Class: Partials::FunctionDeclaration

Inherits:
Struct
  • Object
show all
Defined in:
lib/ceedling/partials/partials.rb

Overview

Data class representing a C function signature

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name: nil, signature: nil, source_filepath: nil, line_num: nil) ⇒ FunctionDeclaration

Constructor to set unassigned fields to nil for convenience



44
45
46
# File 'lib/ceedling/partials/partials.rb', line 44

def initialize(name: nil, signature: nil, source_filepath: nil, line_num: nil)
  super
end

Instance Attribute Details

#line_numObject

Returns the value of attribute line_num

Returns:

  • (Object)

    the current value of line_num



35
36
37
# File 'lib/ceedling/partials/partials.rb', line 35

def line_num
  @line_num
end

#nameObject

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



35
36
37
# File 'lib/ceedling/partials/partials.rb', line 35

def name
  @name
end

#return_typeObject

Returns the value of attribute return_type

Returns:

  • (Object)

    the current value of return_type



35
36
37
# File 'lib/ceedling/partials/partials.rb', line 35

def return_type
  @return_type
end

#signatureObject

Returns the value of attribute signature

Returns:

  • (Object)

    the current value of signature



35
36
37
# File 'lib/ceedling/partials/partials.rb', line 35

def signature
  @signature
end

#source_filepathObject

Returns the value of attribute source_filepath

Returns:

  • (Object)

    the current value of source_filepath



35
36
37
# File 'lib/ceedling/partials/partials.rb', line 35

def source_filepath
  @source_filepath
end