Class JpaCustomizedAccountRoleRepository<D extends JpaAccountRole>
- java.lang.Object
-
- com.broadleafcommerce.customer.provider.jpa.repository.JpaCustomizedAccountRoleRepository<D>
-
- All Implemented Interfaces:
com.broadleafcommerce.common.extension.DomainTypeAware
,CustomizedAccountRoleRepository<D>
public class JpaCustomizedAccountRoleRepository<D extends JpaAccountRole> extends Object implements CustomizedAccountRoleRepository<D>
Specialized implementation ofJpaAccountRoleRepository
.- Author:
- Samarth Dhruva (samarthd), Chris Kittrell (ckittrell)
-
-
Constructor Summary
Constructors Constructor Description JpaCustomizedAccountRoleRepository()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
existsByNameAndIdNot(@NonNull String name, String id, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Reports whether there exists a role in the data store whoseAccountRole.getName()
is equal to the givenname
and whoseAccountRole.getId()
is not equal to the givenid
.Class<D>
getDomainType()
Object
save(Object entity)
List<Object>
saveAll(Iterable<?> entities)
-
-
-
Method Detail
-
saveAll
@Transactional("customerTransactionManager") public List<Object> saveAll(Iterable<?> entities)
-
getDomainType
public Class<D> getDomainType()
- Specified by:
getDomainType
in interfacecom.broadleafcommerce.common.extension.DomainTypeAware
-
existsByNameAndIdNot
public boolean existsByNameAndIdNot(@NonNull @NonNull String name, @Nullable String id, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Description copied from interface:CustomizedAccountRoleRepository
Reports whether there exists a role in the data store whoseAccountRole.getName()
is equal to the givenname
and whoseAccountRole.getId()
is not equal to the givenid
.Results are restricted to only the roles accessible from the given context as described in the class-level javadocs.
- Specified by:
existsByNameAndIdNot
in interfaceCustomizedAccountRoleRepository<D extends JpaAccountRole>
- Parameters:
name
- the value that role name must equal in order to matchid
- (optional) the value that the role's id must not equal in order to match. If this value isnull
, then results will not be filtered by their id.contextInfo
- The context of the user's request- Returns:
true
if there exists a role with a matching or null tenant ID, a matching name, and a not matching id,false
otherwise
-
-