revert firestoreから受け取ったデータを一つの配列化
This commit is contained in:
murakumo 2024-06-18 10:21:49 +00:00
parent 25bc379d25
commit 4ba6437357
4 changed files with 1 additions and 11 deletions

View File

@ -7,7 +7,6 @@
<option name="testRunner" value="GRADLE" />
<option name="distributionType" value="DEFAULT_WRAPPED" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="gradleJvm" value="jbr-17" />
<option name="modules">
<set>
<option value="$PROJECT_DIR$" />

View File

@ -1,6 +1,6 @@
<project version="4">
<component name="ExternalStorageConfigurationManager" enabled="true" />
<component name="ProjectRootManager" version="2" languageLevel="JDK_17" default="true" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
<component name="ProjectRootManager" version="2" languageLevel="JDK_17" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" />
</component>
<component name="ProjectType">

View File

@ -19,9 +19,6 @@ public class FirestoreReception {
db = FirebaseFirestore.getInstance();
}
//firestoreから受け取ったデータを束ねるためのマップ
public Map<String, Object> firestoreData;
//ClassIdを引数にデータの作成を行う
public void getDocumentsByClassId(int classId, MainActivity context) {
CollectionReference collectionRef = db.collection("QuestionnaireForms");
@ -39,17 +36,11 @@ public class FirestoreReception {
// CreateRootクラスのインスタンスを作成しdataを引数として渡す
GeoCoder geoCoder = new GeoCoder();
geoCoder.processData(data, context);
// firestoreDataにdataを追加
firestoreData = data;
}
} else {
Log.w("FirestoreReception", "Error getting documents.", task.getException());
}
Log.w ("FirestoreReception", "firestoreData: " + firestoreData.size());
}
});
}
}