Module: AmberVM::ActsAsAmberVMType::ActsAsAmberVMTypeMethods
- Defined in:
- lib/amber/acts_as_rvm_type.rb
Instance Method Summary collapse
-
#acts_as_amber_type ⇒ Object
This function sets up the class to be a registerd class for rVM.
Instance Method Details
#acts_as_amber_type ⇒ Object
This function sets up the class to be a registerd class for rVM. It also sets it up to allow the use of register_variable
and register_function
.
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
# File 'lib/amber/acts_as_rvm_type.rb', line 53 def acts_as_amber_type # registering as class extend AmberVM::Plugin plugin_host AmberVM::Classes register_for self.class.to_s.gsub(/(\w)([A-Z])/,"\1_" + "\2".downcase).to_sym #initializing empty functions and variables hashes @functions = {} @variables = {} #including DSL functions extend AmberVM::ActsAsAmberVMType::ActsAsAmberVMTypeInstanceMethods #including methods in class include AmberVM::ActsAsAmberVMType::ActsAsAmberVMTypeSingeltonMethods end |