Package datomic

Interface Attribute


  • public interface Attribute

    Programmatic representation of a schema attribute.

    Attribute information always resides in memory, so using this interface is more efficient than accessing the same information from the database via e.g. query.
    Since:
    0.9.4470
    • Field Detail

      • CARDINALITY_MANY

        static final java.lang.Object CARDINALITY_MANY
      • CARDINALITY_ONE

        static final java.lang.Object CARDINALITY_ONE
      • UNIQUE_IDENTITY

        static final java.lang.Object UNIQUE_IDENTITY
      • UNIQUE_VALUE

        static final java.lang.Object UNIQUE_VALUE
      • TYPE_BIGDEC

        static final java.lang.Object TYPE_BIGDEC
      • TYPE_BIGINT

        static final java.lang.Object TYPE_BIGINT
      • TYPE_BOOLEAN

        static final java.lang.Object TYPE_BOOLEAN
      • TYPE_BYTES

        static final java.lang.Object TYPE_BYTES
      • TYPE_DOUBLE

        static final java.lang.Object TYPE_DOUBLE
      • TYPE_FN

        static final java.lang.Object TYPE_FN
      • TYPE_FLOAT

        static final java.lang.Object TYPE_FLOAT
      • TYPE_INSTANT

        static final java.lang.Object TYPE_INSTANT
      • TYPE_KEYWORD

        static final java.lang.Object TYPE_KEYWORD
      • TYPE_LONG

        static final java.lang.Object TYPE_LONG
      • TYPE_REF

        static final java.lang.Object TYPE_REF
      • TYPE_STRING

        static final java.lang.Object TYPE_STRING
      • TYPE_URI

        static final java.lang.Object TYPE_URI
      • TYPE_UUID

        static final java.lang.Object TYPE_UUID
    • Method Detail

      • id

        java.lang.Object id()
        The attribute's entity id
        Returns:
        an entity id
      • ident

        java.lang.Object ident()
        The attribute's ident (programmatic name)
        Returns:
        an ident
      • valueType

        java.lang.Object valueType()
        The attribute's value type
        Returns:
        a value type
      • isComponent

        boolean isComponent()
        Is this a component attribute?
        Returns:
        true if :db/isComponent true for this attribute
      • isIndexed

        boolean isIndexed()
        Is this attribute configured for an AVET index?
        Returns:
        true if :db/index true for this attribute, or attribute is unique
      • hasAVET

        boolean hasAVET()

        Does this attribute currently have an AVET index?

        When you alter an existing schema, indexes are created in the background after setting :db/index to true. This method returns true once a recently-added index is ready for use.
        Returns:
        true if AVET index available for this attribute
      • hasNoHistory

        boolean hasNoHistory()
        Is this a noHistory attribute?
        Returns:
        true if :db/noHistory true for this attribute
      • hasFulltext

        boolean hasFulltext()
        Does this attribute have a fulltext index?
        Returns:
        true if :db/fulltext true for this attribute