Class BinaryTypeProxy

  • All Implemented Interfaces:
    BinaryType

    public class BinaryTypeProxy
    extends Object
    implements BinaryType
    Binary type proxy. Is used to delay or completely avoid metadata lookup.
    • Constructor Detail

      • BinaryTypeProxy

        public BinaryTypeProxy​(BinaryContext ctx,
                               int typeId,
                               @Nullable
                               @Nullable String clsName)
        Constructor.
        Parameters:
        ctx - Context.
        typeId - Type ID.
        clsName - Class name.
    • Method Detail

      • typeId

        public int typeId()
        Gets binary type ID.
        Specified by:
        typeId in interface BinaryType
        Returns:
        Binary type ID.
      • field

        public BinaryField field​(String fieldName)
        Get BinaryField for the given field name. Later this field can be used for fast field's value retrieval from concrete BinaryObject.
        Specified by:
        field in interface BinaryType
        Parameters:
        fieldName - Field name.
        Returns:
        Binary field.
      • typeName

        public String typeName()
        Gets binary type name.
        Specified by:
        typeName in interface BinaryType
        Returns:
        Binary type name.
      • fieldNames

        public Collection<String> fieldNames()
        Gets collection of all field names for this binary type.
        Specified by:
        fieldNames in interface BinaryType
        Returns:
        Collection of all field names for this binary type.
      • fieldTypeName

        public String fieldTypeName​(String fieldName)
        Gets name of the field type for a given field.
        Specified by:
        fieldTypeName in interface BinaryType
        Parameters:
        fieldName - Field name.
        Returns:
        Field type name.
      • affinityKeyFieldName

        public String affinityKeyFieldName()
        Binary objects can optionally specify custom key-affinity mapping in the configuration. This method returns the name of the field which should be used for the key-affinity mapping.
        Specified by:
        affinityKeyFieldName in interface BinaryType
        Returns:
        Affinity key field name.
      • isEnum

        public boolean isEnum()
        Check whether type represents enum or not.
        Specified by:
        isEnum in interface BinaryType
        Returns:
        True if type is enum.