PHP 클래스 WsdlToPhp\PackageGenerator\Model\AbstractModel

상속: extends WsdlToPhp\PackageGenerator\Generator\AbstractGeneratorAware
파일 보기 프로젝트 열기: wsdltophp/packagegenerator 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( Generator $generator, string $name ) Main constructor
addMeta ( string $metaName, mixed $metaValue ) : AbstractModel Add meta information to the operation
cleanString ( string $string, boolean $keepMultipleUnderscores = true ) : string Clean a string to make it valid as PHP variable
getCleanName ( boolean $keepMultipleUnderscores = true ) : string Returns a valid clean name for PHP
getContextualPart ( ) : string Allows to define the contextual part of the class name for the package
getDocSubPackages ( ) : array Returns the sub package name which the model belongs to Must be overridden by sub classes
getExtends ( boolean $short = false ) : string | null Allows to define from which class the curent model extends
getExtendsClassName ( ) : string
getInheritance ( ) : string Returns the name of the class the current class inherits from
getInheritedMoel ( ) : Struct
getIsAbstract ( ) : boolean
getMeta ( ) : string[] Returns the meta
getMetaValue ( string $metaName, mixed $fallback = null ) : mixed Returns a meta value according to its name
getMetaValueFirstSet ( array $names, mixed $fallback = null ) : mixed Returns the value of the first meta value assigned to the name
getName ( ) : string Returns the original name extracted from the WSDL
getNamespace ( ) : string
getOwner ( ) : AbstractModel Returns the owner model object
getPackagedName ( $namespaced = false ) : string Returns the packaged name
getReservedMethodsInstance ( $filename = null ) : AbstractReservedWord
getSubDirectory ( ) : string Returns directory where to store class and create it if needed
nameIsClean ( ) : boolean Returns true if the original name is safe to use as a PHP property, variable name or class name
purgePhpReservedKeywords ( ) Gives the availability for test purpose and multiple package generation to purge reserved keywords usage
purgeReservedMethods ( ) Gives the availability for test purpose and multiple package generation to purge reserved methods usage
purgeUniqueNames ( ) Gives the availability for test purpose and multiple package generation to purge unique names
replacePhpReservedKeyword ( string $keyword, string $context = null ) : string Returns a usable keyword for a original keyword
replaceReservedMethod ( $methodName, string $context = null ) : string Returns a usable method for a original method
setDocumentation ( string $documentation ) : AbstractModel Sets the documentation meta value.
setInheritance ( $inheritance = '' ) Sets the name of the class the current class inherits from
setIsAbstract ( boolean $isAbstract ) : AbstractModel
setMeta ( array $meta = [] ) : AbstractModel Sets the meta
setName ( string $name ) : AbstractModel Sets the original name extracted from the WSDL
setOwner ( AbstractModel $owner ) : AbstractModel Sets the owner model object

보호된 메소드들

메소드 설명
uniqueName ( string $name, string $context ) : string Static method wich returns a unique name case sensitively Useful to name methods case sensitively distinct, see http://the-echoplex.net/log/php-case-sensitivity

메소드 상세

__construct() 공개 메소드

Main constructor
public __construct ( Generator $generator, string $name )
$generator WsdlToPhp\PackageGenerator\Generator\Generator
$name string the original name

addMeta() 공개 메소드

Add meta information to the operation
public addMeta ( string $metaName, mixed $metaValue ) : AbstractModel
$metaName string
$metaValue mixed
리턴 AbstractModel

cleanString() 공개 정적인 메소드

Clean a string to make it valid as PHP variable
public static cleanString ( string $string, boolean $keepMultipleUnderscores = true ) : string
$string string the string to clean
$keepMultipleUnderscores boolean optional, allows to keep the multiple consecutive underscores
리턴 string

getCleanName() 공개 메소드

Returns a valid clean name for PHP
public getCleanName ( boolean $keepMultipleUnderscores = true ) : string
$keepMultipleUnderscores boolean optional, allows to keep the multiple consecutive underscores
리턴 string

getContextualPart() 공개 메소드

Allows to define the contextual part of the class name for the package
public getContextualPart ( ) : string
리턴 string

getDocSubPackages() 공개 메소드

Returns the sub package name which the model belongs to Must be overridden by sub classes
public getDocSubPackages ( ) : array
리턴 array

getExtends() 공개 메소드

Allows to define from which class the curent model extends
public getExtends ( boolean $short = false ) : string | null
$short boolean
리턴 string | null

getExtendsClassName() 공개 메소드

public getExtendsClassName ( ) : string
리턴 string

getInheritance() 공개 메소드

Returns the name of the class the current class inherits from
public getInheritance ( ) : string
리턴 string

getInheritedMoel() 공개 메소드

public getInheritedMoel ( ) : Struct
리턴 Struct

getIsAbstract() 공개 메소드

public getIsAbstract ( ) : boolean
리턴 boolean

getMeta() 공개 메소드

Returns the meta
public getMeta ( ) : string[]
리턴 string[]

getMetaValue() 공개 메소드

Returns a meta value according to its name
public getMetaValue ( string $metaName, mixed $fallback = null ) : mixed
$metaName string the meta information name
$fallback mixed the fallback value if unset
리턴 mixed the meta information value

getMetaValueFirstSet() 공개 메소드

Returns the value of the first meta value assigned to the name
public getMetaValueFirstSet ( array $names, mixed $fallback = null ) : mixed
$names array the meta names to check
$fallback mixed the fallback value if anyone is set
리턴 mixed the meta information value

getName() 공개 메소드

Returns the original name extracted from the WSDL
public getName ( ) : string
리턴 string

getNamespace() 공개 메소드

public getNamespace ( ) : string
리턴 string

getOwner() 공개 메소드

Returns the owner model object
public getOwner ( ) : AbstractModel
리턴 AbstractModel

getPackagedName() 공개 메소드

Returns the packaged name
public getPackagedName ( $namespaced = false ) : string
리턴 string

getReservedMethodsInstance() 공개 메소드

public getReservedMethodsInstance ( $filename = null ) : AbstractReservedWord
$filename
리턴 WsdlToPhp\PackageGenerator\ConfigurationReader\AbstractReservedWord

getSubDirectory() 공개 메소드

Returns directory where to store class and create it if needed
public getSubDirectory ( ) : string
리턴 string

nameIsClean() 공개 메소드

Returns true if the original name is safe to use as a PHP property, variable name or class name
public nameIsClean ( ) : boolean
리턴 boolean

purgePhpReservedKeywords() 공개 정적인 메소드

Gives the availability for test purpose and multiple package generation to purge reserved keywords usage
public static purgePhpReservedKeywords ( )

purgeReservedMethods() 공개 정적인 메소드

Gives the availability for test purpose and multiple package generation to purge reserved methods usage
public static purgeReservedMethods ( )

purgeUniqueNames() 공개 정적인 메소드

Gives the availability for test purpose and multiple package generation to purge unique names
public static purgeUniqueNames ( )

replacePhpReservedKeyword() 공개 정적인 메소드

Returns a usable keyword for a original keyword
public static replacePhpReservedKeyword ( string $keyword, string $context = null ) : string
$keyword string the keyword
$context string the context
리턴 string

replaceReservedMethod() 공개 메소드

Returns a usable method for a original method
public replaceReservedMethod ( $methodName, string $context = null ) : string
$context string the context
리턴 string

setDocumentation() 공개 메소드

Documentation is set as an array so if multiple documentation nodes are set for an unique element, it will gather them.
public setDocumentation ( string $documentation ) : AbstractModel
$documentation string the documentation from the WSDL
리턴 AbstractModel

setInheritance() 공개 메소드

Sets the name of the class the current class inherits from
public setInheritance ( $inheritance = '' )

setIsAbstract() 공개 메소드

public setIsAbstract ( boolean $isAbstract ) : AbstractModel
$isAbstract boolean
리턴 AbstractModel

setMeta() 공개 메소드

Sets the meta
public setMeta ( array $meta = [] ) : AbstractModel
$meta array
리턴 AbstractModel

setName() 공개 메소드

Sets the original name extracted from the WSDL
public setName ( string $name ) : AbstractModel
$name string
리턴 AbstractModel

setOwner() 공개 메소드

Sets the owner model object
public setOwner ( AbstractModel $owner ) : AbstractModel
$owner AbstractModel object the owner of the current model
리턴 AbstractModel

uniqueName() 보호된 정적인 메소드

Static method wich returns a unique name case sensitively Useful to name methods case sensitively distinct, see http://the-echoplex.net/log/php-case-sensitivity
protected static uniqueName ( string $name, string $context ) : string
$name string the original name
$context string the context where the name is needed unique
리턴 string