Skip to content

Commit 2d5ec68

Browse files
committed
addressing more nits.
1 parent cb89423 commit 2d5ec68

File tree

3 files changed

+5
-19
lines changed

3 files changed

+5
-19
lines changed

firebase-firestore/src/main/java/com/google/firebase/firestore/UserDataConverter.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public UserDataConverter(DatabaseId databaseId) {
7676
/**
7777
* Parse document data from a non-merge set() call.
7878
*
79-
* @param input A POJO object representing document data.
79+
* @param input A map or POJO object representing document data.
8080
*/
8181
public ParsedSetData parseSetData(Object input) {
8282
ParseAccumulator accumulator = new ParseAccumulator(UserData.Source.Set);
@@ -87,7 +87,7 @@ public ParsedSetData parseSetData(Object input) {
8787
/**
8888
* Parse document data from a set() call with SetOptions.merge() set.
8989
*
90-
* @param input A POJO object representing document data.
90+
* @param input A map or POJO object representing document data.
9191
* @param fieldMask A {@link FieldMask} object representing the fields to be merged.
9292
*/
9393
public ParsedSetData parseMergeData(Object input, @Nullable FieldMask fieldMask) {

firebase-firestore/src/main/java/com/google/firebase/firestore/util/CustomClassMapper.java

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public static Map<String, Object> convertToPlainJavaTypes(Map<?, Object> update)
9696
*/
9797
public static <T> T convertToCustomClass(
9898
Object object, Class<T> clazz, DocumentReference docRef) {
99-
// TODO: Use DeserializeContext to encapsulate ErrorPath and docRef.
99+
// TODO(wuandy): Use DeserializeContext to encapsulate ErrorPath and docRef.
100100
return deserializeToClass(object, clazz, ErrorPath.EMPTY);
101101
}
102102

@@ -757,7 +757,7 @@ private Type resolveType(Type type, Map<TypeVariable<Class<T>>, Type> types) {
757757
}
758758

759759
Map<String, Object> serialize(T object, ErrorPath path) {
760-
// TODO: Add logic to skip @DocumentId annotated fields in serialization.
760+
// TODO(wuandy): Add logic to skip @DocumentId annotated fields in serialization.
761761
if (!clazz.isAssignableFrom(object.getClass())) {
762762
throw new IllegalArgumentException(
763763
"Can't serialize object of class "
@@ -1015,18 +1015,4 @@ public String toString() {
10151015
}
10161016
}
10171017
}
1018-
1019-
static class DeserializeContext {
1020-
final ErrorPath errorPath;
1021-
final String documentId;
1022-
1023-
DeserializeContext(ErrorPath path, String docId) {
1024-
errorPath = path;
1025-
documentId = docId;
1026-
}
1027-
1028-
DeserializeContext newInstanceWithErrorPath(ErrorPath newPath) {
1029-
return new DeserializeContext(newPath, documentId);
1030-
}
1031-
}
10321018
}

firebase-firestore/src/main/java/com/google/firebase/firestore/util/DocumentId.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,4 @@
3535
@PublicApi
3636
@Retention(RetentionPolicy.RUNTIME)
3737
@Target({ElementType.FIELD})
38-
public @interface DocumentId {}
38+
@interface DocumentId {}

0 commit comments

Comments
 (0)