Class: SPNet::PortLocater

Inherits:
Object
  • Object
show all
Includes:
Hashmake::HashMakeable
Defined in:
lib/spnet/storage/port_locater.rb

Overview

Locate a port based on the block and port name, rather than an object reference.

Author:

  • James Tunnell

Constant Summary collapse

ARG_SPECS =

Define arg specs to use in processing hashed arguments during #initialize.

{
  :block_name => arg_spec(:reqd => true, :type => String),
  :port_name => arg_spec(:reqd => true, :type => String),
}

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(args) ⇒ PortLocater

Returns a new instance of PortLocater.



17
18
19
# File 'lib/spnet/storage/port_locater.rb', line 17

def initialize args
  hash_make args, ARG_SPECS
end

Instance Attribute Details

#block_nameObject (readonly)

Returns the value of attribute block_name.



15
16
17
# File 'lib/spnet/storage/port_locater.rb', line 15

def block_name
  @block_name
end

#port_nameObject (readonly)

Returns the value of attribute port_name.



15
16
17
# File 'lib/spnet/storage/port_locater.rb', line 15

def port_name
  @port_name
end