class Oga::XML::Namespace

The Namespace class contains information about XML namespaces such as the name and URI.

Attributes

name[RW]

@return [String]

uri[RW]

@return [String]

Public Class Methods

new(options = {}) click to toggle source

@param [Hash] options

@option options [String] :name @option options [String] :uri

# File lib/oga/xml/namespace.rb, line 16
def initialize(options = {})
  @name = options[:name]
  @uri  = options[:uri]
end

Public Instance Methods

==(other) click to toggle source

@param [Oga::XML::Namespace] other @return [TrueClass|FalseClass]

# File lib/oga/xml/namespace.rb, line 33
def ==(other)
  other.is_a?(self.class) && name == other.name && uri == other.uri
end
inspect() click to toggle source

@return [String]

# File lib/oga/xml/namespace.rb, line 27
def inspect
  "Namespace(name: #{name.inspect} uri: #{uri.inspect})"
end
to_s() click to toggle source

@return [String]

# File lib/oga/xml/namespace.rb, line 22
def to_s
  name.to_s
end