Class: OoxmlParser::Numbering

Inherits:
Object
  • Object
show all
Defined in:
lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(ilvl = 0, numbering_properties = nil) ⇒ Numbering

Returns a new instance of Numbering.



6
7
8
9
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 6

def initialize(ilvl = 0, numbering_properties = nil)
  @ilvl = ilvl
  @numbering_properties = numbering_properties
end

Instance Attribute Details

#fontObject

Returns the value of attribute font.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def font
  @font
end

#ilvlObject

Returns the value of attribute ilvl.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def ilvl
  @ilvl
end

#numbering_propertiesObject

Returns the value of attribute numbering_properties.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def numbering_properties
  @numbering_properties
end

#sizeObject

Returns the value of attribute size.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def size
  @size
end

#start_atObject

Returns the value of attribute start_at.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def start_at
  @start_at
end

#symbolObject

Returns the value of attribute symbol.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def symbol
  @symbol
end

#typeObject

Returns the value of attribute type.



4
5
6
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 4

def type
  @type
end

Instance Method Details

#numbering_level_currentObject



11
12
13
14
15
16
# File 'lib/ooxml_parser/common_parser/common_data/paragraph/paragrpah_properties/numbering.rb', line 11

def numbering_level_current
  @numbering_properties.ilvls.each do |current_ilvl|
    return current_ilvl if current_ilvl.ilvl == @ilvl
  end
  nil
end