class SAML::Metadata::EntitiesDescriptor

Attributes

entity_descriptors[R]

Public Class Methods

from_xml(xml) click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 7
def self.from_xml(xml)
  allocate.from_xml(xml)
end

Public Instance Methods

from_xml(xml) click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 11
def from_xml(xml)
  @entity_descriptors = xml.get_elements('md:EntityDescriptor').map do |ed_node|
    EntityDescriptor.from_xml(ed_node)
  end
  self
end
idp() click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 25
def idp
  @entity_descriptors.each do |entity|
    return entity if entity.idp?
  end
  nil
end
idp_single_signon_service() click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 40
def idp_single_signon_service
  idp.idp_sso_descriptors.first.single_signon_services.first
end
sp() click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 18
def sp
  @entity_descriptors.each do |entity|
    return entity if entity.sp?
  end
  nil
end
sp_assertion_consumer_service() click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 32
def sp_assertion_consumer_service
  sp.sp_sso_descriptors.first.assertion_consumer_services.first
end
sp_single_logout_service() click to toggle source
# File lib/saml/metadata/entities_descriptor.rb, line 36
def sp_single_logout_service
  sp.sp_sso_descriptors.first.single_logout_services.first
end