Class: Imasgen::MIXNUTSCls
- Inherits:
-
GeneratorBase
- Object
- GeneratorBase
- Imasgen::MIXNUTSCls
- Defined in:
- lib/imasgen/mixnuts.rb
Instance Attribute Summary
Attributes inherited from GeneratorBase
Instance Method Summary collapse
-
#initialize(*nuts) ⇒ MIXNUTSCls
constructor
A new instance of MIXNUTSCls.
- #unique ⇒ Object
Methods inherited from GeneratorBase
getyaml, #hotchpotch, #name, #reset
Constructor Details
#initialize(*nuts) ⇒ MIXNUTSCls
Returns a new instance of MIXNUTSCls.
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 |
# File 'lib/imasgen/mixnuts.rb', line 13 def initialize(*nuts) super() nuts.each do |item| case item when Imasgen::SIDEM @namedic += Imasgen::SideMCls.getyaml when Imasgen::MILLIONLIVE @namedic += Imasgen::MillionLiveCls.getyaml when Imasgen::CINDERELLA @namedic += Imasgen::CinderellaGirlsCls.getyaml else raise ArgumentError.new("Invalid Argument #{item}") end end if nuts.none? @namedic += Imasgen::SideMCls.getyaml @namedic += Imasgen::MillionLiveCls.getyaml @namedic += Imasgen::CinderellaGirlsCls.getyaml end @args = nuts end |
Instance Method Details
#unique ⇒ Object
35 36 37 |
# File 'lib/imasgen/mixnuts.rb', line 35 def unique @unique_i ||= self.class.new(*@args) end |