class RubyNos::Endpoint

Constants

ALLOWED_TYPES

Attributes

host[RW]
path[RW]
port[RW]
priority[RW]
sticky[RW]
type[RW]

Public Instance Methods

to_hash() click to toggle source
# File lib/ruby_nos/endpoint.rb, line 32
def to_hash
  {
      pa: self.path,
      po: self.port,
      st: self.sticky,
      ty: self.type,
      xp: self.priority,
      ho: self.host
  }
end
type=(type) click to toggle source
# File lib/ruby_nos/endpoint.rb, line 16
def type= type
  if ALLOWED_TYPES.include?(type)
    @type = type
  else
    raise ArgumentError
  end
end