psdi.webclient.system.erm

Class UIERMEntity

  • All Implemented Interfaces:
    java.io.Serializable


    public class UIERMEntity
    extends ERMEntity
    implements java.io.Serializable
    See Also:
    Serialized Form
    • Constructor Detail

      • UIERMEntity

        public UIERMEntity()
      • UIERMEntity

        public UIERMEntity(org.w3c.dom.Element controlElement)
        Constructor for the class taking the presentation element that the entity was created from.
        Parameters:
        controlElement -
    • Method Detail

      • getRelatedEntity

        public ERMEntity getRelatedEntity(java.lang.String relationship)
        Returns the child entity whose Mbo relationship is the same as the relationship passed in. This method does not not find the entity by entity name. If you want to find the child/related entity by entity name use the getChildEntity method.
        Overrides:
        getRelatedEntity in class ERMEntity
        Parameters:
        relationship - The Mbo relationship used by a child entity
        Returns:
        - The "related" ERMEntity as defined by the relationship passed in.
      • getCreatingControlId

        public java.lang.String getCreatingControlId()
        Returns the id of the control that this entity was created from. There is the potential that the id can be null. In that case the entity was created because another control is bound to the entity and the entity hasn't been created yet. In that case it is expected that once the control that defines/creates this entity if found (during the creation of the EntityRelationshipModel) the creating control of the entity will be updated.
        Returns:
        returns the id of the control the entity was created from. It can return null.
      • setCreatingControl

        public void setCreatingControl(org.w3c.dom.Element creatingElement)
        Sets the control that creates the data source that the entity is based on. This method will set the creating control id and the relationship used by the entity, if there is one.
        Parameters:
        creatingElement - - The control element that the entity is based on.
      • getRelationship

        public java.lang.String getRelationship()
        Returns the relationship used by the data source which is represented by this entity.
        Returns:
        the Mbo relationship used by the entity
      • addCondUISigOption

        public void addCondUISigOption(java.lang.String sigOption,
                                       UIERMAttribute attribute)
        This adds the passed in sigoption to the list of sigoptions that will need to be evaluated for conditional ui.
        Parameters:
        sigOption - The sigoption to add to the entity's list
        attribute - The attribute whose inputmode could change as a result of the eval of the sigoption
      • getCondUISigOptions

        public java.util.Map getCondUISigOptions()
        The structure that is holding the sigoptions that need to be evaluated on this enitity is a map of maps. Where the key to the "outer" map is a sigoption. The value is a map keyed by UIERMEntities. The entities are needed because the attribute whose inputmode could be conditionally changed may actually be an attribute associated with another UIERMEntiny. Then the attribute is added to the list (which is then stored as the value of the entity map) of the attributes for the entity. This structure allows the sigoption to be evaluated once on a mbo. Then just loop thru the list of entities find their MboSets and based on the conditional inputmode returned set the appropriate required flag value on each of the attributes for each mbo in the MboSet of the UIERMEntites associated with the sigoption.
        Returns:
        a map of sigoptions with conditional ui that can change the inputmode of a control.
      • addAttribute

        public ERMAttribute addAttribute(ERMAttribute attribute)
        Description copied from class: ERMEntity
        Adds and ERMAttribute the the entity's attribute list.
        Overrides:
        addAttribute in class ERMEntity
        Parameters:
        attribute - The ERMAttribute to add to the list
        Returns:
        returns the replaced attribute if one existed
      • getEntityForMbo

        public ERMEntity getEntityForMbo()
      • addChildEntity

        public void addChildEntity(java.lang.String name,
                                   ERMEntity entity)
        Description copied from class: ERMEntity
        This method adds a related entity (child) entity to this entity with a specified name.
        Overrides:
        addChildEntity in class ERMEntity
        Parameters:
        name - The name of the child entity
        entity - The child ERMEntity to add to this entity
      • setName

        public void setName(java.lang.String name)
        Description copied from class: ERMEntity
        Sets the name of the entity
        Overrides:
        setName in class ERMEntity
        Parameters:
        name - the name of the entity
      • hasSiteOrgDomains

        public boolean hasSiteOrgDomains()
        Returns:
        the hasSiteOrgDomains
      • getSiteOrgValuesKey

        public int getSiteOrgValuesKey()
        Returns:
        the siteOrgValuesKey
      • isCloned

        public boolean isCloned()
      • setIsCloned

        public void setIsCloned(boolean aBool)
      • clone

        public UIERMEntity clone()
        This will check if this ERMEntity has already been cloned. If it has, it will return it. If not, it will clone it and return the cloned Entity.
        Overrides:
        clone in class java.lang.Object
        Returns:
        ERMEntity