Class AttributeTemplate

java.lang.Object
se.swedenconnect.opensaml.saml2.attribute.AttributeTemplate
All Implemented Interfaces:
Serializable

public class AttributeTemplate extends Object implements Serializable
An attribute template is a template of a SAML attribute, i.e., it represents the name, friendly name and name format but not the value of the attribute.

A template may be useful when defining attribute sets and/or attribute release policies.

Author:
Martin Lindström (martin@idsec.se)
See Also:
  • Constructor Details

    • AttributeTemplate

      public AttributeTemplate(String name, String friendlyName)
      Creates an attribute template with the given name and friendly name, the default name format urn:oasis:names:tc:SAML:2.0:attrname-format:uri (Attribute.URI_REFERENCE) and not multi-valued.
      Parameters:
      name - the attribute name
      friendlyName - the attribute friendly name (optional)
    • AttributeTemplate

      public AttributeTemplate(String name, String friendlyName, String nameFormat)
      Creates an attribute template with the given name, friendly name and name format.
      Parameters:
      name - the attribute name
      friendlyName - the attribute friendly name
      nameFormat - the name format
  • Method Details

    • getName

      public String getName()
      Get the name of this attribute template.
      Returns:
      the name of this attribute template
    • getFriendlyName

      public String getFriendlyName()
      Get the friendly name of this attribute template.
      Returns:
      the friendly name of this attribute template
    • getNameFormat

      public String getNameFormat()
      Get the name format of this attribute template.
      Returns:
      the name format of this attribute template
    • createBuilder

      public AttributeBuilder createBuilder()
      Based on the attribute template an AttributeBuilder object is created.
      Returns:
      a builder