Class ApiKey.Builder
- All Implemented Interfaces:
WithJson<ApiKey.Builder>,ObjectBuilder<ApiKey>
- Enclosing class:
- ApiKey
ApiKey.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aApiKey.final ApiKey.BuilderCreation time for the API key in milliseconds.final ApiKey.Builderexpiration(Long value) Expiration time for the API key in milliseconds.final ApiKey.BuilderRequired - Id for the API keyfinal ApiKey.Builderinvalidated(Boolean value) Invalidation status for the API key.final ApiKey.BuilderlimitedBy(List<Map<String, RoleDescriptor>> list) The owner user’s permissions associated with the API key.final ApiKey.BuilderlimitedBy(Map<String, RoleDescriptor> value, Map<String, RoleDescriptor>... values) The owner user’s permissions associated with the API key.final ApiKey.BuilderMetadata of the API keyfinal ApiKey.BuilderMetadata of the API keyfinal ApiKey.BuilderRequired - Name of the API key.final ApiKey.BuilderprofileUid(String value) The profile uid for the API key owner principal, if requested and if it existsfinal ApiKey.BuilderRealm name of the principal for which this API key was created.final ApiKey.BuilderRealm type of the principal for which this API key was createdfinal ApiKey.BuilderroleDescriptors(String key, RoleDescriptor value) The role descriptors assigned to this API key when it was created or last updated.final ApiKey.BuilderThe role descriptors assigned to this API key when it was created or last updated.final ApiKey.BuilderThe role descriptors assigned to this API key when it was created or last updated.protected ApiKey.Builderself()final ApiKey.Buildersort(boolean value, boolean... values) API name:_sortfinal ApiKey.Buildersort(double value, double... values) API name:_sortfinal ApiKey.Buildersort(long value, long... values) API name:_sortfinal ApiKey.Buildersort(FieldValue value, FieldValue... values) API name:_sortfinal ApiKey.BuilderAPI name:_sortfinal ApiKey.BuilderAPI name:_sortfinal ApiKey.Buildersort(List<FieldValue> list) API name:_sortfinal ApiKey.BuilderPrincipal for which this API key was createdMethods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJsonMethods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
creation
Creation time for the API key in milliseconds.API name:
creation -
expiration
Expiration time for the API key in milliseconds.API name:
expiration -
id
Required - Id for the API keyAPI name:
id -
invalidated
Invalidation status for the API key. If the key has been invalidated, it has a value oftrue. Otherwise, it isfalse.API name:
invalidated -
name
Required - Name of the API key.API name:
name -
realm
Realm name of the principal for which this API key was created.API name:
realm -
realmType
Realm type of the principal for which this API key was createdAPI name:
realm_type -
username
Principal for which this API key was createdAPI name:
username -
profileUid
The profile uid for the API key owner principal, if requested and if it existsAPI name:
profile_uid -
metadata
Metadata of the API keyAPI name:
metadataAdds all entries of
maptometadata. -
metadata
Metadata of the API keyAPI name:
metadataAdds an entry to
metadata. -
roleDescriptors
The role descriptors assigned to this API key when it was created or last updated. An empty role descriptor means the API key inherits the owner user’s permissions.API name:
role_descriptorsAdds all entries of
maptoroleDescriptors. -
roleDescriptors
The role descriptors assigned to this API key when it was created or last updated. An empty role descriptor means the API key inherits the owner user’s permissions.API name:
role_descriptorsAdds an entry to
roleDescriptors. -
roleDescriptors
public final ApiKey.Builder roleDescriptors(String key, Function<RoleDescriptor.Builder, ObjectBuilder<RoleDescriptor>> fn) The role descriptors assigned to this API key when it was created or last updated. An empty role descriptor means the API key inherits the owner user’s permissions.API name:
role_descriptorsAdds an entry to
roleDescriptorsusing a builder lambda. -
limitedBy
The owner user’s permissions associated with the API key. It is a point-in-time snapshot captured at creation and subsequent updates. An API key’s effective permissions are an intersection of its assigned privileges and the owner user’s permissions.API name:
limited_byAdds all elements of
listtolimitedBy. -
limitedBy
public final ApiKey.Builder limitedBy(Map<String, RoleDescriptor> value, Map<String, RoleDescriptor>... values) The owner user’s permissions associated with the API key. It is a point-in-time snapshot captured at creation and subsequent updates. An API key’s effective permissions are an intersection of its assigned privileges and the owner user’s permissions.API name:
limited_byAdds one or more values to
limitedBy. -
sort
API name:_sortAdds all elements of
listtosort. -
sort
API name:_sortAdds one or more values to
sort. -
sort
API name:_sortAdds all passed values to
sort. -
sort
API name:_sortAdds all passed values to
sort. -
sort
API name:_sortAdds all passed values to
sort. -
sort
API name:_sortAdds all passed values to
sort. -
sort
API name:_sortAdds a value to
sortusing a builder lambda. -
self
- Specified by:
selfin classWithJsonObjectBuilderBase<ApiKey.Builder>
-
build
Builds aApiKey.- Specified by:
buildin interfaceObjectBuilder<ApiKey>- Throws:
NullPointerException- if some of the required fields are null.
-