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

#endpointObject

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

#idObject

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

#clientObject



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

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

#publisher_endpointObject



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

def publisher_endpoint
  @publisher_endpoint ||= discover_publisher_endpoint
end

#to_sObject



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

def to_s
  id
end