|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.neethi.PolicyBuilder
public class PolicyBuilder
PolicyBuilder provides set of methods to create a Policy object from an InputStream, Element, XMLStreamReader, OMElement, etc.. It maintains an instance of AssertionBuilderFactory that can return AssertionBuilders that can create a Domain Assertion out of an element. These AssertionBuilders are used when constructing a Policy object.
Field Summary | |
---|---|
protected PolicyRegistry |
defaultPolicyRegistry
|
protected AssertionBuilderFactory |
factory
|
Constructor Summary | |
---|---|
PolicyBuilder()
|
|
PolicyBuilder(AssertionBuilderFactory factory)
|
Method Summary | |
---|---|
AssertionBuilderFactory |
getAssertionBuilderFactory()
|
Policy |
getPolicy(Element el)
|
Policy |
getPolicy(InputStream inputStream)
Creates a Policy object from an InputStream. |
Policy |
getPolicy(Object element)
Creates a Policy object from an element. |
Policy |
getPolicy(javax.xml.stream.XMLStreamReader reader)
|
PolicyReference |
getPolicyReference(InputStream inputStream)
Creates a PolicyReference object. |
PolicyReference |
getPolicyReference(Object element)
Creates a PolicyReference object from an element. |
PolicyRegistry |
getPolicyRegistry()
The PolicyEngine can have a default PolicyRegistry that the Policy objects that it creates are setup to use when normalize is called without the PolicyRegistry. |
protected void |
notifyUnknownPolicyElement(Object childElement)
|
void |
registerBuilder(QName qname,
AssertionBuilder<?> builder)
Registers an AssertionBuilder instances and associates it with a QName. |
void |
setPolicyRegistry(PolicyRegistry reg)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected AssertionBuilderFactory factory
protected PolicyRegistry defaultPolicyRegistry
Constructor Detail |
---|
public PolicyBuilder()
public PolicyBuilder(AssertionBuilderFactory factory)
Method Detail |
---|
public void registerBuilder(QName qname, AssertionBuilder<?> builder)
qname
- the QName of the Assertion that the Builder can buildbuilder
- the AssertionBuilder that can build assertions that of 'qname'
typepublic PolicyRegistry getPolicyRegistry()
public void setPolicyRegistry(PolicyRegistry reg)
public AssertionBuilderFactory getAssertionBuilderFactory()
public Policy getPolicy(InputStream inputStream)
inputStream
- the InputStream of the Policy
public Policy getPolicy(Element el)
public Policy getPolicy(javax.xml.stream.XMLStreamReader reader)
public Policy getPolicy(Object element)
element
- the Policy element
public PolicyReference getPolicyReference(InputStream inputStream)
inputStream
- the InputStream of the PolicyReference
public PolicyReference getPolicyReference(Object element)
element
- the PolicyReference element
protected void notifyUnknownPolicyElement(Object childElement)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |