Class: Nexpose::Header
- Inherits:
-
Object
- Object
- Nexpose::Header
- Includes:
- XMLUtils
- Defined in:
- lib/nexpose/creds.rb
Overview
Object that represents Header name-value pairs, associated with Web Session Authentication.
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Name, one per Header.
-
#value ⇒ Object
readonly
Value, one per Header.
Instance Method Summary collapse
-
#initialize(name, value) ⇒ Header
constructor
Construct with name value pair.
- #to_xml_elem ⇒ Object
Methods included from XMLUtils
Constructor Details
#initialize(name, value) ⇒ Header
Construct with name value pair
119 120 121 122 |
# File 'lib/nexpose/creds.rb', line 119 def initialize(name, value) @name = name @value = value end |
Instance Attribute Details
#name ⇒ Object (readonly)
Name, one per Header
114 115 116 |
# File 'lib/nexpose/creds.rb', line 114 def name @name end |
#value ⇒ Object (readonly)
Value, one per Header
116 117 118 |
# File 'lib/nexpose/creds.rb', line 116 def value @value end |
Instance Method Details
#to_xml_elem ⇒ Object
124 125 126 127 128 129 130 |
# File 'lib/nexpose/creds.rb', line 124 def to_xml_elem attributes = {} attributes['name'] = @name attributes['value'] = @value make_xml('Header', attributes) end |