Module: Puppet::Pops::Types

Extended by:
RGen::MetamodelBuilder::ModuleExtension
Defined in:
lib/puppet/pops/types/types.rb,
lib/puppet/pops/types/types_meta.rb

Overview

The Types model is a model of Puppet Language types.

The exact relationship between types is not visible in this model wrt. the PDataType which is an abstraction of Scalar, Array, and Hash[Scalar, Data] nested to any depth. This means it is not possible to infer the type by simply looking at the inheritance hierarchy. The TypeCalculator should be used to answer questions about types. The TypeFactory should be used to create an instance of a type whenever one is needed.

The implementation of the Types model contains methods that are required for the type objects to behave as expected when comparing them and using them as keys in hashes. (No other logic is, or should be included directly in the model’s classes).

Defined Under Namespace

Modules: TypeFactory Classes: ClassLoader, Enumeration, PAnyType, PArrayType, PBooleanType, PCallableType, PCatalogEntryType, PCollectionType, PDataType, PDefaultType, PEnumType, PFloatType, PHashType, PHostClassType, PIntegerType, PNilType, PNumericType, POptionalType, PPatternType, PRegexpType, PResourceType, PRuntimeType, PScalarType, PStringType, PStructElement, PStructType, PTupleType, PType, PUnitType, PVariantType, TypeCalculator, TypeModelObject, TypeParser

Constant Summary collapse

INFINITY =

Used as end in a range

1.0 / 0.0
NEGATIVE_INFINITY =
-INFINITY
RuntimeEnum =
RGen::MetamodelBuilder::DataTypes::Enum.new(
:name => 'RuntimeEnum',
:literals => [:'ruby', ])

Method Summary

Methods included from RGen::MetamodelBuilder::ModuleExtension

_annotations, _constantOrder, annotation, extended, final_method, method_added

Methods included from RGen::ECore::ECoreInterface

#_set_ecore_internal, clear_ecore_cache, #ecore