class TEF::Animation::Coordinate
Public Class Methods
new(start_offset)
click to toggle source
# File lib/tef/Animation/Coordinate.rb, line 34 def initialize(start_offset) @animatable_attributes = {} $coordinate_def.each do |key, v| @animatable_attributes[key] = Value.new(v + start_offset) end end
Public Instance Methods
animatable_attributes()
click to toggle source
# File lib/tef/Animation/Coordinate.rb, line 42 def animatable_attributes @animatable_attributes.values end
configure(data)
click to toggle source
# File lib/tef/Animation/Coordinate.rb, line 46 def configure(data) raise ArgumentError, 'Coordinate config must be a hash!' unless data.is_a? Hash data.each do |key, value| coord = @animatable_attributes[key] raise ArgumentError, "Coordinate #{key} does not exist!" unless coord coord.configure value end end