Class ReactiveCredHubPermissionV2Template
java.lang.Object
org.springframework.credhub.core.permissionV2.ReactiveCredHubPermissionV2Template
- All Implemented Interfaces:
ReactiveCredHubPermissionV2Operations
public class ReactiveCredHubPermissionV2Template
extends Object
implements ReactiveCredHubPermissionV2Operations
Implements the main interaction with CredHub to add, retrieve, and delete permissions.
- Author:
- Scott Frederick, Alberto C. RĂos
-
Constructor Summary
ConstructorsConstructorDescriptionReactiveCredHubPermissionV2Template(ReactiveCredHubOperations credHubOperations) Create a newReactiveCredHubPermissionV2Template. -
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Mono<CredentialPermission>addPermissions(CredentialName path, Permission permission) Add permissions to an credential path.reactor.core.publisher.Mono<Void>Delete a permission.reactor.core.publisher.Mono<CredentialPermission>getPermissions(String id) Get a permission.reactor.core.publisher.Mono<CredentialPermission>getPermissionsByPathAndActor(CredentialName path, Actor actor) Get a permission by path and actor.reactor.core.publisher.Mono<CredentialPermission>updatePermissions(String id, CredentialName path, Permission permission) Add permissions to an existing credential.
-
Constructor Details
-
ReactiveCredHubPermissionV2Template
Create a newReactiveCredHubPermissionV2Template.- Parameters:
credHubOperations- theReactiveCredHubOperationsto use for interactions with CredHub
-
-
Method Details
-
getPermissions
Description copied from interface:ReactiveCredHubPermissionV2OperationsGet a permission.- Specified by:
getPermissionsin interfaceReactiveCredHubPermissionV2Operations- Parameters:
id- the CredHub-assigned ID of the permission; must not be null- Returns:
- the details if the specified permission
-
addPermissions
public reactor.core.publisher.Mono<CredentialPermission> addPermissions(CredentialName path, Permission permission) Description copied from interface:ReactiveCredHubPermissionV2OperationsAdd permissions to an credential path.- Specified by:
addPermissionsin interfaceReactiveCredHubPermissionV2Operations- Parameters:
path- the path of the credentials; must not be nullpermission- a permission to add- Returns:
- the details if the added permission
-
getPermissionsByPathAndActor
public reactor.core.publisher.Mono<CredentialPermission> getPermissionsByPathAndActor(CredentialName path, Actor actor) Description copied from interface:ReactiveCredHubPermissionV2OperationsGet a permission by path and actor.- Specified by:
getPermissionsByPathAndActorin interfaceReactiveCredHubPermissionV2Operations- Parameters:
path- the path of the credentials; must not be nullactor- the actor of the credentials; must not be null- Returns:
- the details if the specified permission
-
updatePermissions
public reactor.core.publisher.Mono<CredentialPermission> updatePermissions(String id, CredentialName path, Permission permission) Description copied from interface:ReactiveCredHubPermissionV2OperationsAdd permissions to an existing credential.- Specified by:
updatePermissionsin interfaceReactiveCredHubPermissionV2Operations- Parameters:
id- the CredHub-assigned ID of the permission; must not be nullpath- the path of the credentials; must not be nullpermission- a permission to add- Returns:
- the details if the added permission
-
deletePermission
Description copied from interface:ReactiveCredHubPermissionV2OperationsDelete a permission.- Specified by:
deletePermissionin interfaceReactiveCredHubPermissionV2Operations- Parameters:
id- the CredHub-assigned ID of the permission; must not be null- Returns:
- an empty
Mono
-