Sha256: 382ceaeb231b729e33ff061577a79562a8501ce3c3b1550fb5fc292768cd1322

Contents?: true

Size: 537 Bytes

Versions: 8

Compression:

Stored size: 537 Bytes

Contents

module Saml
  module Elements
    class AttributeStatement
      include Saml::Base

      tag 'AttributeStatement'
      register_namespace 'saml', Saml::SAML_NAMESPACE
      namespace 'saml'

      has_many :attribute, Saml::Elements::Attribute
      has_many :encrypted_attributes, Saml::Elements::EncryptedAttribute

      def fetch_attribute(key)
        fetch_attributes(key).first
      end

      def fetch_attributes(key)
        attribute.find_all { |attr| attr.name == key }.map(&:attribute_value)
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
libsaml-2.7.0 lib/saml/elements/attribute_statement.rb
libsaml-2.6.9 lib/saml/elements/attribute_statement.rb
libsaml-2.6.8 lib/saml/elements/attribute_statement.rb
libsaml-2.6.7 lib/saml/elements/attribute_statement.rb
libsaml-2.6.6 lib/saml/elements/attribute_statement.rb
libsaml-2.6.4 lib/saml/elements/attribute_statement.rb
libsaml-2.6.2 lib/saml/elements/attribute_statement.rb
libsaml-2.6.1 lib/saml/elements/attribute_statement.rb