Class OAuth2RestService
java.lang.Object
com.bytedesk.core.base.BaseRestService<OAuth2Entity,OAuth2Request,OAuth2Response>
com.bytedesk.core.rbac.auth.oauth2.OAuth2RestService
@Service
public class OAuth2RestService
extends BaseRestService<OAuth2Entity,OAuth2Request,OAuth2Response>
-
Field Summary
Fields inherited from class com.bytedesk.core.base.BaseRestService
authService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvertToResponse(OAuth2Entity entity) create(OAuth2Request request) protected org.springframework.data.jpa.domain.Specification<OAuth2Entity>createSpecification(OAuth2Request request) 创建Specification对象,子类必须实现 用于queryByOrg的通用实现voiddelete(OAuth2Request entity) voiddeleteByUid(String uid) protected OAuth2EntitydoSave(OAuth2Entity entity) 子类实现具体的保存逻辑protected org.springframework.data.domain.Page<OAuth2Entity>executePageQuery(org.springframework.data.jpa.domain.Specification<OAuth2Entity> specification, org.springframework.data.domain.Pageable pageable) 执行分页查询,子类必须实现 用于queryByOrg的通用实现handleOptimisticLockingFailureException(org.springframework.orm.ObjectOptimisticLockingFailureException e, OAuth2Entity entity) org.springframework.data.domain.Page<OAuth2Response>queryByOrg(OAuth2Request request) 通用的queryByOrg实现 子类如果有特殊逻辑可以重写此方法queryByUid(OAuth2Request request) 通用的queryByUid实现org.springframework.data.domain.Page<OAuth2Response>queryByUser(OAuth2Request request) 通用的queryByUser实现 子类如果有特殊逻辑可以重写此方法save(OAuth2Entity entity) 保存实体,带重试机制update(OAuth2Request request) Methods inherited from class com.bytedesk.core.base.BaseRestService
deleteByOrgUid, findByOrgUid, getUidFromRequest, recover, setUserUidToRequest
-
Constructor Details
-
OAuth2RestService
public OAuth2RestService()
-
-
Method Details
-
queryByOrg
Description copied from class:BaseRestService通用的queryByOrg实现 子类如果有特殊逻辑可以重写此方法- Overrides:
queryByOrgin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
queryByUser
Description copied from class:BaseRestService通用的queryByUser实现 子类如果有特殊逻辑可以重写此方法- Overrides:
queryByUserin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
findByUid
- Specified by:
findByUidin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
create
- Specified by:
createin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
update
- Specified by:
updatein classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
save
Description copied from class:BaseRestService保存实体,带重试机制- Overrides:
savein classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
doSave
Description copied from class:BaseRestService子类实现具体的保存逻辑- Specified by:
doSavein classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
handleOptimisticLockingFailureException
public OAuth2Entity handleOptimisticLockingFailureException(org.springframework.orm.ObjectOptimisticLockingFailureException e, OAuth2Entity entity) - Specified by:
handleOptimisticLockingFailureExceptionin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
deleteByUid
- Specified by:
deleteByUidin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
delete
- Specified by:
deletein classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
convertToResponse
- Specified by:
convertToResponsein classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
queryByUid
Description copied from class:BaseRestService通用的queryByUid实现- Overrides:
queryByUidin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
createSpecification
protected org.springframework.data.jpa.domain.Specification<OAuth2Entity> createSpecification(OAuth2Request request) Description copied from class:BaseRestService创建Specification对象,子类必须实现 用于queryByOrg的通用实现- Specified by:
createSpecificationin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-
executePageQuery
protected org.springframework.data.domain.Page<OAuth2Entity> executePageQuery(org.springframework.data.jpa.domain.Specification<OAuth2Entity> specification, org.springframework.data.domain.Pageable pageable) Description copied from class:BaseRestService执行分页查询,子类必须实现 用于queryByOrg的通用实现- Specified by:
executePageQueryin classBaseRestService<OAuth2Entity,OAuth2Request, OAuth2Response>
-