Class ContactPersonBuilder
java.lang.Object
se.swedenconnect.opensaml.common.builder.AbstractSAMLObjectBuilder<org.opensaml.saml.saml2.metadata.ContactPerson>
se.swedenconnect.opensaml.saml2.metadata.build.ContactPersonBuilder
- All Implemented Interfaces:
SAMLObjectBuilder<org.opensaml.saml.saml2.metadata.ContactPerson>
public class ContactPersonBuilder
extends AbstractSAMLObjectBuilder<org.opensaml.saml.saml2.metadata.ContactPerson>
A builder for
ContactPerson
elements.- Author:
- Martin Lindström (martin@idsec.se)
-
Constructor Summary
ConstructorDescriptionDefault constructor.ContactPersonBuilder
(org.opensaml.saml.saml2.metadata.ContactPerson template) Creates a builder from an object template. -
Method Summary
Modifier and TypeMethodDescriptionstatic ContactPersonBuilder
builder()
Creates a builder instance.static ContactPersonBuilder
builder
(org.opensaml.saml.saml2.metadata.ContactPerson template) Creates a builder instance.Assigns theCompany
element.emailAddresses
(String... emailAddresses) emailAddresses
(List<String> emailAddresses) Assigns theEmailAddress
elements.protected Class
<org.opensaml.saml.saml2.metadata.ContactPerson> Returns the object type.Assigns theGivenName
element.Assigns theSurName
element.telephoneNumbers
(String... telephoneNumbers) telephoneNumbers
(List<String> telephoneNumbers) Assigns theTelephoneNumber
elements.type
(org.opensaml.saml.saml2.metadata.ContactPersonTypeEnumeration type) Assigns the type of contact person.Methods inherited from class se.swedenconnect.opensaml.common.builder.AbstractSAMLObjectBuilder
build, getDefaultElementName, object
-
Constructor Details
-
ContactPersonBuilder
public ContactPersonBuilder()Default constructor. -
ContactPersonBuilder
public ContactPersonBuilder(org.opensaml.saml.saml2.metadata.ContactPerson template) throws org.opensaml.core.xml.io.MarshallingException, org.opensaml.core.xml.io.UnmarshallingException Creates a builder from an object template.- Parameters:
template
- the object template- Throws:
org.opensaml.core.xml.io.MarshallingException
- for marshalling errorsorg.opensaml.core.xml.io.UnmarshallingException
- for unmarshalling errors
-
-
Method Details
-
builder
Creates a builder instance.- Returns:
- a builder instance
-
builder
public static ContactPersonBuilder builder(org.opensaml.saml.saml2.metadata.ContactPerson template) throws org.opensaml.core.xml.io.MarshallingException, org.opensaml.core.xml.io.UnmarshallingException Creates a builder instance.- Parameters:
template
- the object template- Returns:
- a builder instance
- Throws:
org.opensaml.core.xml.io.MarshallingException
- for marshalling errorsorg.opensaml.core.xml.io.UnmarshallingException
- for unmarshalling errors
-
type
public ContactPersonBuilder type(org.opensaml.saml.saml2.metadata.ContactPersonTypeEnumeration type) Assigns the type of contact person.- Parameters:
type
- the type- Returns:
- the builder
-
company
Assigns theCompany
element.- Parameters:
company
- the company- Returns:
- the builder
-
givenName
Assigns theGivenName
element.- Parameters:
givenName
- the name- Returns:
- the builder
-
surname
Assigns theSurName
element.- Parameters:
surname
- the name- Returns:
- the builder
-
emailAddresses
Assigns theEmailAddress
elements.- Parameters:
emailAddresses
- the email addresses- Returns:
- the builder
-
emailAddresses
- Parameters:
emailAddresses
- the email addresses- Returns:
- the builder
- See Also:
-
telephoneNumbers
Assigns theTelephoneNumber
elements.- Parameters:
telephoneNumbers
- the numbers to assign- Returns:
- the builder
-
telephoneNumbers
- Parameters:
telephoneNumbers
- the numbers to assign- Returns:
- the builder
- See Also:
-
getObjectType
Returns the object type.- Specified by:
getObjectType
in classAbstractSAMLObjectBuilder<org.opensaml.saml.saml2.metadata.ContactPerson>
- Returns:
- the object type
-