PHP 클래스 ComponentStubGenerator

Yii components' properties can come from many sources and be accessed either directly or via get method calls. This class, given a set of property values, will generate a stub that will return those values under any circumstances.
파일 보기 프로젝트 열기: openeyes/openeyes 1 사용 예제들

공개 메소드들

메소드 설명
generate ( string $class_name, array $properties = [] )
propertiesSetAndMatch ( $stub, array $properties = [], boolean $force = false ) iteratest through properties to set values on the stub that exists on the stub class. If $force is true, will set the value regardless of whether or not the property exists on the element.

메소드 상세

generate() 공개 정적인 메소드

public static generate ( string $class_name, array $properties = [] )
$class_name string
$properties array

propertiesSetAndMatch() 공개 정적인 메소드

iteratest through properties to set values on the stub that exists on the stub class. If $force is true, will set the value regardless of whether or not the property exists on the element.
public static propertiesSetAndMatch ( $stub, array $properties = [], boolean $force = false )
$stub
$properties array
$force boolean