PHP 클래스 Protobuf\Binary\StreamWriter

저자: Iván Montes ([email protected])
저자: Fabio B. Silva ([email protected])
파일 보기 프로젝트 열기: protobuf-php/protobuf 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$config Protobuf\Configuration
$isBigEndian boolean
$negativeEncoder Protobuf\Binary\Platform\NegativeEncoder

공개 메소드들

메소드 설명
__construct ( Configuration $config ) Constructor
writeBool ( Stream $stream, boolean $value ) Encode a bool.
writeByte ( Stream $stream, integer $value ) Store a single byte.
writeByteStream ( Stream $stream, Stream $value ) Encode a stream of bytes.
writeBytes ( Stream $stream, string $bytes, integer $length = null ) Store the given bytes in the stream.
writeDouble ( Stream $stream, float $value ) Encode a number as a 64bit double.
writeFixed32 ( Stream $stream, integer $value ) Encode an integer as a fixed of 32bits without sign.
writeFixed64 ( Stream $stream, integer $value ) Encode an integer as a fixed of 64bits without sign.
writeFloat ( Stream $stream, float $value ) Encode a number as a 32bit float.
writeSFixed32 ( Stream $stream, integer $value ) Encode an integer as a fixed of 32bits with sign.
writeSFixed64 ( Stream $stream, integer $value ) Encode an integer as a fixed of 64bits with sign.
writeStream ( Stream $stream, Stream $value, integer $length = null ) Write the given stream.
writeString ( Stream $stream, string $value ) Encode a string.
writeVarint ( Stream $stream, integer $value ) Store an integer encoded as varint.
writeZigzag ( Stream $stream, integer $value, integer $base = 32 ) Encodes an integer with zigzag.
writeZigzag32 ( Stream $stream, integer $value ) Encodes an integer with zigzag.
writeZigzag64 ( Stream $stream, integer $value ) Encodes an integer with zigzag.

메소드 상세

__construct() 공개 메소드

Constructor
public __construct ( Configuration $config )
$config Protobuf\Configuration

writeBool() 공개 메소드

Encode a bool.
public writeBool ( Stream $stream, boolean $value )
$stream Protobuf\Stream
$value boolean

writeByte() 공개 메소드

Store a single byte.
public writeByte ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeByteStream() 공개 메소드

Encode a stream of bytes.
public writeByteStream ( Stream $stream, Stream $value )
$stream Protobuf\Stream
$value Protobuf\Stream

writeBytes() 공개 메소드

Store the given bytes in the stream.
public writeBytes ( Stream $stream, string $bytes, integer $length = null )
$stream Protobuf\Stream
$bytes string
$length integer

writeDouble() 공개 메소드

Encode a number as a 64bit double.
public writeDouble ( Stream $stream, float $value )
$stream Protobuf\Stream
$value float

writeFixed32() 공개 메소드

Encode an integer as a fixed of 32bits without sign.
public writeFixed32 ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeFixed64() 공개 메소드

Encode an integer as a fixed of 64bits without sign.
public writeFixed64 ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeFloat() 공개 메소드

Encode a number as a 32bit float.
public writeFloat ( Stream $stream, float $value )
$stream Protobuf\Stream
$value float

writeSFixed32() 공개 메소드

Encode an integer as a fixed of 32bits with sign.
public writeSFixed32 ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeSFixed64() 공개 메소드

Encode an integer as a fixed of 64bits with sign.
public writeSFixed64 ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeStream() 공개 메소드

Write the given stream.
public writeStream ( Stream $stream, Stream $value, integer $length = null )
$stream Protobuf\Stream
$value Protobuf\Stream
$length integer

writeString() 공개 메소드

Encode a string.
public writeString ( Stream $stream, string $value )
$stream Protobuf\Stream
$value string

writeVarint() 공개 메소드

Store an integer encoded as varint.
public writeVarint ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeZigzag() 공개 메소드

Encodes an integer with zigzag.
public writeZigzag ( Stream $stream, integer $value, integer $base = 32 )
$stream Protobuf\Stream
$value integer
$base integer

writeZigzag32() 공개 메소드

Encodes an integer with zigzag.
public writeZigzag32 ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

writeZigzag64() 공개 메소드

Encodes an integer with zigzag.
public writeZigzag64 ( Stream $stream, integer $value )
$stream Protobuf\Stream
$value integer

프로퍼티 상세

$config 보호되어 있는 프로퍼티

protected Configuration,Protobuf $config
리턴 Protobuf\Configuration

$isBigEndian 보호되어 있는 프로퍼티

protected bool $isBigEndian
리턴 boolean

$negativeEncoder 보호되어 있는 프로퍼티

protected NegativeEncoder,Protobuf\Binary\Platform $negativeEncoder
리턴 Protobuf\Binary\Platform\NegativeEncoder