Package com.vmware.nsx_policy.model
Class RoleBinding.Builder
- java.lang.Object
-
- com.vmware.nsx_policy.model.RoleBinding.Builder
-
- Enclosing class:
- RoleBinding
public static final class RoleBinding.Builder extends java.lang.Object
Builder class forRoleBinding
.
-
-
Constructor Summary
Constructors Constructor Description Builder()
Constructor with parameters for the required properties ofRoleBinding
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RoleBinding
build()
RoleBinding.Builder
setCreateTime(java.lang.Long createTime)
Timestamp of resource creation format: int64 This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setCreateUser(java.lang.String createUser)
ID of the user who created this resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setDescription(java.lang.String description)
Description of this resourceRoleBinding.Builder
setDisplayName(java.lang.String displayName)
Defaults to ID if not setRoleBinding.Builder
setId(java.lang.String id)
Unique identifier of this resourceRoleBinding.Builder
setIdentitySourceId(java.lang.String identitySourceId)
The ID of the external identity source that holds the referenced external entity.RoleBinding.Builder
setIdentitySourceType(java.lang.String identitySourceType)
Possible values are:RoleBinding.IDENTITY_SOURCE_TYPE_VIDM
RoleBinding.IDENTITY_SOURCE_TYPE_LDAP
RoleBinding.IDENTITY_SOURCE_TYPE_OIDC
RoleBinding.IDENTITY_SOURCE_TYPE_CSP
Identity source typeRoleBinding.Builder
setLastModifiedTime(java.lang.Long lastModifiedTime)
Timestamp of last modification format: int64 This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setLastModifiedUser(java.lang.String lastModifiedUser)
ID of the user who last modified this resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setLinks(java.util.List<ResourceLink> links)
The server will populate this field when returing the resource.RoleBinding.Builder
setName(java.lang.String name)
User/Group's name This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setProtection(java.lang.String protection)
Protection status is one of the following: PROTECTED - the client who retrieved the entity is not allowed to modify it.RoleBinding.Builder
setReadRolesForPaths(java.lang.Boolean readRolesForPaths)
Set this property to true to cause the user's role definition to be read from the roles_for_paths property.RoleBinding.Builder
setResourceType(java.lang.String resourceType)
The type of this resource.RoleBinding.Builder
setRevision(java.lang.Long revision)
The _revision property describes the current revision of the resource.RoleBinding.Builder
setRoles(java.util.List<Role> roles)
Roles This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setRolesForPaths(java.util.List<RolesForPath> rolesForPaths)
The roles that are associated with the user, limiting them to a path.RoleBinding.Builder
setSchema(java.lang.String schema)
Schema for this resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setSelf(SelfResourceLink self)
RoleBinding.Builder
setStale(java.lang.String stale)
Possible values are:RoleBinding.STALE_TRUE
RoleBinding.STALE_FALSE
RoleBinding.STALE_UNKNOWN
Property 'stale' can be considered to have these values - absent - This type of rolebinding does not support stale property TRUE - Rolebinding is stale in vIDM meaning the user is no longer present in vIDM FALSE - Rolebinding is available in vIDM UNKNOWN - Rolebinding's state of staleness in unknown Once rolebindings become stale, they can be deleted using the API POST /aaa/role-bindings?action=delete_stale_bindings This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setSystemOwned(java.lang.Boolean systemOwned)
Indicates system owned resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.RoleBinding.Builder
setTags(java.util.List<Tag> tags)
Opaque identifiers meaningful to the API userRoleBinding.Builder
setType(java.lang.String type)
Possible values are:RoleBinding.TYPE_REMOTE_USER
RoleBinding.TYPE_REMOTE_GROUP
RoleBinding.TYPE_LOCAL_USER
RoleBinding.TYPE_PRINCIPAL_IDENTITY
RoleBinding.TYPE_REMOTE
Indicates the type of the user.RoleBinding.Builder
setUserId(java.lang.String userId)
Local user's numeric id on the system.
-
-
-
Constructor Detail
-
Builder
public Builder()
Constructor with parameters for the required properties ofRoleBinding
.
-
-
Method Detail
-
setLinks
public RoleBinding.Builder setLinks(java.util.List<ResourceLink> links)
The server will populate this field when returing the resource. Ignored on PUT and POST. This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
links
- New value for the property.
-
setSchema
public RoleBinding.Builder setSchema(java.lang.String schema)
Schema for this resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
schema
- New value for the property.
-
setSelf
public RoleBinding.Builder setSelf(SelfResourceLink self)
- Parameters:
self
- New value for the property.
-
setRevision
public RoleBinding.Builder setRevision(java.lang.Long revision)
The _revision property describes the current revision of the resource. To prevent clients from overwriting each other's changes, PUT operations must include the current _revision of the resource, which clients should obtain by issuing a GET operation. If the _revision provided in a PUT request is missing or stale, the operation will be rejected. format: int32- Parameters:
revision
- New value for the property.
-
setCreateTime
public RoleBinding.Builder setCreateTime(java.lang.Long createTime)
Timestamp of resource creation format: int64 This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
createTime
- New value for the property.
-
setCreateUser
public RoleBinding.Builder setCreateUser(java.lang.String createUser)
ID of the user who created this resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
createUser
- New value for the property.
-
setLastModifiedTime
public RoleBinding.Builder setLastModifiedTime(java.lang.Long lastModifiedTime)
Timestamp of last modification format: int64 This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
lastModifiedTime
- New value for the property.
-
setLastModifiedUser
public RoleBinding.Builder setLastModifiedUser(java.lang.String lastModifiedUser)
ID of the user who last modified this resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
lastModifiedUser
- New value for the property.
-
setProtection
public RoleBinding.Builder setProtection(java.lang.String protection)
Protection status is one of the following: PROTECTED - the client who retrieved the entity is not allowed to modify it. NOT_PROTECTED - the client who retrieved the entity is allowed to modify it REQUIRE_OVERRIDE - the client who retrieved the entity is a super user and can modify it, but only when providing the request header X-Allow-Overwrite=true. UNKNOWN - the _protection field could not be determined for this entity. This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
protection
- New value for the property.
-
setSystemOwned
public RoleBinding.Builder setSystemOwned(java.lang.Boolean systemOwned)
Indicates system owned resource This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
systemOwned
- New value for the property.
-
setDescription
public RoleBinding.Builder setDescription(java.lang.String description)
Description of this resource- Parameters:
description
- New value for the property.
-
setDisplayName
public RoleBinding.Builder setDisplayName(java.lang.String displayName)
Defaults to ID if not set- Parameters:
displayName
- New value for the property.
-
setId
public RoleBinding.Builder setId(java.lang.String id)
Unique identifier of this resource- Parameters:
id
- New value for the property.
-
setResourceType
public RoleBinding.Builder setResourceType(java.lang.String resourceType)
The type of this resource.- Parameters:
resourceType
- New value for the property.
-
setTags
public RoleBinding.Builder setTags(java.util.List<Tag> tags)
Opaque identifiers meaningful to the API user- Parameters:
tags
- New value for the property.
-
setIdentitySourceId
public RoleBinding.Builder setIdentitySourceId(java.lang.String identitySourceId)
The ID of the external identity source that holds the referenced external entity. Currently, only external LDAP and OIDC servers are allowed.- Parameters:
identitySourceId
- New value for the property.
-
setIdentitySourceType
public RoleBinding.Builder setIdentitySourceType(java.lang.String identitySourceType)
Possible values are: Identity source type- Parameters:
identitySourceType
- New value for the property.
-
setName
public RoleBinding.Builder setName(java.lang.String name)
User/Group's name This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
name
- New value for the property.
-
setReadRolesForPaths
public RoleBinding.Builder setReadRolesForPaths(java.lang.Boolean readRolesForPaths)
Set this property to true to cause the user's role definition to be read from the roles_for_paths property. Set it to false to cause the user's role definition to be read from the roles property.- Parameters:
readRolesForPaths
- New value for the property.
-
setRoles
public RoleBinding.Builder setRoles(java.util.List<Role> roles)
Roles This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
roles
- New value for the property.
-
setRolesForPaths
public RoleBinding.Builder setRolesForPaths(java.util.List<RolesForPath> rolesForPaths)
The roles that are associated with the user, limiting them to a path. In case the path is '/', the roles apply everywhere i.e. it is same as the deprecated property roles.- Parameters:
rolesForPaths
- New value for the property.
-
setStale
public RoleBinding.Builder setStale(java.lang.String stale)
Possible values are: Property 'stale' can be considered to have these values - absent - This type of rolebinding does not support stale property TRUE - Rolebinding is stale in vIDM meaning the user is no longer present in vIDM FALSE - Rolebinding is available in vIDM UNKNOWN - Rolebinding's state of staleness in unknown Once rolebindings become stale, they can be deleted using the API POST /aaa/role-bindings?action=delete_stale_bindings This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
stale
- New value for the property.
-
setType
public RoleBinding.Builder setType(java.lang.String type)
Possible values are: Indicates the type of the user. remote_user - This is a user which is external to NSX. remote_group - This is a group of users which is external to NSX. local_user - This is a user local to NSX. These are linux users. principal_identity - This is a principal identity user. remote - The the principal is remote but whether it is a user or group is not known. Currently this is applicable only to LDAP identity_source_type. This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
type
- New value for the property.
-
setUserId
public RoleBinding.Builder setUserId(java.lang.String userId)
Local user's numeric id on the system. This property may be present in responses from the server, but if it is present in a request to server it will be ignored.- Parameters:
userId
- New value for the property.
-
build
public RoleBinding build()
-
-