Package adalid.core

Class AbstractPersistentEntity

    • Constructor Detail

      • AbstractPersistentEntity

        public AbstractPersistentEntity​(Artifact declaringArtifact,
                                        Field declaringField)
    • Method Detail

      • finalise

        public boolean finalise()
        Description copied from interface: Artifact
        dot the i's and cross the t's
        Specified by:
        finalise in interface Artifact
        Overrides:
        finalise in class AbstractEntity
        Returns:
        true if this artifact was successfully finalised; otherwise false
      • linkForeignQueryEntityReferences

        protected void linkForeignQueryEntityReferences()
      • getDiscriminatorFieldName

        public String getDiscriminatorFieldName()
        Returns:
        the discriminator property name
      • getDiscriminatorField

        public Field getDiscriminatorField()
        Returns:
        the discriminator property field
      • isAnnotatedWithInheritanceMapping

        public boolean isAnnotatedWithInheritanceMapping()
        Returns:
        the InheritanceMapping annotation indicator
      • isAnnotatedWithDiscriminatorValue

        public boolean isAnnotatedWithDiscriminatorValue()
        Returns:
        the DiscriminatorValue annotation indicator
      • isAnnotatedWithEntityTriggers

        public boolean isAnnotatedWithEntityTriggers()
        Returns:
        the EntityTriggers annotation indicator
      • isAnnotatedWithForeignKey

        public boolean isAnnotatedWithForeignKey()
        Returns:
        the ForeignKey annotation indicator
      • isTable

        public boolean isTable()
        Specified by:
        isTable in interface PersistentEntity
        Returns:
        the table indicator
      • getDiscriminatorType

        public String getDiscriminatorType()
        Returns:
        the discriminator type
      • getEntityTriggerColumnsList

        public List<Property> getEntityTriggerColumnsList()
        Returns:
        the properties that are columns
      • getMatchingColumnsList

        public List<Property> getMatchingColumnsList​(List<Property> properties)
        Parameters:
        properties - properties
        Returns:
        the properties that are columns
      • getEntityClassColumnsList1

        public List<Property> getEntityClassColumnsList1()
        Returns:
        the properties that are not entities
      • getEntityClassColumnsList2

        public List<Property> getEntityClassColumnsList2()
        Returns:
        the properties that are entities
      • getEntityClassColumnsList3

        public List<Property> getEntityClassColumnsList3()
        Returns:
        the properties that reference this entity
      • getChecksList

        public List<Expression> getChecksList()
        Returns:
        the expressions that are checks
      • getChecksList

        public List<Expression> getChecksList​(Checkpoint checkpoint)
        Parameters:
        checkpoint - the point at which the check is performed
        Returns:
        the expressions that are checks checked at the specified checkpoint
      • getChecksList

        public List<Expression> getChecksList​(Checkpoint checkpoint,
                                              boolean inheritedless)
        Parameters:
        checkpoint - the point at which the check is performed
        inheritedless - exclude inherited checks or not
        Returns:
        the expressions that are checks checked at the specified checkpoint
      • getInsertableRowsList

        public List<Instance> getInsertableRowsList()
        Returns:
        the insertable rows
      • getQueryTable

        public QueryTable getQueryTable​(int maxDepth)
        Parameters:
        maxDepth - max depth
        Returns:
        the queryTable
      • getQueryTable

        public QueryTable getQueryTable​(VirtualEntityType virtualEntityType)
        Parameters:
        virtualEntityType - virtual entity type
        Returns:
        the queryTable
      • getQueryTable

        public QueryTable getQueryTable​(int maxDepth,
                                        VirtualEntityType virtualEntityType)
        Parameters:
        maxDepth - max depth
        virtualEntityType - virtual entity type
        Returns:
        the queryTable
      • getEntityListReport

        public Report getEntityListReport()
        Returns:
        the entity list report
      • getChecksColumnsList

        public List<Property> getChecksColumnsList()
        Returns:
        the referenced columns list
      • getChecksColumnsList

        public List<Property> getChecksColumnsList​(Checkpoint checkpoint)
        Parameters:
        checkpoint - the point at which the check is performed
        Returns:
        the referenced columns list
      • getChecksColumnsMap

        public Map<String,​Property> getChecksColumnsMap()
        Returns:
        the referenced columns map
      • getChecksColumnsMap

        public Map<String,​Property> getChecksColumnsMap​(Checkpoint checkpoint)
        Parameters:
        checkpoint - the point at which the check is performed
        Returns:
        the referenced columns map
      • getChecksJoinsList

        public List<QueryJoin> getChecksJoinsList()
        Returns:
        the referenced joins list
      • getChecksJoinsList

        public List<QueryJoin> getChecksJoinsList​(Checkpoint checkpoint)
        Parameters:
        checkpoint - the point at which the check is performed
        Returns:
        the referenced joins list
      • getChecksJoinsMap

        public Map<String,​QueryJoin> getChecksJoinsMap()
        Returns:
        the referenced joins map
      • getChecksJoinsMap

        public Map<String,​QueryJoin> getChecksJoinsMap​(Checkpoint checkpoint)
        Parameters:
        checkpoint - the point at which the check is performed
        Returns:
        the referenced joins map
      • getInitialValueColumnsList

        public List<Property> getInitialValueColumnsList()
        Returns:
        the referenced columns list
      • getInitialValueColumnsMap

        public Map<String,​Property> getInitialValueColumnsMap()
        Returns:
        the referenced columns map
      • getInitialValueJoinsList

        public List<QueryJoin> getInitialValueJoinsList()
        Returns:
        the referenced joins list
      • getInitialValueJoinsMap

        public Map<String,​QueryJoin> getInitialValueJoinsMap()
        Returns:
        the referenced joins map
      • getDefaultValueColumnsList

        public List<Property> getDefaultValueColumnsList()
        Returns:
        the referenced columns list
      • getDefaultValueColumnsList

        public List<Property> getDefaultValueColumnsList​(String checkpoints,
                                                         String conditions)
        Parameters:
        checkpoints - valid checkpoint names (null for all)
        conditions - valid conditions names (null for all)
        Returns:
        the referenced columns list
      • getDefaultValueColumnsMap

        public Map<String,​Property> getDefaultValueColumnsMap()
        Returns:
        the referenced columns map
      • getDefaultValueColumnsMap

        public Map<String,​Property> getDefaultValueColumnsMap​(String checkpoints,
                                                                    String conditions)
        Parameters:
        checkpoints - valid checkpoint names (null for all)
        conditions - valid conditions names (null for all)
        Returns:
        the referenced columns map for sql functions
      • getDefaultValueJoinsList

        public List<QueryJoin> getDefaultValueJoinsList()
        Returns:
        the referenced joins list
      • getDefaultValueJoinsList

        public List<QueryJoin> getDefaultValueJoinsList​(String checkpoints,
                                                        String conditions)
        Parameters:
        checkpoints - valid checkpoint names (null for all)
        conditions - valid conditions names (null for all)
        Returns:
        the referenced joins list
      • getDefaultValueJoinsList

        public List<QueryJoin> getDefaultValueJoinsList​(String checkpoints,
                                                        String conditions,
                                                        boolean calculableless)
        Parameters:
        checkpoints - valid checkpoint names (null for all)
        conditions - valid conditions names (null for all)
        calculableless - exclude values referencing calculable properties
        Returns:
        the referenced joins list
      • getDefaultValueJoinsMap

        public Map<String,​QueryJoin> getDefaultValueJoinsMap()
        Returns:
        the referenced joins map
      • getDefaultValueJoinsMap

        public Map<String,​QueryJoin> getDefaultValueJoinsMap​(String checkpoints,
                                                                   String conditions)
        Parameters:
        checkpoints - valid checkpoint names (null for all)
        conditions - valid conditions names (null for all)
        Returns:
        the referenced joins map
      • getDefaultValueJoinsMap

        public Map<String,​QueryJoin> getDefaultValueJoinsMap​(String checkpoints,
                                                                   String conditions,
                                                                   boolean calculableless)
        Parameters:
        checkpoints - valid checkpoint names (null for all)
        conditions - valid conditions names (null for all)
        calculableless - exclude values referencing calculable properties
        Returns:
        the referenced joins map