Class: NominetEPP::Request
- Inherits:
-
Object
- Object
- NominetEPP::Request
- Defined in:
- lib/nominet-epp/request.rb
Direct Known Subclasses
Contact::Check, Contact::Create, Contact::Delete, Contact::Info, Contact::Update, CustomRequest, Domain::Check, Domain::Create, Domain::Delete, Domain::Info, Domain::Renew, Domain::Request, Domain::Update, Host::Check, Host::Create, Host::Delete, Host::Info, Host::Update
Instance Attribute Summary collapse
-
#command ⇒ Object
readonly
Returns the value of attribute command.
-
#extension ⇒ Object
readonly
Returns the value of attribute extension.
Instance Method Summary collapse
- #command_name ⇒ Object
- #namespaces ⇒ Object
-
#xml_namespace(node, name, uri, namespaces = {}) ⇒ XML::Namespace
Creates and returns a new XML namespace.
-
#xml_node(name, value = nil) ⇒ XML::Node
Creates and returns a new XML node.
Instance Attribute Details
#command ⇒ Object (readonly)
Returns the value of attribute command.
3 4 5 |
# File 'lib/nominet-epp/request.rb', line 3 def command @command end |
#extension ⇒ Object (readonly)
Returns the value of attribute extension.
3 4 5 |
# File 'lib/nominet-epp/request.rb', line 3 def extension @extension end |
Instance Method Details
#command_name ⇒ Object
5 6 7 |
# File 'lib/nominet-epp/request.rb', line 5 def command_name @command_name ||= command.name end |
#namespaces ⇒ Object
9 10 11 12 |
# File 'lib/nominet-epp/request.rb', line 9 def namespaces ext_ns = @extension && @extension.namespaces || {} @command.namespaces.merge(ext_ns) end |
#xml_namespace(node, name, uri, namespaces = {}) ⇒ XML::Namespace
Creates and returns a new XML namespace
29 30 31 |
# File 'lib/nominet-epp/request.rb', line 29 def xml_namespace(node, name, uri, namespaces = {}) XML::Namespace.new(node, name, uri) end |
#xml_node(name, value = nil) ⇒ XML::Node
Creates and returns a new XML node
19 20 21 |
# File 'lib/nominet-epp/request.rb', line 19 def xml_node(name, value = nil) XML::Node.new(name, value) end |