Class: AdLint::Cc1::Member

Inherits:
Object
  • Object
show all
Defined in:
lib/adlint/cc1/type.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, type) ⇒ Member

Returns a new instance of Member.



6696
6697
6698
6699
# File 'lib/adlint/cc1/type.rb', line 6696

def initialize(name, type)
  @name = name
  @type = type
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



6701
6702
6703
# File 'lib/adlint/cc1/type.rb', line 6701

def name
  @name
end

#typeObject (readonly)

Returns the value of attribute type.



6702
6703
6704
# File 'lib/adlint/cc1/type.rb', line 6702

def type
  @type
end

Instance Method Details

#dupObject



6708
6709
6710
# File 'lib/adlint/cc1/type.rb', line 6708

def dup
  Member.new(@name, @type.dup)
end

#named?Boolean

Returns:

  • (Boolean)


6704
6705
6706
# File 'lib/adlint/cc1/type.rb', line 6704

def named?
  !@name.nil?
end