KLayout Manual: Main Index » Class Index » API reference - Class ArgType

API reference - Class ArgType

Notation used in Ruby API documentation

Description: The description of a type (argument or return value)

Public constructors

ArgTypenewCreates a new object of this class

Public methods

[const]bool!=(const ArgType arg1)Inequality of two types
[const]bool==(const ArgType arg1)Equality of two types
[const]voidassign(const ArgType other)Assign the contents of another object to self
[const]const Class ptrclsSpecifies the class for t_object.. types
voidcreateEnsures the C++ object is created
voiddestroyExplicitly destroy the object
[const]booldestroyed?Returns a value indicating whether the object was already destroyed
[const]ArgTypedupCreates a copy of self
[const]const ArgType ptrinnerReturns the inner ArgType object (i.e. value of a vector)
[const]boolis_const_object?Returns a value indicating whether the reference is a const reference
[const]boolis_cptr?True, if the type is a const pointer to the given type
[const]boolis_cref?True, if the type is a const reference to the given type
[const]boolis_iter?(Return value only) True, if the return value is an iterator rendering the given type
[const]boolis_ptr?True, if the type is a non-const pointer to the given type
[const]boolis_ref?True, if the type is a reference to the given type
[const]stringto_sConvert to a string
[const]inttypeReturn the basic type (see t_.. constants)

Public static methods and constants

intTypeBool
intTypeChar
intTypeDouble
intTypeFloat
intTypeInt
intTypeLong
intTypeLongLong
intTypeObject
intTypeObjectNew
intTypeQString
intTypeSChar
intTypeShort
intTypeString
intTypeStringCCptr
intTypeUChar
intTypeUInt
intTypeULong
intTypeULongLong
intTypeUShort
intTypeVar
intTypeVector
intTypeVoid

Deprecated methods (protected, public, static, non-static and constructors)

[static]intt_boolUse of this method is deprecated. Use TypeBool instead
[static]intt_charUse of this method is deprecated. Use TypeChar instead
[static]intt_doubleUse of this method is deprecated. Use TypeDouble instead
[static]intt_floatUse of this method is deprecated. Use TypeFloat instead
[static]intt_intUse of this method is deprecated. Use TypeInt instead
[static]intt_longUse of this method is deprecated. Use TypeLong instead
[static]intt_longlongUse of this method is deprecated. Use TypeLongLong instead
[static]intt_objectUse of this method is deprecated. Use TypeObject instead
[static]intt_object_newUse of this method is deprecated. Use TypeObjectNew instead
[static]intt_qstringUse of this method is deprecated. Use TypeQString instead
[static]intt_scharUse of this method is deprecated. Use TypeSChar instead
[static]intt_shortUse of this method is deprecated. Use TypeShort instead
[static]intt_stringUse of this method is deprecated. Use TypeString instead
[static]intt_string_ccptrUse of this method is deprecated. Use TypeStringCCptr instead
[static]intt_ucharUse of this method is deprecated. Use TypeUChar instead
[static]intt_uintUse of this method is deprecated. Use TypeUInt instead
[static]intt_ulongUse of this method is deprecated. Use TypeULong instead
[static]intt_ulonglongUse of this method is deprecated. Use TypeULongLong instead
[static]intt_ushortUse of this method is deprecated. Use TypeUShort instead
[static]intt_varUse of this method is deprecated. Use TypeVar instead
[static]intt_vectorUse of this method is deprecated. Use TypeVector instead
[static]intt_voidUse of this method is deprecated. Use TypeVoid instead

Detailed description

[const] bool !=(const ArgType arg1)

Description: Inequality of two types

[const] bool ==(const ArgType arg1)

Description: Equality of two types

[static] int TypeBool

Description:

[static] int TypeChar

Description:

[static] int TypeDouble

Description:

[static] int TypeFloat

Description:

[static] int TypeInt

Description:

[static] int TypeLong

Description:

[static] int TypeLongLong

Description:

[static] int TypeObject

Description:

[static] int TypeObjectNew

Description:

[static] int TypeQString

Description:

[static] int TypeSChar

Description:

[static] int TypeShort

Description:

[static] int TypeString

Description:

[static] int TypeStringCCptr

Description:

[static] int TypeUChar

Description:

[static] int TypeUInt

Description:

[static] int TypeULong

Description:

[static] int TypeULongLong

Description:

[static] int TypeUShort

Description:

[static] int TypeVar

Description:

[static] int TypeVector

Description:

[static] int TypeVoid

Description:

[const] void assign(const ArgType other)

Description: Assign the contents of another object to self

This method assigns the contents of another object to self. This is a deep copy that does not only copy the reference but the actual content.

[const] const Class ptr cls

Description: Specifies the class for t_object.. types

void create

Description: Ensures the C++ object is created

Use this method to ensure the C++ object is created, for example to ensure that resources are allocated. Usually C++ objects are created on demand and not necessarily when the script object is created.

void destroy

Description: Explicitly destroy the object

Explicitly destroy the object on C++ side if it was owned by the Ruby interpreter. Subsequent access to this object will throw an exception. If the object is not owned by Ruby, this method will do nothing.

[const] bool destroyed?

Description: Returns a value indicating whether the object was already destroyed

This method returns true, if the object was destroyed, either explicitly or by the C++ side. The latter may happen, if the object is owned by a C++ object which got destroyed itself.

[const] ArgType dup

Description: Creates a copy of self

[const] const ArgType ptr inner

Description: Returns the inner ArgType object (i.e. value of a vector)

Starting with version 0.22, this method replaces the is_vector method.

[const] bool is_const_object?

Description: Returns a value indicating whether the reference is a const reference

This method returns true, if self is a const reference. In that case, only const methods may be called on self.

[const] bool is_cptr?

Description: True, if the type is a const pointer to the given type

This property indicates that the argument is a const pointer (in C++: 'const X *').

[const] bool is_cref?

Description: True, if the type is a const reference to the given type

This property indicates that the argument is a const reference (in C++: 'const X &').

[const] bool is_iter?

Description: (Return value only) True, if the return value is an iterator rendering the given type

[const] bool is_ptr?

Description: True, if the type is a non-const pointer to the given type

This property indicates that the argument is a non-const pointer (in C++: 'X *').

[const] bool is_ref?

Description: True, if the type is a reference to the given type

Starting with version 0.22 there are more methods that describe the type of reference and is_ref? only applies to non-const reference (in C++: 'X &').

[static] ArgType new

Description: Creates a new object of this class

[static] int t_bool

Description:

This method is deprecated. Use method 'TypeBool' instead

[static] int t_char

Description:

This method is deprecated. Use method 'TypeChar' instead

[static] int t_double

Description:

This method is deprecated. Use method 'TypeDouble' instead

[static] int t_float

Description:

This method is deprecated. Use method 'TypeFloat' instead

[static] int t_int

Description:

This method is deprecated. Use method 'TypeInt' instead

[static] int t_long

Description:

This method is deprecated. Use method 'TypeLong' instead

[static] int t_longlong

Description:

This method is deprecated. Use method 'TypeLongLong' instead

[static] int t_object

Description:

This method is deprecated. Use method 'TypeObject' instead

[static] int t_object_new

Description:

This method is deprecated. Use method 'TypeObjectNew' instead

[static] int t_qstring

Description:

This method is deprecated. Use method 'TypeQString' instead

[static] int t_schar

Description:

This method is deprecated. Use method 'TypeSChar' instead

[static] int t_short

Description:

This method is deprecated. Use method 'TypeShort' instead

[static] int t_string

Description:

This method is deprecated. Use method 'TypeString' instead

[static] int t_string_ccptr

Description:

This method is deprecated. Use method 'TypeStringCCptr' instead

[static] int t_uchar

Description:

This method is deprecated. Use method 'TypeUChar' instead

[static] int t_uint

Description:

This method is deprecated. Use method 'TypeUInt' instead

[static] int t_ulong

Description:

This method is deprecated. Use method 'TypeULong' instead

[static] int t_ulonglong

Description:

This method is deprecated. Use method 'TypeULongLong' instead

[static] int t_ushort

Description:

This method is deprecated. Use method 'TypeUShort' instead

[static] int t_var

Description:

This method is deprecated. Use method 'TypeVar' instead

[static] int t_vector

Description:

This method is deprecated. Use method 'TypeVector' instead

[static] int t_void

Description:

This method is deprecated. Use method 'TypeVoid' instead

[const] string to_s

Description: Convert to a string

[const] int type

Description: Return the basic type (see t_.. constants)