ECI
extends QRDataModeAbstract
in package
FinalYes
Adds an ECI Designator
ISO/IEC 18004:2000 8.4.1.1
Please note that you have to take care for the correct data encoding when adding with QRCode::add*Segment()
Table of Contents
Constants
- DATAMODE = \chillerlan\QRCode\Common\Mode::ECI
Properties
Methods
- __construct() : mixed
- QRDataModeAbstract constructor.
- convertEncoding() : string
- encoding conversion helper
- decodeSegment() : string
- Reads and decodes the ECI designator including the following byte sequence
- getLengthInBits() : int
- retruns the length in bits of the data string
- parseValue() : ECICharset
- Reads and parses the value of an ECI designator
- validateString() : bool
- checks if the given string qualifies for the encoder module
- write() : static
- Writes an ECI designator to the bitbuffer
- getCharCount() : int
- returns the character count of the $data string
- getLengthBits() : int
- shortcut
Constants
DATAMODE
public
mixed
DATAMODE
= \chillerlan\QRCode\Common\Mode::ECI
Properties
$data
The data to write
protected
string
$data
$encoding
The current ECI encoding id
private
int
$encoding
Methods
__construct()
QRDataModeAbstract constructor.
public
__construct(int $encoding) : mixed
Parameters
- $encoding : int
Tags
convertEncoding()
encoding conversion helper
public
static convertEncoding(string $string) : string
Parameters
- $string : string
Return values
stringdecodeSegment()
Reads and decodes the ECI designator including the following byte sequence
public
static decodeSegment(BitBuffer $bitBuffer, int $versionNumber) : string
Parameters
- $bitBuffer : BitBuffer
- $versionNumber : int
Tags
Return values
stringgetLengthInBits()
retruns the length in bits of the data string
public
getLengthInBits() : int
Return values
intparseValue()
Reads and parses the value of an ECI designator
public
static parseValue(BitBuffer $bitBuffer) : ECICharset
Parameters
- $bitBuffer : BitBuffer
Tags
Return values
ECICharsetvalidateString()
checks if the given string qualifies for the encoder module
public
static validateString(string $string) : bool
Parameters
- $string : string
Tags
Return values
boolwrite()
Writes an ECI designator to the bitbuffer
public
write(BitBuffer $bitBuffer, int $versionNumber) : static
Parameters
- $bitBuffer : BitBuffer
- $versionNumber : int
Tags
Return values
staticgetCharCount()
returns the character count of the $data string
protected
getCharCount() : int
Return values
intgetLengthBits()
shortcut
protected
static getLengthBits(int $versionNumber) : int
Parameters
- $versionNumber : int