Class PredicateRepositoryImpl
java.lang.Object
de.digitalcollections.cudami.server.backend.impl.database.AbstractPagingAndSortingRepositoryImpl
de.digitalcollections.cudami.server.backend.impl.jdbi.JdbiRepositoryImpl
de.digitalcollections.cudami.server.backend.impl.jdbi.identifiable.entity.relation.PredicateRepositoryImpl
- All Implemented Interfaces:
PredicateRepository
@Repository public class PredicateRepositoryImpl extends JdbiRepositoryImpl implements PredicateRepository
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringMAPPING_PREFIXstatic java.lang.StringSQL_FULL_FIELDS_PREDstatic java.lang.StringSQL_REDUCED_FIELDS_PREDstatic java.lang.StringTABLE_ALIASstatic java.lang.StringTABLE_NAMEFields inherited from class de.digitalcollections.cudami.server.backend.impl.jdbi.JdbiRepositoryImpl
dbi, mappingPrefix, tableAlias, tableName -
Constructor Summary
Constructors Constructor Description PredicateRepositoryImpl(org.jdbi.v3.core.Jdbi dbi) -
Method Summary
Modifier and Type Method Description voiddelete(java.lang.String value)java.util.List<de.digitalcollections.model.api.identifiable.entity.relation.Predicate>findAll()de.digitalcollections.model.api.identifiable.entity.relation.PredicatefindOneByValue(java.lang.String value)protected java.util.List<java.lang.String>getAllowedOrderByFields()protected java.lang.StringgetColumnName(java.lang.String modelProperty)de.digitalcollections.model.api.identifiable.entity.relation.Predicatesave(de.digitalcollections.model.api.identifiable.entity.relation.Predicate predicate)Methods inherited from class de.digitalcollections.cudami.server.backend.impl.jdbi.JdbiRepositoryImpl
count, getMappingPrefix, getTableAlias, getTableNameMethods inherited from class de.digitalcollections.cudami.server.backend.impl.database.AbstractPagingAndSortingRepositoryImpl
addFiltering, addFiltering, addLimit, addOffset, addOrderBy, addPageRequestParams, convertToSqlString, getFilterClauses, getOrderBy, getWhereClauseMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.digitalcollections.cudami.server.backend.api.repository.identifiable.entity.relation.PredicateRepository
count
-
Field Details
-
MAPPING_PREFIX
public static final java.lang.String MAPPING_PREFIX- See Also:
- Constant Field Values
-
SQL_REDUCED_FIELDS_PRED
public static final java.lang.String SQL_REDUCED_FIELDS_PRED- See Also:
- Constant Field Values
-
SQL_FULL_FIELDS_PRED
public static final java.lang.String SQL_FULL_FIELDS_PRED- See Also:
- Constant Field Values
-
TABLE_ALIAS
public static final java.lang.String TABLE_ALIAS- See Also:
- Constant Field Values
-
TABLE_NAME
public static final java.lang.String TABLE_NAME- See Also:
- Constant Field Values
-
-
Constructor Details
-
PredicateRepositoryImpl
@Autowired public PredicateRepositoryImpl(org.jdbi.v3.core.Jdbi dbi)
-
-
Method Details
-
delete
public void delete(java.lang.String value)- Specified by:
deletein interfacePredicateRepository
-
findAll
public java.util.List<de.digitalcollections.model.api.identifiable.entity.relation.Predicate> findAll()- Specified by:
findAllin interfacePredicateRepository
-
findOneByValue
public de.digitalcollections.model.api.identifiable.entity.relation.Predicate findOneByValue(java.lang.String value)- Specified by:
findOneByValuein interfacePredicateRepository
-
getAllowedOrderByFields
protected java.util.List<java.lang.String> getAllowedOrderByFields()- Specified by:
getAllowedOrderByFieldsin classAbstractPagingAndSortingRepositoryImpl- Returns:
- model properties names that are applicable for sorting, will be mapped to database column names using @see #getColumnName
-
getColumnName
protected java.lang.String getColumnName(java.lang.String modelProperty)- Specified by:
getColumnNamein classAbstractPagingAndSortingRepositoryImpl- Parameters:
modelProperty- name of model property passed as String, e.g. "lastModified"- Returns:
- full qualified column name as used in sql queries ("last_modified" or e.g. "w.last_modified" if prefix used in queries)
-
save
public de.digitalcollections.model.api.identifiable.entity.relation.Predicate save(de.digitalcollections.model.api.identifiable.entity.relation.Predicate predicate)- Specified by:
savein interfacePredicateRepository
-