Class: Puppet::Pops::Types::PResourceType
Overview
Represents a Resource Type in the Puppet Language
Constant Summary
collapse
- DEFAULT =
PResourceType.new(nil)
Instance Attribute Summary collapse
Instance Method Summary
collapse
#instance?
Methods inherited from PAnyType
#==, #accept, #assignable?, #callable?, #callable_args?, #generalize, #instance?, #iterable?, #iterable_type, #kind_of_callable?, #normalize, #simple_name, #to_alias_expanded_s, #to_s
Methods included from Visitable
#accept
Constructor Details
#initialize(type_name, title = nil) ⇒ PResourceType
Returns a new instance of PResourceType.
2121
2122
2123
2124
|
# File 'lib/puppet/pops/types/types.rb', line 2121
def initialize(type_name, title = nil)
@type_name = type_name
@title = title
end
|
Instance Attribute Details
2119
2120
2121
|
# File 'lib/puppet/pops/types/types.rb', line 2119
def title
@title
end
|
#type_name ⇒ Object
2119
2120
2121
|
# File 'lib/puppet/pops/types/types.rb', line 2119
def type_name
@type_name
end
|
Instance Method Details
#eql?(o) ⇒ Boolean
2130
2131
2132
|
# File 'lib/puppet/pops/types/types.rb', line 2130
def eql?(o)
self.class == o.class && @type_name == o.type_name && @title == o.title
end
|
2126
2127
2128
|
# File 'lib/puppet/pops/types/types.rb', line 2126
def hash
@type_name.hash ^ @title.hash
end
|