public abstract class AbstractIdMapper extends Object implements IdMapper
Constructor and Description |
---|
AbstractIdMapper(ServiceRegistry serviceRegistry) |
Modifier and Type | Method and Description |
---|---|
void |
addIdEqualsToQuery(Parameters parameters,
Object id,
String alias,
String prefix,
boolean equals)
Adds query statements, which contains restrictions, which express the property that the id of the entity
with alias prefix, is equal to the given object.
|
void |
addIdsEqualToQuery(Parameters parameters,
String prefix1,
IdMapper mapper2,
String prefix2)
Adds query statements, which contains restrictions, which express the property that the id of the entity
with alias prefix1, is equal to the id of the entity with alias prefix2 mapped by the second mapper
(the second mapper must be for the same entity, but it can have, for example, prefixed properties).
|
void |
addIdsEqualToQuery(Parameters parameters,
String prefix1,
String prefix2)
Adds query statements, which contains restrictions, which express the property that the id of the entity
with alias prefix1, is equal to the id of the entity with alias prefix2 (the entity is the same).
|
void |
addNamedIdEqualsToQuery(Parameters parameters,
String prefix,
boolean equals)
Adds query statements, which contains named parameters, which express the property that the id of the entity
with alias prefix, is equal to the given object.
|
void |
addNamedIdEqualsToQuery(Parameters parameters,
String prefix1,
IdMapper mapper,
boolean equals)
Adds query statements, which contains named parameters that express the property that the id of the entity
with alias prefix is equal to the given object using the specified mapper.
|
ServiceRegistry |
getServiceRegistry() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
mapToEntityFromMap, mapToIdFromEntity, mapToIdFromMap, mapToMapFromEntity, mapToMapFromId, mapToMapFromId, mapToQueryParametersFromId, prefixMappedProperties
public AbstractIdMapper(ServiceRegistry serviceRegistry)
public ServiceRegistry getServiceRegistry()
getServiceRegistry
in interface IdMapper
public void addIdsEqualToQuery(Parameters parameters, String prefix1, String prefix2)
IdMapper
addIdsEqualToQuery
in interface IdMapper
parameters
- Parameters, to which to add the statements.prefix1
- First alias of the entity + prefix to add to the properties.prefix2
- Second alias of the entity + prefix to add to the properties.public void addIdsEqualToQuery(Parameters parameters, String prefix1, IdMapper mapper2, String prefix2)
IdMapper
addIdsEqualToQuery
in interface IdMapper
parameters
- Parameters, to which to add the statements.prefix1
- First alias of the entity + prefix to add to the properties.mapper2
- Second mapper for the same entity, which will be used to get properties for the right side
of the equation.prefix2
- Second alias of the entity + prefix to add to the properties.public void addIdEqualsToQuery(Parameters parameters, Object id, String alias, String prefix, boolean equals)
IdMapper
addIdEqualsToQuery
in interface IdMapper
parameters
- Parameters, to which to add the statements.id
- Value of id.alias
- the alias to use in the specified parameters (may be null).prefix
- Prefix to add to the properties (may be null).equals
- Should this query express the "=" relation or the "<>" relation.public void addNamedIdEqualsToQuery(Parameters parameters, String prefix, boolean equals)
IdMapper
addNamedIdEqualsToQuery
in interface IdMapper
parameters
- Parameters, to which to add the statements.prefix
- Prefix to add to the properties (may be null).equals
- Should this query express the "=" relation or the "<>" relation.public void addNamedIdEqualsToQuery(Parameters parameters, String prefix1, IdMapper mapper, boolean equals)
IdMapper
addNamedIdEqualsToQuery
in interface IdMapper
parameters
- Parameters, to which to add the statements.prefix1
- Prefix to add to the properties (may be null).mapper
- The identifier mapper to useequals
- Should this query express the "=" relation or the "<>" relation.Copyright © 2019 JBoss by Red Hat. All rights reserved.