Project Aristotle - ArisID Attribute Services

org.openliberty.arisid
Class CarmlDoc

java.lang.Object
  extended by org.openliberty.arisid.CarmlDoc

public class CarmlDoc
extends java.lang.Object

A Java representation of a CARML declaration. Use this object to gain access to application schema definitions (DataDefs) and defined Interactions. This object contains all interactions for the current application. A CarmlDoc may reference other CarmlDoc objects in the case where external data definitions are referenced. All schema will be treated as if it were part of the local Carml declaration. However to test if a particular data object is externally defined, use the isXXXXExternal() methods. This class is normally automatically instantiated by the ArisIdService or by another CarmlDoc object in the case of externally referenced declarations.


Field Summary
static java.lang.String APPNAME_ATTR
           
static java.lang.String[] CARML_SCHEMA
           
static java.lang.String CARML_SCHEMA_PROP
           
static java.lang.String DEFAULT_DOMERRORHANDLER
           
static java.lang.String DEFAULT_DOMIMPLEMENTATIONSOURCE
          This default DOMImplementationSource is used if DomImplementationSourceList is not set in Java system property org.w3c.dom.DOMImplementationSourceList
static java.lang.String DESCR_ATTR
           
static java.lang.String IRDATA_ELEMENT
           
static java.lang.String namespace
           
static java.lang.String PROPERTY_DOM_ERROR_HANDLER
           
static java.lang.String URI_ATTR
           
static java.lang.String XML_SCHEMA
           
 
Method Summary
 org.w3c.dom.Document copyToDocument(java.lang.String appName, java.lang.String description)
          Creates a new copy Document object with the specified new name and description.
 void copyToFile(java.lang.String filename, java.lang.String appName, java.lang.String description)
          Create a copy of the CARML declaration to a new file
 IAddInteraction createAddInteraction(java.lang.String name, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy)
          Deprecated. Use createAddInteraction(String, String, Collection, Collection, IPolicy) instead
 IAddInteraction createAddInteraction(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy)
          Method to define an interaction for the purpose of performing adds.
 IAddInteraction createAddInteractionByRef(java.lang.String name, java.lang.String description, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy)
          Deprecated. Use createAddInteractionByRef(String,String,String,Collection,Collection,IPolicy) instead
 IAddInteraction createAddInteractionByRef(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy)
          Method to define an interaction for the purpose of performing adds.
 IDeleteInteraction createDeleteInteraction(java.lang.String name, java.lang.String description, IPolicy txnPolicy)
          Deprecated. Use createDeleteInteraction(String,String,String,IPolicy) instead
 IDeleteInteraction createDeleteInteraction(java.lang.String name, java.lang.String entityName, java.lang.String description, IPolicy txnPolicy)
          Create an interaction for the purpose of performing deletions of subjects.
 IFindInteraction createFindInteraction(java.lang.String name, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<PredicateDef> predicateDefs, java.util.Collection<RoleDef> roleDefs, Filter filter, IPolicy txnPolicy)
          Deprecated. Use createFindInteraction(String,String,String,Collection,Collection,Collection,Filter,IPolicy) instead
 IFindInteraction createFindInteraction(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<PredicateDef> predicateDefs, java.util.Collection<RoleDef> roleDefs, Filter filter, IPolicy txnPolicy)
          Method to define an interaction for the purpose of performing locating a single subject based on a filter.
 IModifyInteraction createModifyInteraction(java.lang.String name, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy)
          Deprecated. Use createModifyInteractionByRef(String, String, Collection, Collection, IPolicy) instead
 IModifyInteraction createModifyInteraction(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy)
          Creates a modify interaction for the purpose of modifying subjects.
 IModifyInteraction createModifyInteractionByRef(java.lang.String name, java.lang.String description, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy)
          Deprecated. Use createModifyInteractionByRef(String,String,String,Collection,Collection,IPolicy) instead
 IModifyInteraction createModifyInteractionByRef(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy)
          Creates a modify interaction for the purpose of modifying subjects.
 IReadInteraction createReadInteraction(java.lang.String name, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<PredicateDef> predDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy)
          Deprecated. Use createReadInteraction(String,String,String,Collection,Collection,Collection,IPolicy) instead
 IReadInteraction createReadInteraction(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<PredicateDef> predDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy)
          Method to define an interaction for the purpose of performing reads.
 IReadInteraction createReadInteractionByRef(java.lang.String name, java.lang.String description, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<PredicateRef> predicateRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy)
          Deprecated. Use createReadInteractionByRef(String,String,String,Collection,Collection,Collection,IPolicy) instead
 IReadInteraction createReadInteractionByRef(java.lang.String name, java.lang.String entityName, java.lang.String description, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<PredicateRef> predicateRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy)
          Method to define an interaction for the purpose of performing reads.
 ISearchInteraction createSearchInteraction(java.lang.String name, java.lang.String description, Filter filter, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<PredicateDef> predDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy, int maxSubjects, int pageSize)
          Deprecated. Use createSearchInteraction(String,String,String,Filter,Collection,Collection,Collection,IPolicy,int,int) instead
 ISearchInteraction createSearchInteraction(java.lang.String name, java.lang.String entityName, java.lang.String description, Filter filter, java.util.Collection<AttributeDef> attrDefs, java.util.Collection<PredicateDef> predDefs, java.util.Collection<RoleDef> roleDefs, IPolicy txnPolicy, int maxSubjects, int pageSize)
          Creates an Interaction declaration used for the purpose of searching attribute authorities for one or more subjects that match a certain criteria.
 ISearchInteraction createSearchInteractionByRef(java.lang.String name, java.lang.String description, Filter filter, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<PredicateRef> predRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy, int maxSubjects, int pageSize)
          Deprecated. Use createSearchInteractionByRef(String, String, Filter, Collection, Collection, Collection, IPolicy, int, int) instead
 ISearchInteraction createSearchInteractionByRef(java.lang.String name, java.lang.String entityName, java.lang.String description, Filter filter, java.util.Collection<AttributeRef> attrRefs, java.util.Collection<PredicateRef> predRefs, java.util.Collection<RoleRef> roleRefs, IPolicy txnPolicy, int maxSubjects, int pageSize)
          Creates an Interaction declaration used for the purpose of searching attribute authorities for one or more subjects that match a certain criteria.
 java.lang.String getApplicationNameId()
          Returns a unique application name for the application.
 java.net.URI getAppURI()
          Deprecated. Use getCarmlURI() instead
 ArisIdService getAttributeService()
           
 java.net.URI getCarmlURI()
          A unique Carml URI identifier for the application.
 java.lang.String getDescription()
           
 java.util.Collection<java.lang.String> getEntityNames()
           
 IInteraction getInteraction(java.lang.String name)
           
 java.util.Collection<IInteraction> getInteractions()
          Returns all defined Interactions
 java.util.Collection<IInteraction> getInteractionsByEntity(java.lang.String entityName)
          Returns Interactions associated with a particular EntityName or null;
 SchemaManager getSchemaManager()
           
 void setApplicationNameId(java.lang.String name)
          Sets the Application Name Identifier.
 void setAppURI(java.net.URI appUri)
          Deprecated. Use setCarmlURI(URI) instead
 void setCarmlURI(java.net.URI carmlUri)
          Sets the unique URI for the CARML document.
 void setDescription(java.lang.String description)
          Sets the description for the CARML declaration document.
 org.w3c.dom.Document toCarmlDocument()
           
 java.lang.String toCarmlString()
           
 void toFile(java.lang.String filename)
          Writes the current CARML declaration to a file.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

namespace

public static final java.lang.String namespace
See Also:
Constant Field Values

CARML_SCHEMA

public static final java.lang.String[] CARML_SCHEMA

CARML_SCHEMA_PROP

public static final java.lang.String CARML_SCHEMA_PROP
See Also:
Constant Field Values

XML_SCHEMA

public static final java.lang.String XML_SCHEMA
See Also:
Constant Field Values

DEFAULT_DOMIMPLEMENTATIONSOURCE

public static final java.lang.String DEFAULT_DOMIMPLEMENTATIONSOURCE
This default DOMImplementationSource is used if DomImplementationSourceList is not set in Java system property org.w3c.dom.DOMImplementationSourceList

See Also:
Constant Field Values

DEFAULT_DOMERRORHANDLER

public static final java.lang.String DEFAULT_DOMERRORHANDLER

PROPERTY_DOM_ERROR_HANDLER

public static final java.lang.String PROPERTY_DOM_ERROR_HANDLER
See Also:
Constant Field Values

IRDATA_ELEMENT

public static final java.lang.String IRDATA_ELEMENT
See Also:
Constant Field Values

APPNAME_ATTR

public static final java.lang.String APPNAME_ATTR
See Also:
Constant Field Values

DESCR_ATTR

public static final java.lang.String DESCR_ATTR
See Also:
Constant Field Values

URI_ATTR

public static final java.lang.String URI_ATTR
See Also:
Constant Field Values
Method Detail

getApplicationNameId

public java.lang.String getApplicationNameId()
Returns a unique application name for the application. Note: Different instances of an application may carry the same name.

Returns:
A String representing a unique name for the application.

setApplicationNameId

public void setApplicationNameId(java.lang.String name)
                          throws InitializedException
Sets the Application Name Identifier. May not be called if attribute service is initialized.

Parameters:
name - Set the application name identifier to String value.
Throws:
InitializedException - thrown if attribute service is initialized.

getDescription

public java.lang.String getDescription()

setDescription

public void setDescription(java.lang.String description)
                    throws InitializedException
Sets the description for the CARML declaration document. May not be called if attribute service is initialized.

Parameters:
description - Set the description value of the CARML declaration.
Throws:
InitializedException - thrown if attribute service is initialized.

getAppURI

public java.net.URI getAppURI()
Deprecated. Use getCarmlURI() instead

A unique URI identifier for the application. Multiples instances of the same application may carry the same URI. Each URI references an application that uses the identical application data definitions and interaction definitions and policy.

Returns:
A URI identifier for the CARML Document

getCarmlURI

public java.net.URI getCarmlURI()
A unique Carml URI identifier for the application. Multiples instances of the same application may carry the same URI. Each URI references an application that uses the identical application data definitions and interaction definitions and policy.

Returns:
A URI identifier for the CARML Document

setAppURI

public void setAppURI(java.net.URI appUri)
               throws InitializedException
Deprecated. Use setCarmlURI(URI) instead

Sets the unique URI for the CARML document.

Parameters:
appUri - A URI for the document. May be the location of the document or just a unique identifier in the case of an application deployed in multiple sites.
Throws:
InitializedException - thrown if attribute service is initialized.

setCarmlURI

public void setCarmlURI(java.net.URI carmlUri)
                 throws InitializedException
Sets the unique URI for the CARML document.

Parameters:
carmlUri - A URI for the document. May be the location of the document or just a unique identifier in the case of an application deployed in multiple sites.
Throws:
InitializedException - thrown if attribute service is initialized.

getInteraction

public IInteraction getInteraction(java.lang.String name)
Parameters:
name - Name of the interaction object to retrieve.
Returns:
An IInteraction object that provides access to an Interaction definition and the operation itself.

getAttributeService

public ArisIdService getAttributeService()
Returns:
The AttributeService associated with this document

getSchemaManager

public SchemaManager getSchemaManager()
Returns:
Return the SchemaManager (used to manage DataDefs) object.

toCarmlString

public java.lang.String toCarmlString()
                               throws IGFException
Returns:
The CARML XML document as a String
Throws:
IGFException

toCarmlDocument

public org.w3c.dom.Document toCarmlDocument()
Returns:
The CARML declaration as a Document.

copyToDocument

public org.w3c.dom.Document copyToDocument(java.lang.String appName,
                                           java.lang.String description)
Creates a new copy Document object with the specified new name and description.

Parameters:
appName - The Application Name Identifier
description - A description for the new document
Returns:
A Document containing a new copy of the CarmlDoc document

copyToFile

public void copyToFile(java.lang.String filename,
                       java.lang.String appName,
                       java.lang.String description)
                throws IGFException
Create a copy of the CARML declaration to a new file

Parameters:
filename - Output filename (for the local system).
appName - A new name identifier for the copy.
description - A new description for the copy.
Throws:
IGFException

toFile

public void toFile(java.lang.String filename)
            throws IGFException
Writes the current CARML declaration to a file.

Parameters:
filename - Output filename (for the local system).
Throws:
IGFException

createAddInteractionByRef

public IAddInteraction createAddInteractionByRef(java.lang.String name,
                                                 java.lang.String description,
                                                 java.util.Collection<AttributeRef> attrRefs,
                                                 java.util.Collection<RoleRef> roleRefs,
                                                 IPolicy txnPolicy)
                                          throws InitializedException,
                                                 UndefinedException
Deprecated. Use createAddInteractionByRef(String,String,String,Collection,Collection,IPolicy) instead

Method to define an interaction for the purpose of performing adds. Attributes and Roles use reference objects that support for policy references.

Parameters:
name - The name of the interaction
description - A description of what the application means by the add
attrRefs - The attributes that are to be added in an add operation.
roleRefs - The roles that may be asserted for the profile to be added.
txnPolicy - The policy that is associated with this interaction
Returns:
An IAddInteraction to perform the add transactions.
Throws:
InitializedException
UndefinedException

createAddInteractionByRef

public IAddInteraction createAddInteractionByRef(java.lang.String name,
                                                 java.lang.String entityName,
                                                 java.lang.String description,
                                                 java.util.Collection<AttributeRef> attrRefs,
                                                 java.util.Collection<RoleRef> roleRefs,
                                                 IPolicy txnPolicy)
                                          throws InitializedException,
                                                 UndefinedException
Method to define an interaction for the purpose of performing adds. Attributes and Roles use reference objects that support for policy references.

Parameters:
name - The name of the interaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A description of what the application means by the add
attrRefs - The attributes that are to be added in an add operation.
roleRefs - The roles that may be asserted for the profile to be added.
txnPolicy - The policy that is associated with this interaction
Returns:
An IAddInteraction to perform the add transactions.
Throws:
InitializedException
UndefinedException

createAddInteraction

public IAddInteraction createAddInteraction(java.lang.String name,
                                            java.lang.String description,
                                            java.util.Collection<AttributeDef> attrDefs,
                                            java.util.Collection<RoleDef> roleDefs,
                                            IPolicy txnPolicy)
                                     throws InitializedException,
                                            UndefinedException
Deprecated. Use createAddInteraction(String, String, Collection, Collection, IPolicy) instead

Method to define an interaction for the purpose of performing adds. This method signature assumes there is no attribute or role specific policy for the transaction. This method signature assumes there is no specific attribute, or role specific policy. All attributes and roles will be presumed to be required (the default).

Parameters:
name - The name of the interaction
description - A description of what the application means by the add
attrDefs - The attributes that are to be added in an add operation.
roleDefs - The roles that may be asserted for the profile to be added.
txnPolicy - The policy that is associated with this interaction
Returns:
An IAddInteraction to perform the add transactions.
Throws:
InitializedException
UndefinedException

createAddInteraction

public IAddInteraction createAddInteraction(java.lang.String name,
                                            java.lang.String entityName,
                                            java.lang.String description,
                                            java.util.Collection<AttributeDef> attrDefs,
                                            java.util.Collection<RoleDef> roleDefs,
                                            IPolicy txnPolicy)
                                     throws InitializedException,
                                            UndefinedException
Method to define an interaction for the purpose of performing adds. This method signature assumes there is no attribute or role specific policy for the transaction. This method signature assumes there is no specific attribute, or role specific policy. All attributes and roles will be presumed to be required (the default).

Parameters:
name - The name of the interaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A description of what the application means by the add
attrDefs - The attributes that are to be added in an add operation.
roleDefs - The roles that may be asserted for the profile to be added.
txnPolicy - The policy that is associated with this interaction
Returns:
An IAddInteraction to perform the add transactions.
Throws:
InitializedException
UndefinedException

createFindInteraction

public IFindInteraction createFindInteraction(java.lang.String name,
                                              java.lang.String description,
                                              java.util.Collection<AttributeDef> attrDefs,
                                              java.util.Collection<PredicateDef> predicateDefs,
                                              java.util.Collection<RoleDef> roleDefs,
                                              Filter filter,
                                              IPolicy txnPolicy)
                                       throws InitializedException,
                                              UndefinedException
Deprecated. Use createFindInteraction(String,String,String,Collection,Collection,Collection,Filter,IPolicy) instead

Method to define an interaction for the purpose of performing locating a single subject based on a filter.

Parameters:
name - The name of the interaction
description - A description of why the application is performing the authenticate.
attrDefs - A Collection of AttributeDef defining the attributes that are to be returned.
predicateDefs - A Collection of PredicateDef objects defining the predicates that are to be returned.
roleDefs - A Collection of RoleDef objects defining roles that are to be returned.
filter - A filter specific enough to match one record
txnPolicy - The policy that is associated with this interaction
Returns:
An IFindInteraction to perform the add transactions.
Throws:
InitializedException
UndefinedException

createFindInteraction

public IFindInteraction createFindInteraction(java.lang.String name,
                                              java.lang.String entityName,
                                              java.lang.String description,
                                              java.util.Collection<AttributeDef> attrDefs,
                                              java.util.Collection<PredicateDef> predicateDefs,
                                              java.util.Collection<RoleDef> roleDefs,
                                              Filter filter,
                                              IPolicy txnPolicy)
                                       throws InitializedException,
                                              UndefinedException
Method to define an interaction for the purpose of performing locating a single subject based on a filter.

Parameters:
name - The name of the interaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A description of why the application is performing the authenticate.
attrDefs - A Collection of AttributeDef defining the attributes that are to be returned.
predicateDefs - A Collection of PredicateDef objects defining the predicates that are to be returned.
roleDefs - A Collection of RoleDef objects defining roles that are to be returned.
filter - A filter specific enough to match one record
txnPolicy - The policy that is associated with this interaction
Returns:
An IFindInteraction to perform the add transactions.
Throws:
InitializedException
UndefinedException

createReadInteractionByRef

public IReadInteraction createReadInteractionByRef(java.lang.String name,
                                                   java.lang.String description,
                                                   java.util.Collection<AttributeRef> attrRefs,
                                                   java.util.Collection<PredicateRef> predicateRefs,
                                                   java.util.Collection<RoleRef> roleRefs,
                                                   IPolicy txnPolicy)
                                            throws InitializedException,
                                                   UndefinedException
Deprecated. Use createReadInteractionByRef(String,String,String,Collection,Collection,Collection,IPolicy) instead

Method to define an interaction for the purpose of performing reads. Reads are used to retrieve attributes, predicates and roles about subjects. This method uses Attribute, Predicate, and Role Reference objects to allow specification of policy specific to each attribute, predicate, or policy.

Parameters:
name - The name of the interaction
description - A friendly description of why the application is performing the read.
attrRefs - The attributes that are to be added in an read operation.
predicateRefs - The predicates that are to be tested in the read operation.
roleRefs - The roles that the interaction is to report on or test for presence.
txnPolicy - The policy that is associated with this interaction
Returns:
an IReadInteraction to perform reads as declared.
Throws:
InitializedException
UndefinedException

createReadInteractionByRef

public IReadInteraction createReadInteractionByRef(java.lang.String name,
                                                   java.lang.String entityName,
                                                   java.lang.String description,
                                                   java.util.Collection<AttributeRef> attrRefs,
                                                   java.util.Collection<PredicateRef> predicateRefs,
                                                   java.util.Collection<RoleRef> roleRefs,
                                                   IPolicy txnPolicy)
                                            throws InitializedException,
                                                   UndefinedException
Method to define an interaction for the purpose of performing reads. Reads are used to retrieve attributes, predicates and roles about subjects. This method uses Attribute, Predicate, and Role Reference objects to allow specification of policy specific to each attribute, predicate, or policy.

Parameters:
name - The name of the interaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly description of why the application is performing the read.
attrRefs - The attributes that are to be added in an read operation.
predicateRefs - The predicates that are to be tested in the read operation.
roleRefs - The roles that the interaction is to report on or test for presence.
txnPolicy - The policy that is associated with this interaction
Returns:
an IReadInteraction to perform reads as declared.
Throws:
InitializedException
UndefinedException

createReadInteraction

public IReadInteraction createReadInteraction(java.lang.String name,
                                              java.lang.String description,
                                              java.util.Collection<AttributeDef> attrDefs,
                                              java.util.Collection<PredicateDef> predDefs,
                                              java.util.Collection<RoleDef> roleDefs,
                                              IPolicy txnPolicy)
                                       throws InitializedException,
                                              UndefinedException
Deprecated. Use createReadInteraction(String,String,String,Collection,Collection,Collection,IPolicy) instead

Method to define an interaction for the purpose of performing reads. Reads are used to retrieve attributes, predicates and roles about subjects. This method signature assumes there is no specific attribute, predicate, or role specific policy. All attributes, predicates, roles will be presumed to be required (the default).

Parameters:
name - The name of the interaction
description - A friendly description of why the application is performing the read.
attrDefs - The attributes that are to be added in an read operation.
predDefs - The predicates that are to be tested in the read operation.
roleDefs - The roles that the interaction is to report on or test for presence.
txnPolicy - The policy that is associated with this interaction
Returns:
an IReadInteraction to perform reads as declared.
Throws:
InitializedException
UndefinedException

createReadInteraction

public IReadInteraction createReadInteraction(java.lang.String name,
                                              java.lang.String entityName,
                                              java.lang.String description,
                                              java.util.Collection<AttributeDef> attrDefs,
                                              java.util.Collection<PredicateDef> predDefs,
                                              java.util.Collection<RoleDef> roleDefs,
                                              IPolicy txnPolicy)
                                       throws InitializedException,
                                              UndefinedException
Method to define an interaction for the purpose of performing reads. Reads are used to retrieve attributes, predicates and roles about subjects. This method signature assumes there is no specific attribute, predicate, or role specific policy. All attributes, predicates, roles will be presumed to be required (the default).

Parameters:
name - The name of the interaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly description of why the application is performing the read.
attrDefs - The attributes that are to be added in an read operation.
predDefs - The predicates that are to be tested in the read operation.
roleDefs - The roles that the interaction is to report on or test for presence.
txnPolicy - The policy that is associated with this interaction
Returns:
an IReadInteraction to perform reads as declared.
Throws:
InitializedException
UndefinedException

createSearchInteraction

public ISearchInteraction createSearchInteraction(java.lang.String name,
                                                  java.lang.String description,
                                                  Filter filter,
                                                  java.util.Collection<AttributeDef> attrDefs,
                                                  java.util.Collection<PredicateDef> predDefs,
                                                  java.util.Collection<RoleDef> roleDefs,
                                                  IPolicy txnPolicy,
                                                  int maxSubjects,
                                                  int pageSize)
                                           throws InitializedException,
                                                  UndefinedException
Deprecated. Use createSearchInteraction(String,String,String,Filter,Collection,Collection,Collection,IPolicy,int,int) instead

Creates an Interaction declaration used for the purpose of searching attribute authorities for one or more subjects that match a certain criteria.

Parameters:
name - A name identifier for the transaction
description - A friendly description of the transaction and its intended function or purpose.
filter - A filters that will be used to match subjects in the attribute authority(ies).
attrDefs - The attributes that are to be returned in the search operation.
predDefs - The predicates that are to be returned in the search operation.
roleDefs - The roles that the interaction is to report on or test for presence.
txnPolicy - Any associated transaction policy.
maxSubjects - The maximum number of subjects to return on a search.
pageSize - The preferred paging size for performance optimization.
Returns:
an ISearchInteraction to perform searches as declared.
Throws:
InitializedException
UndefinedException

createSearchInteraction

public ISearchInteraction createSearchInteraction(java.lang.String name,
                                                  java.lang.String entityName,
                                                  java.lang.String description,
                                                  Filter filter,
                                                  java.util.Collection<AttributeDef> attrDefs,
                                                  java.util.Collection<PredicateDef> predDefs,
                                                  java.util.Collection<RoleDef> roleDefs,
                                                  IPolicy txnPolicy,
                                                  int maxSubjects,
                                                  int pageSize)
                                           throws InitializedException,
                                                  UndefinedException
Creates an Interaction declaration used for the purpose of searching attribute authorities for one or more subjects that match a certain criteria.

Parameters:
name - A name identifier for the transaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly description of the transaction and its intended function or purpose.
filter - A filters that will be used to match subjects in the attribute authority(ies).
attrDefs - The attributes that are to be returned in the search operation.
predDefs - The predicates that are to be returned in the search operation.
roleDefs - The roles that the interaction is to report on or test for presence.
txnPolicy - Any associated transaction policy.
maxSubjects - The maximum number of subjects to return on a search.
pageSize - The preferred paging size for performance optimization.
Returns:
an ISearchInteraction to perform searches as declared.
Throws:
InitializedException
UndefinedException

createSearchInteractionByRef

public ISearchInteraction createSearchInteractionByRef(java.lang.String name,
                                                       java.lang.String description,
                                                       Filter filter,
                                                       java.util.Collection<AttributeRef> attrRefs,
                                                       java.util.Collection<PredicateRef> predRefs,
                                                       java.util.Collection<RoleRef> roleRefs,
                                                       IPolicy txnPolicy,
                                                       int maxSubjects,
                                                       int pageSize)
                                                throws InitializedException,
                                                       UndefinedException
Deprecated. Use createSearchInteractionByRef(String, String, Filter, Collection, Collection, Collection, IPolicy, int, int) instead

Creates an Interaction declaration used for the purpose of searching attribute authorities for one or more subjects that match a certain criteria. Note:

Parameters:
name - A name identifier for the transaction
description - A friendly description of the transaction and its intended function or purpose.
filter - A filters that will be used to match subjects in the attribute authority(ies).
attrRefs - The attributes that are to be returned in the search operation.
predRefs - The predicates that are to be returned in the search operation.
roleRefs - The roles that the interaction is to report on or test for presence.
txnPolicy - Any associated transaction policy
maxSubjects - The maximum number of subjects to return on a search.
pageSize - The preferred paging size for performance optimization.
Returns:
an ISearchInteraction to perform searches as declared.
Throws:
InitializedException
UndefinedException

createSearchInteractionByRef

public ISearchInteraction createSearchInteractionByRef(java.lang.String name,
                                                       java.lang.String entityName,
                                                       java.lang.String description,
                                                       Filter filter,
                                                       java.util.Collection<AttributeRef> attrRefs,
                                                       java.util.Collection<PredicateRef> predRefs,
                                                       java.util.Collection<RoleRef> roleRefs,
                                                       IPolicy txnPolicy,
                                                       int maxSubjects,
                                                       int pageSize)
                                                throws InitializedException,
                                                       UndefinedException
Creates an Interaction declaration used for the purpose of searching attribute authorities for one or more subjects that match a certain criteria. Note:

Parameters:
name - A name identifier for the transaction
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly description of the transaction and its intended function or purpose.
filter - A filters that will be used to match subjects in the attribute authority(ies).
attrRefs - The attributes that are to be returned in the search operation.
predRefs - The predicates that are to be returned in the search operation.
roleRefs - The roles that the interaction is to report on or test for presence.
txnPolicy - Any associated transaction policy
maxSubjects - The maximum number of subjects to return on a search.
pageSize - The preferred paging size for performance optimization.
Returns:
an ISearchInteraction to perform searches as declared.
Throws:
InitializedException
UndefinedException

createModifyInteractionByRef

public IModifyInteraction createModifyInteractionByRef(java.lang.String name,
                                                       java.lang.String description,
                                                       java.util.Collection<AttributeRef> attrRefs,
                                                       java.util.Collection<RoleRef> roleRefs,
                                                       IPolicy txnPolicy)
                                                throws InitializedException,
                                                       UndefinedException
Deprecated. Use createModifyInteractionByRef(String,String,String,Collection,Collection,IPolicy) instead

Creates a modify interaction for the purpose of modifying subjects.

Parameters:
name - A name identifier for the transaction.
description - A friendly name describing the transaction's purpose.
attrRefs - The attributes that are modified defined using AttributeRef objects.
roleRefs - The roles that may be modified defined using RoleRef objects.
txnPolicy - Any associated policy relating to the Interaction.
Returns:
an IModifyInteraction to perform modifies as declared.
Throws:
InitializedException
UndefinedException

createModifyInteractionByRef

public IModifyInteraction createModifyInteractionByRef(java.lang.String name,
                                                       java.lang.String entityName,
                                                       java.lang.String description,
                                                       java.util.Collection<AttributeRef> attrRefs,
                                                       java.util.Collection<RoleRef> roleRefs,
                                                       IPolicy txnPolicy)
                                                throws InitializedException,
                                                       UndefinedException
Creates a modify interaction for the purpose of modifying subjects.

Parameters:
name - A name identifier for the transaction.
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly name describing the transaction's purpose.
attrRefs - The attributes that are modified defined using AttributeRef objects.
roleRefs - The roles that may be modified defined using RoleRef objects.
txnPolicy - Any associated policy relating to the Interaction.
Returns:
an IModifyInteraction to perform modifies as declared.
Throws:
InitializedException
UndefinedException

createModifyInteraction

public IModifyInteraction createModifyInteraction(java.lang.String name,
                                                  java.lang.String description,
                                                  java.util.Collection<AttributeDef> attrDefs,
                                                  java.util.Collection<RoleDef> roleDefs,
                                                  IPolicy txnPolicy)
                                           throws InitializedException,
                                                  UndefinedException
Deprecated. Use createModifyInteractionByRef(String, String, Collection, Collection, IPolicy) instead

Creates a modify interaction for the purpose of modifying subjects. This method assumes there are no attribute or role specific policies.

Parameters:
name - A name identifier for the transaction.
description - A friendly name describing the transaction's purpose.
attrDefs - The attributes that are modified.
roleDefs - The roles that may be modified.
txnPolicy - Any associated policy relating to the Interaction.
Returns:
an IModifyInteraction to perform modifies as declared.
Throws:
InitializedException
UndefinedException

createModifyInteraction

public IModifyInteraction createModifyInteraction(java.lang.String name,
                                                  java.lang.String entityName,
                                                  java.lang.String description,
                                                  java.util.Collection<AttributeDef> attrDefs,
                                                  java.util.Collection<RoleDef> roleDefs,
                                                  IPolicy txnPolicy)
                                           throws InitializedException,
                                                  UndefinedException
Creates a modify interaction for the purpose of modifying subjects. This method assumes there are no attribute or role specific policies.

Parameters:
name - A name identifier for the transaction.
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly name describing the transaction's purpose.
attrDefs - The attributes that are modified.
roleDefs - The roles that may be modified.
txnPolicy - Any associated policy relating to the Interaction.
Returns:
an IModifyInteraction to perform modifies as declared.
Throws:
InitializedException
UndefinedException

createDeleteInteraction

public IDeleteInteraction createDeleteInteraction(java.lang.String name,
                                                  java.lang.String description,
                                                  IPolicy txnPolicy)
                                           throws InitializedException,
                                                  UndefinedException
Deprecated. Use createDeleteInteraction(String,String,String,IPolicy) instead

Create an interaction for the purpose of performing deletions of subjects.

Parameters:
name - A name identifier for the transaction.
description - A friendly description describing the intent of the deletion.
txnPolicy - Any associated policy relating to the delete operation.
Returns:
an IDeleteInteraction to perform deletes as declared.
Throws:
InitializedException
UndefinedException

createDeleteInteraction

public IDeleteInteraction createDeleteInteraction(java.lang.String name,
                                                  java.lang.String entityName,
                                                  java.lang.String description,
                                                  IPolicy txnPolicy)
                                           throws InitializedException,
                                                  UndefinedException
Create an interaction for the purpose of performing deletions of subjects.

Parameters:
name - A name identifier for the transaction.
entityName - A space (or tab or newline) separated list of entityNames with which the Interaction is associated with
description - A friendly description describing the intent of the deletion.
txnPolicy - Any associated policy relating to the delete operation.
Returns:
an IDeleteInteraction to perform deletes as declared.
Throws:
InitializedException
UndefinedException

getInteractions

public java.util.Collection<IInteraction> getInteractions()
Returns all defined Interactions

Returns:
A Collection of IInteraction objects (may be empty)

getInteractionsByEntity

public java.util.Collection<IInteraction> getInteractionsByEntity(java.lang.String entityName)
Returns Interactions associated with a particular EntityName or null;

Parameters:
entityName - A single name of an entity to return Interactions for. EntityName may be null or "DEFAULT" in the case of a default object definition.
Returns:
A Collection of IInteraction for a specific entity name. A null is returned if no entityName exists in the CARML declaration.

getEntityNames

public java.util.Collection<java.lang.String> getEntityNames()
Returns:
A set of String defining the EntityNames defined in the CARML document. Note: the name "DEFAULT" is used for any interactions defined with no entityName.

OpenLiberty.org - Licensed under Apache APL 2.0