PHP 클래스 PrefixLines, symfony-1.4

Example:
Or:

 
또한 보기: FilterReader
저자: hans lellelid, [email protected]
상속: extends BaseParamFilterReader, implements ChainableReader
파일 보기 프로젝트 열기: vjousse/symfony-1.4 1 사용 예제들

공개 메소드들

메소드 설명
chain ( Reader $reader ) : object Creates a new PrefixLines filter using the passed in Reader for instantiation.
getPrefix ( ) : string Returns the prefix which will be added at the start of each input line.
read ( $len = null ) : mixed Adds a prefix to each line of input stream and returns resulting stream.
setPrefix ( string $prefix ) Sets the prefix to add at the start of each input line.

비공개 메소드들

메소드 설명
_initialize ( ) Initializes the prefix if it is available from the parameters.

메소드 상세

chain() 공개 메소드

Creates a new PrefixLines filter using the passed in Reader for instantiation.
public chain ( Reader $reader ) : object
$reader Reader
리턴 object A new filter based on this configuration, but filtering the specified reader

getPrefix() 공개 메소드

Returns the prefix which will be added at the start of each input line.
public getPrefix ( ) : string
리턴 string The prefix which will be added at the start of each input line

read() 공개 메소드

Adds a prefix to each line of input stream and returns resulting stream.
public read ( $len = null ) : mixed
리턴 mixed buffer, -1 on EOF

setPrefix() 공개 메소드

Sets the prefix to add at the start of each input line.
public setPrefix ( string $prefix )
$prefix string The prefix to add at the start of each input line. May be null, in which case no prefix is added.