Package org.eclipse.ditto.model.things
Interface Permissions
-
- All Superinterfaces:
Collection<Permission>
,Iterable<Permission>
,org.eclipse.ditto.model.base.json.Jsonifiable<org.eclipse.ditto.json.JsonObject>
,org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelector
,org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelectorAndPredicate<org.eclipse.ditto.json.JsonField>
,org.eclipse.ditto.model.base.json.Jsonifiable.WithPointer<org.eclipse.ditto.json.JsonObject>
,org.eclipse.ditto.model.base.json.Jsonifiable.WithPredicate<org.eclipse.ditto.json.JsonObject,org.eclipse.ditto.json.JsonField>
,Set<Permission>
@Deprecated public interface Permissions extends Set<Permission>, org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelectorAndPredicate<org.eclipse.ditto.json.JsonField>
Deprecated.Permissions belong to deprecated API version 1. Use API version 2 with policies instead.This set is dedicated to holdPermission
s only. Additionally to the methods defined inSet
this type also implementsJsonifiable
which means that a JSON representation can be obtained. This representation is a JSON object where all constants ofPermission
is a JSON key and the value is a JSON boolean literal which indicates whether that permission is contained in this set or not.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.eclipse.ditto.model.base.json.Jsonifiable
org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelector, org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelectorAndPredicate<T extends Object>, org.eclipse.ditto.model.base.json.Jsonifiable.WithPointer<J extends org.eclipse.ditto.json.JsonValue>, org.eclipse.ditto.model.base.json.Jsonifiable.WithPredicate<J extends org.eclipse.ditto.json.JsonValue,T extends Object>
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description boolean
contains(Permission permission, Permission... furtherPermissions)
Deprecated.Indicates whether this set of permissions contains the specified permission(s).default org.eclipse.ditto.model.base.json.JsonSchemaVersion[]
getSupportedSchemaVersions()
Deprecated.Permissions is only available in JsonSchemaVersion V_1.static Permissions
newInstance(Permission permission, Permission... furtherPermissions)
Deprecated.Returns a new mutablePermissions
containing the given permissions.default org.eclipse.ditto.json.JsonObject
toJson()
Deprecated.Returns all non hidden marked fields of this permissions.default org.eclipse.ditto.json.JsonObject
toJson(org.eclipse.ditto.model.base.json.JsonSchemaVersion schemaVersion, org.eclipse.ditto.json.JsonFieldSelector fieldSelector)
Deprecated.-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface org.eclipse.ditto.model.base.json.Jsonifiable
getImplementedSchemaVersion, getLatestSchemaVersion, implementsSchemaVersion, implementsSchemaVersion, toJsonString
-
Methods inherited from interface org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelector
toJson, toJson, toJson, toJsonString, toJsonString
-
Methods inherited from interface org.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelectorAndPredicate
toJson, toJson, toJsonString, toJsonString
-
Methods inherited from interface org.eclipse.ditto.model.base.json.Jsonifiable.WithPointer
toJsonString, toJsonString
-
-
-
-
Method Detail
-
newInstance
static Permissions newInstance(Permission permission, Permission... furtherPermissions)
Deprecated.Returns a new mutablePermissions
containing the given permissions.- Parameters:
permission
- the mandatory permission to be contained in the result.furtherPermissions
- additional permissions to be contained in the result.- Returns:
- the new
Permissions
. - Throws:
NullPointerException
- if any argument isnull
.
-
getSupportedSchemaVersions
default org.eclipse.ditto.model.base.json.JsonSchemaVersion[] getSupportedSchemaVersions()
Deprecated.Permissions is only available in JsonSchemaVersion V_1.- Specified by:
getSupportedSchemaVersions
in interfaceorg.eclipse.ditto.model.base.json.Jsonifiable<org.eclipse.ditto.json.JsonObject>
- Returns:
- the supported JsonSchemaVersions of Permissions.
-
contains
boolean contains(Permission permission, Permission... furtherPermissions)
Deprecated.Indicates whether this set of permissions contains the specified permission(s). The result istrue
if all specified permissions are contained in this set.- Parameters:
permission
- the permission whose presence in this set is to be tested.furtherPermissions
- additional permissions whose presence in this set is to be tested.- Returns:
true
if this set contains each specified permission,false
else.- Throws:
NullPointerException
- if any argument isnull
.
-
toJson
default org.eclipse.ditto.json.JsonObject toJson()
Deprecated.Returns all non hidden marked fields of this permissions.- Specified by:
toJson
in interfaceorg.eclipse.ditto.model.base.json.Jsonifiable<org.eclipse.ditto.json.JsonObject>
- Returns:
- a JSON object representation of this permissions including only non hidden marked fields.
-
toJson
default org.eclipse.ditto.json.JsonObject toJson(org.eclipse.ditto.model.base.json.JsonSchemaVersion schemaVersion, org.eclipse.ditto.json.JsonFieldSelector fieldSelector)
Deprecated.- Specified by:
toJson
in interfaceorg.eclipse.ditto.model.base.json.Jsonifiable.WithFieldSelector
-
-