Class: SAML2::RequestedAuthnContext
- Defined in:
- lib/saml2/requested_authn_context.rb
Instance Attribute Summary collapse
Attributes inherited from Base
Instance Method Summary collapse
-
#build(builder) ⇒ void
Serialize this object to XML, as part of a larger document.
-
#from_xml(node) ⇒ void
Parse an XML element into this object.
Methods inherited from Base
#decrypt, from_xml, #initialize, #inspect, load_object_array, load_string_array, lookup_qname, #to_s, #to_xml
Constructor Details
This class inherits a constructor from SAML2::Base
Instance Attribute Details
#class_ref ⇒ String+
10 11 12 |
# File 'lib/saml2/requested_authn_context.rb', line 10 def class_ref @class_ref end |
#comparison ⇒ String?
8 9 10 |
# File 'lib/saml2/requested_authn_context.rb', line 8 def comparison @comparison end |
Instance Method Details
#build(builder) ⇒ void
This method returns an undefined value.
Serialize this object to XML, as part of a larger document
19 20 21 22 23 24 25 26 |
# File 'lib/saml2/requested_authn_context.rb', line 19 def build(builder) builder["samlp"].RequestedAuthnContext do |requested_authn_context| requested_authn_context.parent["Comparison"] = comparison.to_s if comparison Array(class_ref).each do |individual_class_ref| requested_authn_context["saml"].AuthnContextClassRef(individual_class_ref) end end end |
#from_xml(node) ⇒ void
This method returns an undefined value.
Parse an XML element into this object.
13 14 15 16 |
# File 'lib/saml2/requested_authn_context.rb', line 13 def from_xml(node) super @class_ref = load_string_array(node, "saml:AuthnContextClassRef") end |