T
- the typepublic abstract class AbstractSAMLObjectBuilder<T extends SAMLObject> extends Object implements SAMLObjectBuilder<T>
Constructor and Description |
---|
AbstractSAMLObjectBuilder()
Constructor setting up the object to build.
|
AbstractSAMLObjectBuilder(InputStream resource)
Constructor setting up the builder with a template object that is read from an input stream.
|
AbstractSAMLObjectBuilder(T template)
Constructor setting up the builder with a template object.
|
Modifier and Type | Method and Description |
---|---|
T |
build()
The default implementation of this method assumes that the object has been built during assignment of its
attributes and elements so it simply returns the object.
|
protected abstract Class<T> |
getObjectType()
Returns the object type.
|
T |
object()
Returns the object being built.
|
public AbstractSAMLObjectBuilder()
public AbstractSAMLObjectBuilder(T template) throws MarshallingException, UnmarshallingException
Note that the supplied object is cloned, so any modifications have no effect on the passed object.
template
- the template objectUnmarshallingException
- for unmarshalling errorsMarshallingException
- for marshalling errorspublic AbstractSAMLObjectBuilder(InputStream resource) throws XMLParserException, UnmarshallingException
resource
- the template resourceUnmarshallingException
- for unmarshalling errorsXMLParserException
- for XML parsing errorspublic T build()
Implementations that need to perform additional processing during the build step should override this method.
build
in interface SAMLObjectBuilder<T extends SAMLObject>
protected abstract Class<T> getObjectType()
public final T object()
Copyright © 2018 Litsec AB. All rights reserved.