Class: Puppet::Pops::Model::TextExpression

Inherits:
UnaryExpression show all
Defined in:
lib/puppet/pops/model/ast.rb

Instance Attribute Summary

Attributes inherited from UnaryExpression

#expr

Attributes inherited from Positioned

#length, #locator, #offset

Attributes inherited from PopsObject

#hash

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from UnaryExpression

#_pcore_init_hash, create, #eql?, from_asserted_hash, from_hash, #initialize

Methods inherited from Positioned

#_pcore_init_hash, create, #file, from_asserted_hash, from_hash, #initialize, #line, #pos

Methods inherited from PopsObject

#_pcore_init_hash, create, #eql?, from_asserted_hash, from_hash, #initialize, #to_s

Methods included from Types::PuppetObject

#_pcore_init_hash, #_pcore_type, #to_s

Constructor Details

This class inherits a constructor from Puppet::Pops::Model::UnaryExpression

Class Method Details

._pcore_typeObject



3537
3538
3539
3540
3541
# File 'lib/puppet/pops/model/ast.rb', line 3537

def self._pcore_type
  @_pcore_type ||= Types::PObjectType.new('Puppet::AST::TextExpression', {
                                            'parent' => UnaryExpression._pcore_type
                                          })
end

Instance Method Details

#_pcore_all_contents(path, &block) ⇒ Object



3547
3548
3549
3550
3551
3552
3553
3554
# File 'lib/puppet/pops/model/ast.rb', line 3547

def _pcore_all_contents(path, &block)
  path << self
  unless @expr.nil?
    block.call(@expr, path)
    @expr._pcore_all_contents(path, &block)
  end
  path.pop
end

#_pcore_contents {|@expr| ... } ⇒ Object

Yields:



3543
3544
3545
# File 'lib/puppet/pops/model/ast.rb', line 3543

def _pcore_contents
  yield(@expr) unless @expr.nil?
end