Class: IChing::Hexagram

Inherits:
Object
  • Object
show all
Includes:
HasAttributes
Defined in:
lib/i_ching/hexagram.rb

Instance Attribute Summary

Attributes included from HasAttributes

#attributes

Class Method Summary collapse

Instance Method Summary collapse

Methods included from HasAttributes

#has_attributes, included, #initialize

Class Method Details

.get(king_wen_number) ⇒ Object



7
8
9
# File 'lib/i_ching/hexagram.rb', line 7

def get(king_wen_number)
  new(table[king_wen_number: king_wen_number])
end

Instance Method Details

#line(line_place) ⇒ Object



22
23
24
# File 'lib/i_ching/hexagram.rb', line 22

def line(line_place)
  Line.get(self.king_wen_number, line_place)
end

#linesObject



18
19
20
# File 'lib/i_ching/hexagram.rb', line 18

def lines
  Line.all(self.king_wen_number)
end