Class PrivilegeDefinitionReader
java.lang.Object
org.apache.jackrabbit.spi.commons.privilege.PrivilegeDefinitionReader
Reads privilege definitions for the specified
InputStream. Note,
that this reader will not apply any validation.-
Constructor Summary
ConstructorsConstructorDescriptionPrivilegeDefinitionReader(InputStream in, String contentType) Creates a newPrivilegeDefinitionReaderfor the given input stream.PrivilegeDefinitionReader(Reader reader, String contentType) Creates a newPrivilegeDefinitionReaderfor the given input stream. -
Method Summary
Modifier and TypeMethodDescriptionReturns the namespace mappings such as retrieved during parsing.Returns the privilege definitions retrieved from the input stream.
-
Constructor Details
-
PrivilegeDefinitionReader
Creates a newPrivilegeDefinitionReaderfor the given input stream. The specified content type is used in order to determine the type of privilege serialization.- Parameters:
in- The input stream to read the privilege definitions from.contentType- Currently only types supported byPrivilegeXmlHandler.isSupportedContentType(String)are allowed.- Throws:
ParseException- If an error occurs.IllegalArgumentException- if the specified content type is not supported.
-
PrivilegeDefinitionReader
Creates a newPrivilegeDefinitionReaderfor the given input stream. The specified content type is used in order to determine the type of privilege serialization.- Parameters:
reader- The reader to read the privilege definitions from.contentType- Currently only types supported byPrivilegeXmlHandler.isSupportedContentType(String)are allowed.- Throws:
ParseException- If an error occurs.IllegalArgumentException- if the specified content type is not supported.
-
-
Method Details
-
getPrivilegeDefinitions
Returns the privilege definitions retrieved from the input stream.- Returns:
- an array of
PrivilegeDefinition
-
getNamespaces
Returns the namespace mappings such as retrieved during parsing.- Returns:
- a mapping of namespace prefix to uri used by the privilege definitions.
-