Package oracle.security.xs
Interface SessionNamespace
-
public interface SessionNamespaceThis interface represents a set of name/value (SessionNamespaceAttibute) pairs associated withSession, which are commonly used to record application state, user profile, and so on.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classSessionNamespace.ATTR_EVENT_TYPEThe list of possible events an attribute can have.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SessionNamespaceAttributecreateAttribute(java.lang.String name, java.lang.String value)Creates a new attribute in the namespace with the specified name and value.SessionNamespaceAttributecreateAttribute(java.lang.String name, java.lang.String value, java.util.List<SessionNamespace.ATTR_EVENT_TYPE> event)Creates a new attribute in the namespace with the specified name, value, and event.voiddeleteAttribute(java.lang.String name)Deletes the specified attributeSessionNamespaceAttributegetAttribute(java.lang.String name)" Returns the specified attribute."java.util.Collection<SessionNamespaceAttribute>getAttributes()Returns a collection of the attribute names in the namespace.java.lang.StringgetName()Returns the name of the namespaceSessionNamespaceAttributeresetAttribute(java.lang.String name)Resets the specified attribute in the namespace to its default value.SessionNamespaceAttributesetAttribute(java.lang.String name, java.lang.String value)Sets the attribute for a session namespace with the specified name and valuejava.lang.StringtoString()Returns a string representation of the namespace
-
-
-
Method Detail
-
getAttributes
java.util.Collection<SessionNamespaceAttribute> getAttributes()
Returns a collection of the attribute names in the namespace.- Returns:
- An enumeration of of attribute objects
-
createAttribute
SessionNamespaceAttribute createAttribute(java.lang.String name, java.lang.String value) throws java.sql.SQLException, SessionNamespaceException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
Creates a new attribute in the namespace with the specified name and value.- Parameters:
name- name of the attributevalue- value of the attribute- Returns:
- the newly created attribute
- Throws:
java.sql.SQLException- when a JDBC exception is thrownAccessDeniedException- when the current user does not have the privilege to attach to the sessionXSException- when a generic error is detectedSessionNamespaceException- when the attibute name is invalidInvalidXSAttributeException- when the attribute value is invalidNotAttachedException- when the session is not attached
-
createAttribute
SessionNamespaceAttribute createAttribute(java.lang.String name, java.lang.String value, java.util.List<SessionNamespace.ATTR_EVENT_TYPE> event) throws java.sql.SQLException, SessionNamespaceException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
Creates a new attribute in the namespace with the specified name, value, and event.- Parameters:
name- name of the attributevalue- value of the attributeevent- event registration of the attribute- Returns:
- the newly created attribute
- Throws:
java.sql.SQLException- when a JDBC exception is thrownAccessDeniedException- when the current user does not have the privilege to attach to the sessionXSException- when a generic error is detectedSessionNamespaceException- when the attibute name is invalidInvalidXSAttributeException- when the attribute value is invalidNotAttachedException- when the session is not attached
-
resetAttribute
SessionNamespaceAttribute resetAttribute(java.lang.String name) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
Resets the specified attribute in the namespace to its default value.- Parameters:
name- name of the attribute- Returns:
- the attribute that has been reset
- Throws:
java.sql.SQLException- when a JDBC exception is thrownAccessDeniedException- when the current user does not have the privilege to reset the attributeXSException- when a generic error is detectedInvalidXSAttributeException- when the attribute is invalidNotAttachedException- when the session is not attached
-
setAttribute
SessionNamespaceAttribute setAttribute(java.lang.String name, java.lang.String value) throws java.sql.SQLException, SessionNamespaceException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
Sets the attribute for a session namespace with the specified name and value- Parameters:
name- name of the attributevalue- value of the attribute- Returns:
- SessionNamespaceAttribute attribute object whose value is set
- Throws:
java.sql.SQLException- when a JDBC exception is thrownAccessDeniedException- when the current user does not have the privilege to set the attributeXSException- when a generic error is detectedSessionNamespaceException- when the namespace is invalidInvalidXSAttributeException- when the attribute is invalidNotAttachedException- when the session is not attached
-
getAttribute
SessionNamespaceAttribute getAttribute(java.lang.String name) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
" Returns the specified attribute."- Parameters:
name- the name of the attribute in the namespace- Returns:
- the specified session attribute (null if not found)
- Throws:
java.sql.SQLException- when a JDBC exception is thrownAccessDeniedException- when the current user does not have the privilege to get the attributeXSException- when a generic error is detectedInvalidXSAttributeException- when the attribute is invalidNotAttachedException- when the session is not attached
-
deleteAttribute
void deleteAttribute(java.lang.String name) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedExceptionDeletes the specified attribute- Parameters:
name- name of the attribute- Throws:
java.sql.SQLException- when a JDBC exception is thrownAccessDeniedException- when the current user does not have the privilege to delete the attributeXSException- when a generic error is detectedInvalidXSAttributeException- when the attribute is invalidNotAttachedException- when the session is not attached
-
getName
java.lang.String getName()
Returns the name of the namespace- Returns:
- The String corresponding to the name for the namespace
-
toString
java.lang.String toString()
Returns a string representation of the namespace- Overrides:
toStringin classjava.lang.Object- Returns:
- a string representation of the namespace
-
-