Zeta Components - high quality PHP components

Zeta Components Manual :: Docs For Class ezcReflectionArrayType

Reflection::ezcReflectionArrayType

Class ezcReflectionArrayType

Provides type information of the array item type or map types

Source for this file: /Reflection/src/types/array_type.php

ezcReflectionAbstractType
   |
   --ezcReflectionPrimitiveType
      |
      --ezcReflectionArrayType
Version:   //autogen//
Todo:   add support for ArrayAccess stuff from http://www.php.net/~helly/php/ext/spl/

Member Variables

protected boolean $isList = false
protected ezcReflectionType $keyType
protected ezcReflectionType $valueType

Inherited Member Variables

From ezcReflectionAbstractType
protected ezcReflectionAbstractType::$typeName

Method Summary

public ezcReflectionArrayType __construct( $typeName )
public ezcReflectionType getKeyType( )
Returns key type of the array
public string getNamespace( )
public string getTypeName( )
Returns the canonical name for this array, which can be used in type annotations.
public ezcReflectionType getValueType( )
Returns value type of the array
public string getXmlName( [ $usePrefix = true] )
Returns XML Schema name of the complexType for the array
public DOMElement getXmlSchema( $dom , [ $namespaceXMLSchema = 'http://www.w3.org/2001/XMLSchema'] )
Returns an <xsd:complexType/>
public boolean isArray( )
public boolean isList( )
Returns true if this array has been documented as a list, i.e., using the notation of any type name followed by a pair of square brakets.
public boolean isMap( )
Returns wether this array is documented as 'array(mixed=>mixed)' or simply 'array'.
protected void _parseTypeName( )
Internal method for parsing array type names.

Inherited Methods

From ezcReflectionPrimitiveType
public boolean ezcReflectionPrimitiveType::isPrimitive()
public boolean ezcReflectionPrimitiveType::isScalarType()
Returns whether this type is one of integer, float, string, or boolean.
From ezcReflectionAbstractType
public ezcReflectionAbstractType ezcReflectionAbstractType::__construct()
public string ezcReflectionAbstractType::getTypeName()
public string ezcReflectionAbstractType::getXmlName()
Returns name of the correspondent XML Schema datatype
public DOMElement ezcReflectionAbstractType::getXmlSchema()
public boolean ezcReflectionAbstractType::isArray()
public boolean ezcReflectionAbstractType::isMap()
public boolean ezcReflectionAbstractType::isObject()
public boolean ezcReflectionAbstractType::isPrimitive()
public boolean ezcReflectionAbstractType::isScalarType()
Returns whether this type is one of integer, float, string, or boolean.
public String ezcReflectionAbstractType::__toString()
Returns a string representation.

Methods

__construct

ezcReflectionArrayType __construct( string $typeName )
Parameters:
Name Type Description
$typeName string
Redefinition of:
Method Description
ezcReflectionAbstractType::__construct()

getKeyType

ezcReflectionType getKeyType( )

Returns key type of the array

getNamespace

string getNamespace( )

getTypeName

string getTypeName( )

Returns the canonical name for this array, which can be used in type annotations.

Redefinition of:
Method Description
ezcReflectionAbstractType::getTypeName()

getValueType

ezcReflectionType getValueType( )

Returns value type of the array

getXmlName

string getXmlName( [boolean $usePrefix = true] )

Returns XML Schema name of the complexType for the array

The `this namespace' (tns) prefix is comonly used to refer to the current XML Schema document.

Parameters:
Name Type Description
$usePrefix boolean augments common prefix `tns:' to the name
Redefinition of:
Method Description
ezcReflectionAbstractType::getXmlName() Returns name of the correspondent XML Schema datatype

getXmlSchema

DOMElement getXmlSchema( $dom , [ $namespaceXMLSchema = 'http://www.w3.org/2001/XMLSchema'] )

Returns an <xsd:complexType/>

Parameters:
Name Type Description
$dom DOMDocument
$namespaceXMLSchema
Redefinition of:
Method Description
ezcReflectionAbstractType::getXmlSchema()

isArray

boolean isArray( )
Redefinition of:
Method Description
ezcReflectionAbstractType::isArray()

isList

boolean isList( )

Returns true if this array has been documented as a list, i.e., using the notation of any type name followed by a pair of square brakets.

Examples of list types include mixed[], stdClass[], sting[][], or array(mixed=>mixed)[].

isMap

boolean isMap( )

Returns wether this array is documented as 'array(mixed=>mixed)' or simply 'array'.

Redefinition of:
Method Description
ezcReflectionAbstractType::isMap()

_parseTypeName

void _parseTypeName( )

Internal method for parsing array type names.

Documentation generated by phpDocumentor 1.4.3