class PgsqlQueryFactory extends QueryFactory (View source)

Workspaces PostgreSQL-specific entity query implementation.

Properties

protected Connection $connection

The database connection to use.

from  QueryFactory
protected array $namespaces

The namespace of this class, the parent class etc.

from  QueryFactory
protected WorkspaceManagerInterface $workspaceManager

The workspace manager.

Methods

__construct(Connection $connection, WorkspaceManagerInterface $workspace_manager)

Constructs a PgsqlQueryFactory object.

get(EntityTypeInterface $entity_type, string $conjunction)

Instantiates an entity query for a given entity type.

getAggregate(EntityTypeInterface $entity_type, string $conjunction)

Instantiates an aggregation query object for a given entity type.

Details

__construct(Connection $connection, WorkspaceManagerInterface $workspace_manager)

Constructs a PgsqlQueryFactory object.

Parameters

Connection $connection

The database connection used by the entity query.

WorkspaceManagerInterface $workspace_manager

The workspace manager.

QueryInterface get(EntityTypeInterface $entity_type, string $conjunction)

Instantiates an entity query for a given entity type.

Parameters

EntityTypeInterface $entity_type

The entity type definition.

string $conjunction

The operator to use to combine conditions: 'AND' or 'OR'.

Return Value

QueryInterface

An entity query for a specific configuration entity type.

QueryAggregateInterface getAggregate(EntityTypeInterface $entity_type, string $conjunction)

Instantiates an aggregation query object for a given entity type.

Parameters

EntityTypeInterface $entity_type

The entity type definition.

string $conjunction
  • AND: all of the conditions on the query need to match.
  • OR: at least one of the conditions on the query need to match.

Return Value

QueryAggregateInterface

The query object that can query the given entity type.

Exceptions

QueryException