Class: VivlioStarter::CLI::PreProcessCommands::CrossReferenceProcessor::Label

Inherits:
Struct
  • Object
show all
Defined in:
lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb

Overview

ラベル定義情報を保持する構造体

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#autoObject

Returns the value of attribute auto

Returns:

  • (Object)

    the current value of auto



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def auto
  @auto
end

#chapterObject

Returns the value of attribute chapter

Returns:

  • (Object)

    the current value of chapter



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def chapter
  @chapter
end

#idObject

Returns the value of attribute id

Returns:

  • (Object)

    the current value of id



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def id
  @id
end

#lineObject

Returns the value of attribute line

Returns:

  • (Object)

    the current value of line



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def line
  @line
end

#numberObject

Returns the value of attribute number

Returns:

  • (Object)

    the current value of number



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def number
  @number
end

#source_fileObject

Returns the value of attribute source_file

Returns:

  • (Object)

    the current value of source_file



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def source_file
  @source_file
end

#titleObject

Returns the value of attribute title

Returns:

  • (Object)

    the current value of title



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def title
  @title
end

#typeObject

Returns the value of attribute type

Returns:

  • (Object)

    the current value of type



59
60
61
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 59

def type
  @type
end

Instance Method Details

#display_nameObject



60
61
62
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 60

def display_name
  LABEL_TYPE_NAMES.fetch(type, '要素')
end

#full_numberObject



64
65
66
# File 'lib/vivlio_starter/cli/pre_process/cross_reference_processor.rb', line 64

def full_number
  "#{display_name} #{number}"
end