Skip to content

Commit 67b1c75

Browse files
committed
Polishing.
1 parent cb6fadf commit 67b1c75

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

spring-data-mongodb/src/main/java/org/springframework/data/mongodb/core/convert/MappingMongoConverter.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,7 @@ public void setCodecRegistryProvider(@Nullable CodecRegistryProvider codecRegist
280280
this.codecRegistryProvider = codecRegistryProvider;
281281
}
282282

283+
@Override
283284
public MappingContext<? extends MongoPersistentEntity<?>, MongoPersistentProperty> getMappingContext() {
284285
return mappingContext;
285286
}
@@ -432,6 +433,7 @@ public Map<String, Object> getBean() {
432433
}
433434
}
434435

436+
@Override
435437
public <S extends Object> S read(Class<S> clazz, Bson bson) {
436438
return read(TypeInformation.of(clazz), bson);
437439
}
@@ -729,6 +731,7 @@ private Object readUnwrapped(ConversionContext context, DocumentAccessor documen
729731
return null;
730732
}
731733

734+
@Override
732735
public DBRef toDBRef(Object object, @Nullable MongoPersistentProperty referringProperty) {
733736

734737
org.springframework.data.mongodb.core.mapping.DBRef annotation;
@@ -795,6 +798,7 @@ DocumentPointer<?> createDocumentPointer(Object source, @Nullable MongoPersisten
795798
*
796799
* @see org.springframework.data.mongodb.core.convert.MongoWriter#write(java.lang.Object, java.lang.Object)
797800
*/
801+
@Override
798802
public void write(Object obj, Bson bson) {
799803

800804
if (null == obj) {
@@ -933,6 +937,7 @@ private void writeAssociation(Association<MongoPersistentProperty> association,
933937
writePropertyInternal(value, dbObjectAccessor, inverseProp, accessor);
934938
}
935939

940+
// TODO: Documentaccessor is package-private
936941
@SuppressWarnings({ "unchecked" })
937942
protected void writePropertyInternal(@Nullable Object obj, DocumentAccessor accessor, MongoPersistentProperty prop,
938943
PersistentPropertyAccessor<?> persistentPropertyAccessor) {
@@ -1610,7 +1615,7 @@ public Object convertToMongoType(@Nullable Object obj, @Nullable TypeInformation
16101615
}
16111616

16121617
@Override
1613-
public Object convertToMongoType(@Nullable Object obj, MongoPersistentEntity entity) {
1618+
public Object convertToMongoType(@Nullable Object obj, MongoPersistentEntity<?> entity) {
16141619
Document newDocument = new Document();
16151620
writeInternal(obj, newDocument, entity);
16161621
return newDocument;
@@ -1948,6 +1953,7 @@ static class MongoDbPropertyValueProvider implements PropertyValueProvider<Mongo
19481953
this.spELContext = spELContext;
19491954
}
19501955

1956+
@Override
19511957
@Nullable
19521958
@SuppressWarnings("unchecked")
19531959
public <T> T getPropertyValue(MongoPersistentProperty property) {
@@ -2261,6 +2267,7 @@ default <S> S findContextualEntity(MongoPersistentEntity<S> entity, Document doc
22612267
return null;
22622268
}
22632269

2270+
// TODO: ObjectPath is package-private
22642271
ObjectPath getPath();
22652272

22662273
CustomConversions getCustomConversions();
@@ -2421,6 +2428,7 @@ public ConversionContext withPath(ObjectPath currentPath) {
24212428
collectionConverter, mapConverter, dbRefConverter, elementConverter);
24222429
}
24232430

2431+
// TODO: ObjectPath is package-private
24242432
@Override
24252433
public ObjectPath getPath() {
24262434
return path;

0 commit comments

Comments
 (0)