class MysqlMapper extends Singleton implements IMapper

Abstract Mysql Mapper

Properties

static protected multiple: $_instances Array of \jtl\Connector\Core\Utilities\Singleton Objects from Singleton
protected Mysql $_db Mysql Database
protected string $_table Mysql Table
protected mixed:string|multiple $_primary Mysql Primary Key

Methods

static Singleton:
getInstance()

Basic Singleton implementation

from Singleton
__construct()

Constructor

__clone()

Clone Method

from Singleton
load()

Loader for $table and $primary

Db()

No description

string
getTable()

Get Table Name

setNames(string $encoding = 'utf8')

Character Set Support

setCharset(string $encoding = 'utf8')

Name Set Support

boolean
isPrimarySet(stdClass $object)

Checks if a Primary Key is set

mutiple|string|null
getPrimaryValues(DataModel $model)

Gets Primary Values

mutiple|string|null
getPrimaryFields(DataModel $model = null, boolean $toWawi = false)

Gets Primary Fields

multitype:
getKeyValues(DataModel $model, boolean $toWawi = false)

No description

string
whereSql(array $kvs = null)

Generation Sql Primary Key Where Statement

string
limitSql(QueryFilter $filter = null)

Generation Sql Limit Statement

string
orderSql(QueryFilter $filter = null)

Generation Sql Order Statement

Details

in Singleton at line 29
static Singleton: getInstance()

Basic Singleton implementation

Return Value

Singleton:

at line 47
protected __construct()

Constructor

in Singleton at line 49
final protected __clone()

Clone Method

at line 60
abstract protected load()

Loader for $table and $primary

at line 65
Mysql Db()

Return Value

Mysql

at line 75
string getTable()

Get Table Name

Return Value

string

at line 85
setNames(string $encoding = 'utf8')

Character Set Support

Parameters

string $encoding

at line 95
setCharset(string $encoding = 'utf8')

Name Set Support

Parameters

string $encoding

at line 106
boolean isPrimarySet(stdClass $object)

Checks if a Primary Key is set

Parameters

stdClass $object

Return Value

boolean

at line 133
mutiple|string|null getPrimaryValues(DataModel $model)

Gets Primary Values

Parameters

DataModel $model

Return Value

mutiple|string|null

at line 157
mutiple|string|null getPrimaryFields(DataModel $model = null, boolean $toWawi = false)

Gets Primary Fields

Parameters

DataModel $model
boolean $toWawi

Return Value

mutiple|string|null

at line 192
multitype: getKeyValues(DataModel $model, boolean $toWawi = false)

Parameters

DataModel $model
boolean $toWawi

Return Value

multitype: mixed

at line 216
string whereSql(array $kvs = null)

Generation Sql Primary Key Where Statement

Parameters

array $kvs

Return Value

string

at line 238
string limitSql(QueryFilter $filter = null)

Generation Sql Limit Statement

Parameters

QueryFilter $filter

Return Value

string

at line 254
string orderSql(QueryFilter $filter = null)

Generation Sql Order Statement

Parameters

QueryFilter $filter

Return Value

string