ndm helped me a lot with this (see comments to my question), but since he didn't post an answer I am doing this now.
It's possible to use an own ValueBinder
by setting it on my query: $this->Table->find()->valueBinder(myOwnValueBinder)
.
To make that the default ValueBinder in my own code (sufficient in most cases) one can use e.g. an AppTable
as known from CakePHP 2 that extends to Table
and make all other *Table
classes extend AppTable
. Now one only needs to create the following method:
public function query() {
return parent::query()->valueBinder(myOwnValueBinder);
}
In case it's needed that all code uses teh custom ValueBinder
, an extended datasource Connection class has to be created (and used). In this class Connection::newQuery()
has to be overriden.