mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-3745] Updates for doc review (#4203)
This commit is contained in:
committed by
Eugenio Romano
parent
44b18659a1
commit
54a1a90083
@@ -2,7 +2,7 @@
|
||||
Title: Identity user service
|
||||
Added: v3.0.0
|
||||
Status: Active
|
||||
Last reviewed: 2019-01-09
|
||||
Last reviewed: 2019-01-23
|
||||
---
|
||||
|
||||
# [Identity user service](../../lib/core/userinfo/services/identity-user.service.ts "Defined in identity-user.service.ts")
|
||||
@@ -13,6 +13,41 @@ Gets OAuth2 personal details and roles for users.
|
||||
|
||||
### Methods
|
||||
|
||||
- **checkUserHasAnyApplicationRole**(userId: `string`, applicationName: `string`, roleNames: `string[]`): [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Checks if a user has any application role.
|
||||
- _userId:_ `string` - ID of the target user
|
||||
- _applicationName:_ `string` - Name of the application
|
||||
- _roleNames:_ `string[]` - List of role names to check for
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>` - True if the user has one or more of the roles, false otherwise
|
||||
- **checkUserHasAnyClientAppRole**(userId: `string`, clientId: `string`, roleNames: `string[]`): [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Checks whether a user has any of the client app roles.
|
||||
- _userId:_ `string` - ID of the target user
|
||||
- _clientId:_ `string` - ID of the client app
|
||||
- _roleNames:_ `string[]` - List of role names to check for
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>` - True if the user has one or more of the roles, false otherwise
|
||||
- **checkUserHasApplicationAccess**(userId: `string`, applicationName: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Checks if a user has access to an application.
|
||||
- _userId:_ `string` - ID of the user
|
||||
- _applicationName:_ `string` - Name of the application
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>` - True if the user has access, false otherwise
|
||||
- **checkUserHasClientApp**(userId: `string`, clientId: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Checks whether user has access to a client app.
|
||||
- _userId:_ `string` - ID of the target user
|
||||
- _clientId:_ `string` - ID of the client app
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>` - True if the user has access, false otherwise
|
||||
- **findUsersByName**(search: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<any>`<br/>
|
||||
Find users based on search input.
|
||||
- _search:_ `string` - Search query string
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<any>` - List of users
|
||||
- **getClientIdByApplicationName**(applicationName: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<string>`<br/>
|
||||
Gets the client ID for an application.
|
||||
- _applicationName:_ `string` - Name of the application
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<string>` - Client ID string
|
||||
- **getClientRoles**(userId: `string`, clientId: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<any[]>`<br/>
|
||||
Get client roles of a user for a particular client.
|
||||
- _userId:_ `string` - ID of the target user
|
||||
- _clientId:_ `string` - ID of the client app
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<any[]>` - List of client roles
|
||||
- **getCurrentUserInfo**(): [`IdentityUserModel`](../../lib/core/userinfo/models/identity-user.model.ts)<br/>
|
||||
Gets the name and other basic details of the current user.
|
||||
- **Returns** [`IdentityUserModel`](../../lib/core/userinfo/models/identity-user.model.ts) - The user's details
|
||||
|
@@ -2,28 +2,61 @@
|
||||
Title: Renditions service
|
||||
Added: v2.0.0
|
||||
Status: Active
|
||||
Last reviewed: 2019-01-23
|
||||
---
|
||||
|
||||
# [Renditions service](../../lib/core/services/renditions.service.ts "Defined in renditions.service.ts")
|
||||
|
||||
Manages prearranged conversions of content to different formats.
|
||||
|
||||
## Methods
|
||||
## Class members
|
||||
|
||||
`isRenditionAvailable(nodeId: string, encoding: string):`[`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Has the specified rendition been set up for this item?
|
||||
### Methods
|
||||
|
||||
`isConversionPossible(nodeId: string, encoding: string):`[`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Is it possible to convert this item to the specified format?
|
||||
|
||||
`getRenditionUrl(nodeId: string, encoding: string): string`<br/>
|
||||
Gets a URL linking to a rendition.
|
||||
|
||||
`getRenditionsListByNodeId(nodeId: string):`[`Observable`](http://reactivex.io/documentation/observable.html)`<RenditionPaging>`<br/>
|
||||
Gets all available renditions for an item.
|
||||
|
||||
`convert(nodeId: string, encoding: string, pollingInterval: number = 1000)`<br/>
|
||||
Performs a format conversion on an item directly.
|
||||
- **convert**(nodeId: `string`, encoding: `string`, pollingInterval: `number` = `1000`, retries: `number` = `5`): [`Observable`](http://reactivex.io/documentation/observable.html)`<Object>`<br/>
|
||||
Repeatedly attempts to create a rendition, through to success or failure.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- _encoding:_ `string` - Name of the rendition encoding
|
||||
- _pollingInterval:_ `number` - Time interval (in milliseconds) between checks for completion
|
||||
- _retries:_ `number` - Number of attempts to make before declaring failure
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<Object>` - True if the rendition was created, false otherwise
|
||||
- **createRendition**(nodeId: `string`, encoding: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<__type>`<br/>
|
||||
Creates a rendition for a node.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- _encoding:_ `string` - Name of the rendition encoding
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<__type>` - Null response to indicate completion
|
||||
- **generateRenditionForNode**(nodeId: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<any>`<br/>
|
||||
Generates a rendition for a node using the first available encoding.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<any>` - Null response to indicate completion
|
||||
- **getAvailableRenditionForNode**(nodeId: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`RenditionEntry`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionEntry.md)`>`<br/>
|
||||
Gets the first available rendition found for a node.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`RenditionEntry`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionEntry.md)`>` - Information object for the rendition
|
||||
- **getRendition**(nodeId: `string`, encoding: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`RenditionEntry`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionEntry.md)`>`<br/>
|
||||
Gets information about a rendition of a node.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- _encoding:_ `string` - Name of the rendition encoding
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`RenditionEntry`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionEntry.md)`>` - Information object about the rendition
|
||||
- **getRenditionUrl**(nodeId: `string`, encoding: `string`): `string`<br/>
|
||||
Gets a URL linking to the specified rendition of a node.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- _encoding:_ `string` - Name of the rendition encoding
|
||||
- **Returns** `string` - URL string
|
||||
- **getRenditionsListByNodeId**(nodeId: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`RenditionPaging`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionPaging.md)`>`<br/>
|
||||
Gets a list of all renditions for a node.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`RenditionPaging`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionPaging.md)`>` - Paged list of rendition details
|
||||
- **isConversionPossible**(nodeId: `string`, encoding: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Checks if the node can be converted using the specified rendition.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- _encoding:_ `string` - Name of the rendition encoding
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>` - True if the node can be converted, false otherwise
|
||||
- **isRenditionAvailable**(nodeId: `string`, encoding: `string`): [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>`<br/>
|
||||
Checks if the specified rendition is available for a node.
|
||||
- _nodeId:_ `string` - ID of the target node
|
||||
- _encoding:_ `string` - Name of the rendition encoding
|
||||
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<boolean>` - True if the rendition is available, false otherwise
|
||||
|
||||
## Details
|
||||
|
||||
@@ -42,5 +75,5 @@ in the ADF API. The `encoding` identifies the conversion performed by the rendit
|
||||
See the
|
||||
[Renditions API page](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionsApi.md#createRendition)
|
||||
in the Alfresco JS API for more information about the
|
||||
[RenditionPaging](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionPaging.md)
|
||||
[`RenditionPaging`](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/RenditionPaging.md)
|
||||
class and other implementation details.
|
||||
|
Reference in New Issue
Block a user