psdi.app.system

Class MaxDomain

  • All Implemented Interfaces:
    java.rmi.Remote, MaxDomainRemote, MboConstants, MboRemote, MaxRemoteProxy


    public class MaxDomain
    extends Mbo
    implements MaxDomainRemote
    Mbo object to represent MaxDomain.

    Detailed information about the domain is contained in one of the child tables. The value of the domaintype attribute indicates which child table is used.

    Also see System Package description.

    This is a system level object.

    The key attribute for this object is DomainID.

    The attributes in this object are as follows:

    Attribute NameDescription
    CreationPurpose
    DescriptionFreeform description of the domain.
    DomainIDUnique identifier for this object.
    DomainTypeType of domain, from valuelist DOMTYPE. Each domain type is associated with a different child table. See the "see also" links below.
    See Also:
    ALNValue, NUMValue, RangeDomSegment, MaxTableDomain, ValueListDomain
    • Constructor Detail

      • MaxDomain

        public MaxDomain(MboSet ms)
                  throws java.rmi.RemoteException
        Throws:
        java.rmi.RemoteException
    • Method Detail

      • init

        public void init()
                  throws MXException
        Description copied from class: Mbo
        Called by the framework when the Mbo has been constructed and the MboValues have been initialized. This can be overridden by the programmer to provide any custom initialization they would like to do.
        Overrides:
        init in class Mbo
        Throws:
        MXException
      • add

        public void add()
                 throws MXException,
                        java.rmi.RemoteException
        Add a mbo, defaulting the attributes shown below.
        Attribute NameAttribute Value
        (none)(none)
        Specified by:
        add in interface MboRemote
        Overrides:
        add in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • getValidateOrder

        public java.lang.String[] getValidateOrder()
        Description copied from class: Mbo
        Returns a String[] of field names. The validate and batchValidate() method will test the fields' validations in this order.
        Overrides:
        getValidateOrder in class Mbo
      • canDelete

        public void canDelete()
                       throws MXException,
                              java.rmi.RemoteException
        TODO -- if a domain is reference by maxattribute, or referenced by a field validation class which load this domain, it cannot be deleted.
        Overrides:
        canDelete in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • delete

        public void delete(long accessModifier)
                    throws MXException,
                           java.rmi.RemoteException
        Description copied from class: Mbo
        Mark the object to be deleted depending on the access modifier. This will usually be overridden in the subclass of Mbo as there may be application specific rules as to if and when an object can be deleted. Object is not actually deleted in the database until save() is called. This method will also mark all associated Long Description and Translation Mbos for deletion.
        Specified by:
        delete in interface MboRemote
        Overrides:
        delete in class Mbo
        Parameters:
        accessModifier - The bitwise flag specified to determine if certain normal security checks are to be bypassed for this delete request. For example: if the accessModifer is NOACCESSCHECK, then the check for the object's NODELETE flag and the call to the object's canDelete() method will not be performed. If the accessModifer is NONE, then all the access checks are performed before this object is marked delete.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        Mbo.delete(long)
      • undelete

        public void undelete()
                      throws MXException,
                             java.rmi.RemoteException
        Description copied from class: Mbo
        Unmark the Mbo for deletion. Can only be called after a delete() and before the save() has been performed. This method will also unmark associated Long Description and Translation Mbos.
        Specified by:
        undelete in interface MboRemote
        Overrides:
        undelete in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • appValidateAtTheEnd

        public void appValidateAtTheEnd()
                                 throws MXException,
                                        java.rmi.RemoteException
        Validate before save. Upon save, it requires the lines exists in some cases. However this cannot be done in appValidate() since MEA calls appValidate() at each mbo level.
        Throws:
        MXException
        java.rmi.RemoteException
      • save

        protected void save()
                     throws MXException,
                            java.rmi.RemoteException
        Description copied from class: Mbo
        Save the object and other linked objects. Subclasses can code their save() logic to include any appropriate updates to other linked objects and call super.save().
        Overrides:
        save in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • commit

        protected void commit()
        After commit event to update the cache.
        Overrides:
        commit in class Mbo
      • getInternalDomainType

        public java.lang.String getInternalDomainType()
                                               throws MXException,
                                                      java.rmi.RemoteException
        Return the internal maxtype of this MBO.
        Specified by:
        getInternalDomainType in interface MaxDomainRemote
        Returns:
        Internal domain type
        Throws:
        MXException
        java.rmi.RemoteException
      • getDefaultExtDomType

        public java.lang.String getDefaultExtDomType(java.lang.String internal)
                                              throws MXException,
                                                     java.rmi.RemoteException
        Return the default external domain type for the passed in internal type.
        Specified by:
        getDefaultExtDomType in interface MaxDomainRemote
        Parameters:
        internal -
        Returns:
        Default external domain type
        Throws:
        MXException
        java.rmi.RemoteException
      • initRelationship

        public void initRelationship(java.lang.String relationName,
                                     MboSetRemote mboSet)
                              throws MXException,
                                     java.rmi.RemoteException
        Description copied from class: Mbo
        Called whenever a relationship is initialized or reset from this Mbo to another MboSet. Programmers can override this method for custom handling of related objects. An example of this would be making the WPMATERIAL object read only if the status of the Work Order is CLOSED.
        Overrides:
        initRelationship in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException