Interface IMediaShareService
The IMediaShareService defines the methods used for working with MediaShare instances.
Namespace: ImageVault.Common.Services
Assembly: ImageVault.Common.dll
Syntax
public interface IMediaShareService : IService
Methods
Delete(String)
Deletes the share with the given id.
Declaration
void Delete(string shareId)
Parameters
Type | Name | Description |
---|---|---|
System.String | shareId | Id of share to delete |
FindShareByMediaItemId(Int32)
Find all shares, containing the given mediaItemId.
Declaration
IEnumerable<MediaShare> FindShareByMediaItemId(int mediaItemId)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | mediaItemId | The Id to search for |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<MediaShare> | Enumerable set of MediaShares |
Get(String, MediaItemQuery)
Gets the media share with the supplied id using extra formats and information from the supplied query
Declaration
MediaShare Get(string id, MediaItemQuery query)
Parameters
Type | Name | Description |
---|---|---|
System.String | id | The id of the Media share to get |
MediaItemQuery | query | The query to use to retrieve extra information. Filter.Id, Populate.PublishIdentifier, Populate.MediaFormats[0] will be set as stated for the share. Is optional. |
Returns
Type | Description |
---|---|
MediaShare | The found MediaShare or null if no matching share is found. |
Remarks
If you specify MediaFormats in the MediaItemQuery, these will be found in the MediaItem from MediaConversions[1] and forwards. MediaConversions[0] will contain the conversion for the format specified in the MediaShare.
GetShares(IList<String>)
Gets a list of media shares with the supplied ids
Declaration
IEnumerable<MediaShare> GetShares(IList<string> id)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IList<System.String> | id |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<MediaShare> |
Save(MediaShare)
Saves the supplied mediaShare
Declaration
MediaShare Save(MediaShare mediaShare)
Parameters
Type | Name | Description |
---|---|---|
MediaShare | mediaShare |
Returns
Type | Description |
---|---|
MediaShare |