Class: Aggro::Node

Inherits:
Struct
  • Object
show all
Defined in:
lib/aggro/node.rb

Overview

Public: Represents an aggro server node.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#endpoint ⇒ Object

Returns the value of attribute endpoint

Returns:

  • (Object) —

    the current value of endpoint



3
4
5
# File 'lib/aggro/node.rb', line 3

def endpoint
  @endpoint
end

#id ⇒ Object

Returns the value of attribute id

Returns:

  • (Object) —

    the current value of id



3
4
5
# File 'lib/aggro/node.rb', line 3

def id
  @id
end

Instance Method Details

#client ⇒ Object



4
5
6
# File 'lib/aggro/node.rb', line 4

def client
  @client ||= Aggro::Client.new(endpoint)
end

#publisher_endpoint ⇒ Object



8
9
10
# File 'lib/aggro/node.rb', line 8

def publisher_endpoint
  @publisher_endpoint ||= discover_publisher_endpoint
end

#to_s ⇒ Object



12
13
14
# File 'lib/aggro/node.rb', line 12

def to_s
  id
end