Class: RubyPost::Translate

Inherits:
Option show all
Defined in:
lib/options.rb

Overview

Wraps the metapose shifted command.
The translation @t is specifed by a Pair

Direct Known Subclasses

Shift, Shifted

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(p = Pair.new) ⇒ Translate

Returns a new instance of Translate.



159
160
161
# File 'lib/options.rb', line 159

def initialize(p=Pair.new)
  @t = p
end

Instance Attribute Details

#t=(value) ⇒ Object (writeonly)

Sets the attribute t

Parameters:

  • value

    the value to set the attribute t to.



157
158
159
# File 'lib/options.rb', line 157

def t=(value)
  @t = value
end

Instance Method Details

#compileObject



163
164
165
# File 'lib/options.rb', line 163

def compile
  'shifted ' + @t.compile
end