Interface AgreementService
- All Known Implementing Classes:
StandardAgreementService
Supported API: true
Extendable: false
-
Method Summary
Modifier and TypeMethodDescriptioncreateAgreement(AgreementAttributes agreementAttributes, WTCollection authorizedObjects, WTCollection authorizedPrincipals, ObjectReference authorizationDocumentReference) Deprecated.As of release 10.0.voidcreateAgreementAuthorizedObjectLinks(HashMap<AuthorizationAgreement, WTCollection> agreementToAuthorizedObject) Associates an agreement iteration to a collection of Contexts.createAuthorizationAgreement(AgreementAttributes agreementAttributes, WTCollection authorizedObjects, WTCollection authorizedPrincipals, ObjectReference authorizationDocumentReference) Creates an agreement object based on the required attributes and persists it.
-
Method Details
-
createAuthorizationAgreement
ObjectReference createAuthorizationAgreement(AgreementAttributes agreementAttributes, WTCollection authorizedObjects, WTCollection authorizedPrincipals, ObjectReference authorizationDocumentReference) throws WTException, WTPropertyVetoException Creates an agreement object based on the required attributes and persists it. This API also associates the related authorized objects, authorized principals, and authorization document.The session user must be an agreement manager. The user must also have create permission for agreement objects and read permission for all of the associated authorized objects, principals, and document.
Supported API: true- Parameters:
agreementAttributes- The attributes to use in creating the agreement. This parameter is required (must not be null).authorizedObjects- The authorized objects to associate to this agreement. TheWTCollectionmust contain onlySecurityLabeledand/orAgreementAuthorizedObjectobjects. In order to specify version ranges for authorized objects, an AgreementAuthorizedObject must be used. See the Javadoc for:AgreementAuthorizedObject.newAgreementAuthorizedObject(WTReference,ObjectReference,String,String,Integer,Integer). Duplicates will be ignored. Conflicting version ranges for the same object will result in anAgreementCollectionException. This parameter may be null or empty.authorizedPrincipals- The authorized principals to associate to this agreement. TheWTCollectionmust contain onlyWTGroupand/orWTUserobjects. Any duplicates will be ignored. This parameter may be null or empty.authorizationDocumentReference- The authorization document to reference for this agreement. TheObjectReferencemust refer to aWTDocumentobject. This parameter may be null.- Returns:
- ObjectReference - A reference to the persisted agreement object
- Throws:
WTException- If any error occurs while creating and persisting the agreementWTPropertyVetoException- If any attributes specified are invalid
-
createAgreement
@Deprecated AuthorizationAgreement createAgreement(AgreementAttributes agreementAttributes, WTCollection authorizedObjects, WTCollection authorizedPrincipals, ObjectReference authorizationDocumentReference) throws WTException, WTPropertyVetoException Deprecated.As of release 10.0. Replaced bycreateAuthorizationAgreement(AgreementAttributes,WTCollection,WTCollection,ObjectReference).Creates an agreement object based on the required attributes and persists it. This API also associates the related authorized objects, authorized principals, and authorization document.The session user must be an agreement manager. The user must also have create permission for agreement objects and read permission for all of the associated authorized objects, principals, and document.
Supported API: true- Parameters:
agreementAttributes- The attributes to use in creating the agreement. This parameter is required (must not be null).authorizedObjects- The authorized objects to associate to this agreement. TheWTCollectionmust contain onlySecurityLabeledand/orAgreementAuthorizedObjectobjects. In order to specify version ranges for authorized objects, an AgreementAuthorizedObject must be used. See the Javadoc for:AgreementAuthorizedObject.newAgreementAuthorizedObject(WTReference,ObjectReference,String,String,Integer,Integer). Duplicates will be ignored. Conflicting version ranges for the same object will result in anAgreementCollectionException. This parameter may be null or empty.authorizedPrincipals- The authorized principals to associate to this agreement. TheWTCollectionmust contain onlyWTGroupand/orWTUserobjects. Any duplicates will be ignored. This parameter may be null or empty.authorizationDocumentReference- The authorization document to reference for this agreement. TheObjectReferencemust refer to aWTDocumentobject. This parameter may be null.- Returns:
- AuthorizationAgreement - The persisted agreement object (null if the session user does not have read permission)
- Throws:
WTException- If any error occurs while creating and persisting the agreementWTPropertyVetoException- If any attributes specified are invalid
-
createAgreementAuthorizedObjectLinks
void createAgreementAuthorizedObjectLinks(HashMap<AuthorizationAgreement, WTCollection> agreementToAuthorizedObject) throws WTExceptionAssociates an agreement iteration to a collection of Contexts.The session user must be an agreement manager.
If the agreementToAuthorizedObject parameter is null, WTInvalidParameterException will be thrown. If key is not Context based authorization agreement object or if collection contains non-context object, an AgreementException will be thrown.
Supported API: true- Parameters:
agreementToAuthorizedObject- HashMap where AuthorizationAgreement object is key & collection of contexts to be associated as value- Throws:
WTException
-