*/ public function select(Select $select): Collection; /** * Get a number of records in DB. */ public function count(Select $select): int; /** * Insert an entity into DB. */ public function insert(Entity $entity): void; /** * Insert a collection into DB. * * @param Collection $collection */ public function massInsert(Collection $collection): void; /** * Update an entity in DB. */ public function update(Entity $entity): void; /** * Mark an entity as deleted in DB. */ public function delete(Entity $entity): void; /** * Insert an entity into DB, on duplicate key update specified attributes. * * @param string[] $onDuplicateUpdateAttributeList */ public function insertOnDuplicateUpdate(Entity $entity, array $onDuplicateUpdateAttributeList): void; }