Class BaseReferenceCodec<T>

  • Type Parameters:
    T - the property type
    All Implemented Interfaces:
    org.bson.codecs.Codec<T>, org.bson.codecs.Decoder<T>, org.bson.codecs.Encoder<T>
    Direct Known Subclasses:
    MorphiaReferenceCodec, ReferenceCodec

    public abstract class BaseReferenceCodec<T>
    extends Object
    implements org.bson.codecs.Codec<T>
    Defines codecs for properties
    Developer note.
    This is an internal item. Its function and presence are subject to change without warning. Its use is highly discouraged.
    • Constructor Detail

      • BaseReferenceCodec

        public BaseReferenceCodec​(Datastore datastore,
                                  PropertyModel property)
        Creates a codec
        Parameters:
        datastore - the datastore
        property - the property
    • Method Detail

      • getDatastore

        public Datastore getDatastore()
        Returns:
        the datastore
      • getPropertyModel

        public PropertyModel getPropertyModel()
        Returns:
        the field
      • getTypeData

        public TypeData<?> getTypeData()
        Returns:
        the type data
      • getEntityModelForField

        protected EntityModel getEntityModelForField()