Package org.gitana.platform.client.identity

# Class IdentityImpl

java.lang.Object
org.gitana.platform.support.GitanaObjectImpl
org.gitana.platform.client.document.DocumentImpl
org.gitana.platform.client.platform.AbstractPlatformDocumentImpl
org.gitana.platform.client.directory.AbstractDirectoryDocumentImpl
org.gitana.platform.client.identity.IdentityImpl

All Implemented Interfaces:
  `Serializable`, `DirectoryDocument`, `Document`, `Identity`, `PlatformDocument`, `Copyable`, `Referenceable`, `Selfable`, `TitleDescription`, `Transferable`, `TypedID`, `org.gitana.platform.GitanaObject`, `org.gitana.platform.JSONable`

public class IdentityImpl extends AbstractDirectoryDocumentImpl implements Identity

Author:
  uzi
See Also:
  - Serialized Form

## Field Summary

### Fields inherited from class org.gitana.platform.support.GitanaObjectImpl

`serialVersionUID`

### Fields inherited from interface org.gitana.platform.client.document.Document

`FIELD_ID, SYSTEM, SYSTEM_CREATED_BY, SYSTEM_CREATED_ON, SYSTEM_MODIFIED_BY, SYSTEM_MODIFIED_ON`

### Fields inherited from interface org.gitana.platform.client.support.TitleDescription

`FIELD_DESCRIPTION, FIELD_TITLE`

## Constructor Summary

Constructors
Constructor
Description
`IdentityImpl(Directory directory, com.fasterxml.jackson.databind.node.ObjectNode obj, boolean isSaved)`

## Method Summary

Modifier and Type
Method
Description
`void`
`changePassword(String password, String verifyPassword)`
Changes the password for this identity.
`void`
`delete()`
Delete
`boolean`
`equals(Object object)`
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findPolicyTenantObjects()`
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findPolicyTenantObjects(String authorityId)`
Finds all of the tenant objects that this identity's policy's users participate in.
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findPolicyTenantObjects(Registrar registrar)`
Finds all of the tenant objects that this identity's policy's users participate in.
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findPolicyTenantObjects(Registrar registrar, String authorityId)`
Finds all of the tenant objects that this identity's policy's users participate in.
`com.fasterxml.jackson.databind.node.ObjectNode`
`findPolicyUserObjectForTenant(String tenantId)`
Finds the first user object that this identity's policy has on the given tenant's platform.
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findPolicyUserObjects()`
Retrieves a map of all of the user objects that this identity's policy has on any platform.
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findPolicyUserObjects(String tenantId)`
Retrieves a map of all of the user objects that this identity's policy has on any platform.
`org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode>`
`findRecipientUserObjects()`
Retrieves a map of all of the user objects that are recipients of this identity.
`protected String`
`getResourceUri()`
`String`
`getTypeId()`
`void`
`reload()`
Reload
`void`
`update()`
Update

### Methods inherited from class org.gitana.platform.client.directory.AbstractDirectoryDocumentImpl

`getDirectory, getDirectoryId, getPlatform, ref`

### Methods inherited from class org.gitana.platform.client.platform.AbstractPlatformDocumentImpl

`copy, copy, copyAsync, copyAsync, exportArchive, exportArchive, exportArchive, getCluster, getDriver, getFactory, getPlatformId, getRemote, importArchive, importArchive, importArchive`

### Methods inherited from class org.gitana.platform.client.document.DocumentImpl

`dateCreated, dateModified, getCreatedBy, getDescription, getId, getModifiedBy, getSystemObject, getTitle, isSaved, mergeProperties, mergePropertyIfExists, reload, reload, setDescription, setId, setSaved, setTitle`

### Methods inherited from class org.gitana.platform.support.GitanaObjectImpl

`_objectGetFloat, _objectGetInt, _objectGetLong, _objectGetObject, _objectGetString, _objectSet, get, getArray, getAsJsonNode, getBigDecimal, getBoolean, getDouble, getInt, getLong, getObject, getObject, getString, has, putAll, putAll, putObject, remove, set, toJSON, toJSONString, toString`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface org.gitana.platform.client.support.Copyable

`copy, copy, copyAsync, copyAsync`

### Methods inherited from interface org.gitana.platform.client.directory.DirectoryDocument

`getDirectory, getDirectoryId, getPlatform`

### Methods inherited from interface org.gitana.platform.client.document.Document

`dateCreated, dateModified, getCreatedBy, getId, getModifiedBy, getSystemObject, isSaved, reload, reload, setId, setSaved`

### Methods inherited from interface org.gitana.platform.GitanaObject

`get, getArray, getAsJsonNode, getBigDecimal, getBoolean, getDouble, getInt, getLong, getObject, getObject, getString, has, putAll, putAll, remove, set`

### Methods inherited from interface org.gitana.platform.JSONable

`toJSON, toJSONString`

### Methods inherited from interface org.gitana.platform.client.platform.PlatformDocument

`getPlatformId`

### Methods inherited from interface org.gitana.platform.client.support.Referenceable

`ref`

### Methods inherited from interface org.gitana.platform.client.support.TitleDescription

`getDescription, getTitle, setDescription, setTitle`

### Methods inherited from interface org.gitana.platform.client.support.Transferable

`exportArchive, exportArchive, exportArchive, importArchive, importArchive, importArchive`

### Methods inherited from interface org.gitana.platform.client.support.TypedID

`getId`

## Constructor Details

### IdentityImpl

public IdentityImpl(Directory directory, com.fasterxml.jackson.databind.node.ObjectNode obj, boolean isSaved)

## Method Details

### getTypeId

public String getTypeId()

Specified by:
  `getTypeId` in interface `TypedID`

### getResourceUri

protected String getResourceUri()

Specified by:
  `getResourceUri` in class `AbstractPlatformDocumentImpl`

### equals

public boolean equals(Object object)

Overrides:
  `equals` in class `Object`

### update

public void update()
Description copied from interface: `Selfable`
Update

Specified by:
  `update` in interface `Selfable`

### delete

public void delete()
Description copied from interface: `Selfable`
Delete

Specified by:
  `delete` in interface `Selfable`

### reload

public void reload()
Description copied from interface: `Selfable`
Reload

Specified by:
  `reload` in interface `Selfable`

### changePassword

public void changePassword(String password, String verifyPassword)
Description copied from interface: `Identity`
Changes the password for this identity.

Specified by:
  `changePassword` in interface `Identity`
Parameters:
  `password` -
  `verifyPassword` -

### findPolicyUserObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findPolicyUserObjects()
Description copied from interface: `Identity`
Retrieves a map of all of the user objects that this identity's policy has on any platform.

Specified by:
  `findPolicyUserObjects` in interface `Identity`
Returns:
  result map

### findPolicyUserObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findPolicyUserObjects(String tenantId)
Description copied from interface: `Identity`
Retrieves a map of all of the user objects that this identity's policy has on any platform. If a tenant ID is supplied, then only those user objects on the provided tenant will be handed back.

Specified by:
  `findPolicyUserObjects` in interface `Identity`
Parameters:
  `tenantId` - tenant ID
Returns:
  result map

### findPolicyUserObjectForTenant

public com.fasterxml.jackson.databind.node.ObjectNode findPolicyUserObjectForTenant(String tenantId)
Description copied from interface: `Identity`
Finds the first user object that this identity's policy has on the given tenant's platform.

Specified by:
  `findPolicyUserObjectForTenant` in interface `Identity`
Parameters:
  `tenantId` -
Returns:
  user object

### findPolicyTenantObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findPolicyTenantObjects()

Specified by:
  `findPolicyTenantObjects` in interface `Identity`
Returns:
  all of the tenant objects that this identity's policy's users participate in

### findPolicyTenantObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findPolicyTenantObjects(Registrar registrar)
Description copied from interface: `Identity`
Finds all of the tenant objects that this identity's policy's users participate in. Filters and keeps only those within the specified registry.

Specified by:
  `findPolicyTenantObjects` in interface `Identity`
Parameters:
  `registrar` -
Returns:

### findPolicyTenantObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findPolicyTenantObjects(String authorityId)
Description copied from interface: `Identity`
Finds all of the tenant objects that this identity's policy's users participate in. Filters and keeps only those tenants whose user has the specified authority against the tenant platform.

Specified by:
  `findPolicyTenantObjects` in interface `Identity`
Parameters:
  `authorityId` -
Returns:

### findPolicyTenantObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findPolicyTenantObjects(Registrar registrar, String authorityId)
Description copied from interface: `Identity`
Finds all of the tenant objects that this identity's policy's users participate in. Filters and keeps only those within the specified registry. Keeps only those tenants whose user has the specified authority against the tenant platform.

Specified by:
  `findPolicyTenantObjects` in interface `Identity`
Parameters:
  `registrar` -
Returns:

### findRecipientUserObjects

public org.gitana.platform.support.ResultMap<com.fasterxml.jackson.databind.node.ObjectNode> findRecipientUserObjects()
Description copied from interface: `Identity`
Retrieves a map of all of the user objects that are recipients of this identity.

Specified by:
  `findRecipientUserObjects` in interface `Identity`
Returns:
  result map