psdi.app.contract

Class ContractType

  • java.lang.Object
  • All Implemented Interfaces:
    java.rmi.Remote, ContractTypeRemote, MboConstants, MboRemote, MaxRemoteProxy


    public class ContractType
    extends Mbo
    implements ContractTypeRemote
    MBO object to represent Contract Type.
    Contract Type table stored a list of valid contract types. ContractType table is related to ContractType value list. All the entries in ContractType value list should be in ContractType table. ContractTypeId is the user defined contract type. The value of ContractTypeId is same as SYNONYMDOMAIN.Value attribute. MaxContractType is the internal contract type. The value of MaxContractType is same as SYNONYMDOMAIN.MaxValue attribute.
    This is an organization level object.
    The key attributes for this object are OrgId and ContractTypeId.

    The attributes in this object are as follows:

    Attribute Name Description
    ContractTypeId Identifies the contract type. Contract type is same as ContractType SynonymDomain Value.
    Description Description of the Contract Type.
    MaxContractType Internal contract type. MaxContractType is same as ContractType SynonymDomain MaxValue.
    OrgId Identifier of the organization for this Contract Type.
    • Constructor Detail

      • ContractType

        public ContractType(MboSet ms)
                     throws MXException,
                            java.rmi.RemoteException
        Construct the Contract Type object.
        Parameters:
        ms -
        Throws:
        MXException
        java.rmi.RemoteException
    • Method Detail

      • add

        public void add()
                 throws MXException,
                        java.rmi.RemoteException
        Add a new ContractType.
        Specified by:
        add in interface MboRemote
        Overrides:
        add in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • save

        public void save()
                  throws MXException,
                         java.rmi.RemoteException
        This also save or update SYNONYMDOMAIN table. Due to framework changes, we need to get SynonymDomain through MaxDomain (using SYNONYMDOMAIN relationship) when inserting, updating or deleting data in SynonymDomain table. SynonymDomain Save logic will take care of inserting other records.
        Overrides:
        save in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • canDelete

        public void canDelete()
                       throws MXException,
                              java.rmi.RemoteException
        This method is called by the delete() method. All the conditions under which this Mbo can be deleted must be checked here. Can delete a Contract Type only if the MaxContractTyps is not a default value of ContractType DomainID.
        Overrides:
        canDelete in class Mbo
        Throws:
        MXApplicationException - (contract, cannotdeletetype) is thrown if the MaxContractTyps is a default in DomainID ContractType.
        MXException
        java.rmi.RemoteException
      • delete

        public void delete(long accessmodifier)
                    throws MXException,
                           java.rmi.RemoteException
        This method is called to delete a contract type. It deletes the contract type, the corresponding contract type in SynonymDomain, PropertyDefault and ContractTypeTerm records.
        Specified by:
        delete in interface MboRemote
        Overrides:
        delete in class Mbo
        Parameters:
        accessModifier - The bitwise flag.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        Mbo.delete(long)
      • undelete

        public void undelete()
                      throws MXException,
                             java.rmi.RemoteException
        This method undeletes a contract type that has been marked for deletion. It also undeletes the corresponding contract type in SynonymDomain, PropertyDefault and ContractTypeTerm records.
        Specified by:
        undelete in interface MboRemote
        Overrides:
        undelete in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • copyTerms

        public void copyTerms(MboSetRemote termsSet)
                       throws MXException,
                              java.rmi.RemoteException
        This method will copy the selected terms to the set calling Mbo's corresponding Terms. It will be used for selecting Terms to POTerm, PRTerm or ContractTerm.
        Specified by:
        copyTerms in interface ContractTypeRemote
        Parameters:
        termsSet - the pass in Term Set.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        psdi.app.contract