Class Agreement

java.lang.Object
com.imc.iss.groovy.agreements.Agreement

public class Agreement extends Object
This is a class representing an agreement for use by groovy scripts

Inside the script, an instance of this class, containing the data of the agreement that the script will be run on, will be provided automatically and can be accessed as a variable named agreement

  • Method Details

    • getAgreementAccountName

      public String getAgreementAccountName() throws IMCException
      Retrieves the name of the account that the agreement belongs to
      Returns:
      The account name of the agreement
      Throws:
      IMCException
    • getAgreementDataAttributeValue

      public Object getAgreementDataAttributeValue(String attributeURI) throws IMCException
      To get the value of a agreement data attribute by attribute URI.
      Parameters:
      attributeURI - as String. The URI of the agreement data attribute.
      Returns:
      the value of the agreement data attribute as Object.
      Throws:
      IMCException
    • getAgreementRelationAttributeErpId

      public String getAgreementRelationAttributeErpId(String attributeURI) throws IMCException
      To get the ERPID of a agreement relation attribute by attribute URI.
      Parameters:
      attributeURI - as String. The URI of the agreement relation attribute.
      Returns:
      the ERPId of the agreement relation attribute as String.
      Throws:
      IMCException
    • getAgreementRelationAttributeObjectId

      public String getAgreementRelationAttributeObjectId(String attributeURI) throws IMCException
      To get the object Id of a agreement relation attribute by attribute URI.
      Parameters:
      attributeURI - as String. The URI of the agreement relation attribute.
      Returns:
      the objectId of the agreement relation attribute as String.
      Throws:
      IMCException
    • getAgreementRelationAttributeObjectName

      public String getAgreementRelationAttributeObjectName(String attributeURI) throws IMCException
      To get the object name of a agreement relation attribute by attribute URI.
      Parameters:
      attributeURI - as String. The URI of the agreement relation attribute.
      Returns:
      the object name of the agreement relation attribute as String.
      Throws:
      IMCException
    • getAgreementRelationAttributeURI

      public String getAgreementRelationAttributeURI(String attributeURI) throws IMCException
      To get the URI of a agreement relation attribute by attribute URI.
      Parameters:
      attributeURI - as String. The URI of the agreement relation attribute.
      Returns:
      the object URI of the agreement relation attribute as String.
      Throws:
      IMCException
    • getAgreementURI

      public String getAgreementURI()
      Retrieves the URI of this agreement
      Returns:
      The agreement URI as String
    • setAgreementDataAttribute

      public Agreement setAgreementDataAttribute(String attributeURI, Object value) throws IMCException
      To set a value for the agreement data attribute.
      Parameters:
      attributeURI - as String. The URI of the agreement data attribute.
      value - as Object. The value for the agreement data attribute.
      Returns:
      The Agreement instance.
      Throws:
      IMCException - the platform exception
    • setAgreementRelationAttribute

      public Agreement setAgreementRelationAttribute(String attributeURI, String valueURI) throws IMCException
      To set a value for the agreement relation attribute.
      Parameters:
      attributeURI - as String. The URI of the agreement relation attribute.
      valueURI - as Object. The value for the agreement relation attribute.
      Returns:
      The Agreement instance.
      Throws:
      IMCException - the platform exception
    • toString

      public String toString()
      Returns a string representation of the agreement, which prints all the attributes
      Overrides:
      toString in class Object
      Returns:
      A string representation of the agreement.