PHP Class Phalcon\Translate\Adapter\Database

Inheritance: extends Phalcon\Translate\Adapter\Base, implements Phalcon\Translate\AdapterInterface, implements ArrayAccess
显示文件 Open project: phalcon/incubator

Protected Properties

Property Type Description
$options array
$stmtExists array Statement for Exist
$stmtSelect array Statement for Read
$useIcuMessageFormatter boolean Use ICU MessageFormatter to parse message

Public Methods

Method Description
_ ( $translateKey, $placeholders = null ) @codingStandardsIgnoreStart
__construct ( array $options ) Class constructor.
add ( string $translateKey, string $message ) : boolean Adds a translation for given key (No existence check!)
delete ( string $translateKey ) : boolean Deletes a translation for given key (No existence check!)
exists ( string $translateKey ) : boolean
offsetExists ( string $translateKey ) : string
offsetGet ( string $translateKey ) : string
offsetSet ( string $translateKey, string $message ) : string
offsetUnset ( string $translateKey ) : string
query ( string $translateKey, array $placeholders = null ) : string
set ( string $translateKey, string $message ) : boolean Sets (insert or updates) a translation for given key
update ( string $translateKey, string $message ) : boolean Update a translation for given key (No existence check!)

Method Details

_() public method

@codingStandardsIgnoreStart
public _ ( $translateKey, $placeholders = null )

__construct() public method

Class constructor.
public __construct ( array $options )
$options array

add() public method

Adds a translation for given key (No existence check!)
public add ( string $translateKey, string $message ) : boolean
$translateKey string
$message string
return boolean

delete() public method

Deletes a translation for given key (No existence check!)
public delete ( string $translateKey ) : boolean
$translateKey string
return boolean

exists() public method

public exists ( string $translateKey ) : boolean
$translateKey string
return boolean

offsetExists() public method

public offsetExists ( string $translateKey ) : string
$translateKey string
return string

offsetGet() public method

public offsetGet ( string $translateKey ) : string
$translateKey string
return string

offsetSet() public method

public offsetSet ( string $translateKey, string $message ) : string
$translateKey string
$message string
return string

offsetUnset() public method

public offsetUnset ( string $translateKey ) : string
$translateKey string
return string

query() public method

public query ( string $translateKey, array $placeholders = null ) : string
$translateKey string
$placeholders array
return string

set() public method

Sets (insert or updates) a translation for given key
public set ( string $translateKey, string $message ) : boolean
$translateKey string
$message string
return boolean

update() public method

Update a translation for given key (No existence check!)
public update ( string $translateKey, string $message ) : boolean
$translateKey string
$message string
return boolean

Property Details

$options protected_oe property

protected array $options
return array

$stmtExists protected_oe property

Statement for Exist
protected array $stmtExists
return array

$stmtSelect protected_oe property

Statement for Read
protected array $stmtSelect
return array

$useIcuMessageFormatter protected_oe property

Use ICU MessageFormatter to parse message
protected bool $useIcuMessageFormatter
return boolean