本文整理匯總了C#中ShareFile.Api.Client.Requests.ShareFile.Api.Client.Requests.Query.ActionIds方法的典型用法代碼示例。如果您正苦於以下問題:C# ShareFile.Api.Client.Requests.Query.ActionIds方法的具體用法?C# ShareFile.Api.Client.Requests.Query.ActionIds怎麽用?C# ShareFile.Api.Client.Requests.Query.ActionIds使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類ShareFile.Api.Client.Requests.ShareFile.Api.Client.Requests.Query
的用法示例。
在下文中一共展示了ShareFile.Api.Client.Requests.Query.ActionIds方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: CreateMetadata
/// <summary>
/// Create or update StorageCenter Metadata
/// </summary>
/// <example>
/// [
/// {"Name":"metadataName1", "Value":"metadataValue1", "IsPublic":"true"},
/// {"Name":"metadataName2", "Value":"metadataValue2", "IsPublic":"false"},
/// ...
/// ]
/// </example>
/// <remarks>
/// Creates or updates Metadata entries associated with the specified storage center
/// </remarks>
/// <param name="zUrl"></param>
/// <param name="scid"></param>
/// <param name="metadata"></param>
/// <returns>
/// the storage center metadata feed
/// </returns>
public IQuery<ODataFeed<Metadata>> CreateMetadata(Uri zUrl, string scid, IEnumerable<Metadata> metadata)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<ODataFeed<Metadata>>(Client);
sfApiQuery.Action("StorageCenters");
sfApiQuery.Uri(zUrl);
sfApiQuery.ActionIds(scid);
sfApiQuery.SubAction("Metadata");
sfApiQuery.Body = metadata;
sfApiQuery.HttpMethod = "POST";
return sfApiQuery;
}
示例2: UpdateLink
/// <summary>
/// Update Link
/// </summary>
/// <example>
/// {
/// "Name":"Name",
/// "Uri":"https://server/path",
/// "Description":"Description",
/// "Parent": { "Id": "parentid" },
/// }
/// </example>
/// <remarks>
/// Updates a Link object
/// </remarks>
/// <param name="id"></param>
/// <param name="link"></param>
/// <param name="notify"></param>
/// <returns>
/// A modified Link object
/// </returns>
public IQuery<Link> UpdateLink(string id, Link link, bool notify = false)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Link>(Client);
sfApiQuery.From("Items");
sfApiQuery.Action("Link");
sfApiQuery.ActionIds(id);
sfApiQuery.QueryString("notify", notify);
sfApiQuery.Body = link;
sfApiQuery.HttpMethod = "PATCH";
return sfApiQuery;
}
示例3: GetTenants
public IQuery<Account> GetTenants(string id)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Account>(Client);
sfApiQuery.From("Accounts");
sfApiQuery.Action("Tenants");
sfApiQuery.ActionIds(id);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例4: UpdateByZone
/// <summary>
/// Update StorageCenter
/// </summary>
/// <example>
/// {
/// "ExternalAddress":"https://server/",
/// "Version":"4.12.20",
/// "HostName":"hostname"
/// }
/// </example>
/// <remarks>
/// Updates an existing Storage Center
/// </remarks>
/// <param name="zUrl"></param>
/// <param name="scid"></param>
/// <param name="storageCenter"></param>
/// <returns>
/// the modified storage center
/// </returns>
public IQuery<StorageCenter> UpdateByZone(Uri zUrl, string scid, StorageCenter storageCenter)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<StorageCenter>(Client);
sfApiQuery.Action("StorageCenters");
sfApiQuery.Uri(zUrl);
sfApiQuery.ActionIds(scid);
sfApiQuery.Body = storageCenter;
sfApiQuery.HttpMethod = "PATCH";
return sfApiQuery;
}
示例5: GetItems
/// <summary>
/// Get Items of a Send Share
/// </summary>
/// <remarks>
/// Retrieve a single Item in the Send Share
/// </remarks>
/// <param name="shareUrl"></param>
/// <param name="itemid"></param>
/// <returns>
/// An item in the Share
/// </returns>
public IQuery<Item> GetItems(Uri shareUrl, string itemid)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Item>(Client);
sfApiQuery.Action("Items");
sfApiQuery.Uri(shareUrl);
sfApiQuery.ActionIds(itemid);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例6: ProtocolLinks
/// <summary>
/// Get List of Protocol Links of a Share item
/// </summary>
/// <param name="shareUrl"></param>
/// <param name="itemid"></param>
/// <param name="platform"></param>
/// <returns>
/// A list of protocol links depending on the input parameter 'platform', 404 (Not Found) if not supported by the item
/// </returns>
public IQuery<ODataFeed<ItemProtocolLink>> ProtocolLinks(Uri shareUrl, string itemid, PreviewPlatform platform)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<ODataFeed<ItemProtocolLink>>(Client);
sfApiQuery.Action("Items");
sfApiQuery.Uri(shareUrl);
sfApiQuery.ActionIds(itemid);
sfApiQuery.SubAction("ProtocolLinks", platform);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例7: BulkDownload
/// <summary>
/// Download Multiple Items from a Share for a Recipient
/// </summary>
/// <example>
/// ["id1","id2",...]
/// </example>
/// <remarks>
/// Download Multiple Items from a Share for a Recipient. The download will contain a ZIP archive containing all
/// files and folders in the share, named Files.zip.To download Shares that require user informaion ( Email, First Name, Last Name and Company), make sure
/// to create an Recipient (alias) and pass in the alaisId.To download Shares that require authentication, make sure this request is authenticated.
/// Anyone can download files from anonymous shares.
/// </remarks>
/// <param name="shareUrl"></param>
/// <param name="aliasid"></param>
/// <param name="ids"></param>
/// <param name="redirect"></param>
/// <returns>
/// Redirects the caller (302) to the download address for the share contents.
/// </returns>
public IQuery<Stream> BulkDownload(Uri shareUrl, string aliasid, IEnumerable<string> ids, bool redirect = true)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Stream>(Client);
sfApiQuery.Action("Recipients");
sfApiQuery.Uri(shareUrl);
sfApiQuery.ActionIds(aliasid);
sfApiQuery.SubAction("BulkDownload");
sfApiQuery.QueryString("redirect", redirect);
sfApiQuery.Body = ids;
sfApiQuery.HttpMethod = "POST";
return sfApiQuery;
}
示例8: GetByUser
/// <summary>
/// Get FavoriteFolder
/// </summary>
/// <remarks>
/// Retrieves a single Favorite Folder
/// </remarks>
/// <param name="userid"></param>
/// <param name="itemUrl"></param>
/// <returns>
/// A list of Favorite Folders specified by this user
/// </returns>
public IQuery<FavoriteFolder> GetByUser(Uri itemUrl, string userid)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<FavoriteFolder>(Client);
sfApiQuery.Action("FavoriteFolders");
sfApiQuery.Uri(itemUrl);
sfApiQuery.ActionIds(userid);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例9: GetInbox
/// <summary>
/// Get Inbox for Recipient
/// </summary>
/// <remarks>
/// Retrieve all outstanding Shares in the inbox.User identifier
/// </remarks>
/// <returns>
/// List of Shares created by the authenticated user
/// </returns>
public IQuery<ODataFeed<Share>> GetInbox(string id = null, ShareType type = ShareType.Both, bool archived = false)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<ODataFeed<Share>>(Client);
sfApiQuery.From("Shares");
sfApiQuery.Action("Inbox");
sfApiQuery.ActionIds(id);
sfApiQuery.QueryString("type", type);
sfApiQuery.QueryString("archived", archived);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例10: Message
/// <summary>
/// Get Sent Message Content by Share
/// </summary>
/// <remarks>
/// Returns sent message content.
/// </remarks>
/// <param name="shareUrl"></param>
/// <param name="aliasId"></param>
/// <returns>
/// Sent Message Content
/// </returns>
public IQuery<Stream> Message(Uri shareUrl, string aliasId)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Stream>(Client);
sfApiQuery.Action("Recipients");
sfApiQuery.Uri(shareUrl);
sfApiQuery.ActionIds(aliasId);
sfApiQuery.SubAction("Message");
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例11: UpdateByItem
/// <summary>
/// Update Metadata
/// </summary>
/// <example>
/// {
/// "Value":"metadata value"
/// }
/// </example>
/// <remarks>
/// Updates a single Metadata entry that has a specified Name for a given Item. Fails if an entry with the given name doesn't exist for this Item.
/// </remarks>
/// <param name="url"></param>
/// <param name="metadataId"></param>
/// <returns>
/// The updated Metadata object
/// </returns>
public IQuery<Metadata> UpdateByItem(Uri url, string metadataId, Metadata metadata)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Metadata>(Client);
sfApiQuery.Action("Metadata");
sfApiQuery.Uri(url);
sfApiQuery.ActionIds(metadataId);
sfApiQuery.Body = metadata;
sfApiQuery.HttpMethod = "PATCH";
return sfApiQuery;
}
示例12: UpdateSymbolicLink
/// <summary>
/// Update SymbolicLink
/// </summary>
/// <example>
/// {
/// "Name":"Name",
/// "Description":"Description",
/// "Link": "https://server/path"
/// }
/// </example>
/// <remarks>
/// Updates a Symbolic Link object
/// </remarks>
/// <param name="id"></param>
/// <param name="symlink"></param>
/// <returns>
/// The modified SymbolicLink object
/// </returns>
public IQuery<SymbolicLink> UpdateSymbolicLink(string id, SymbolicLink symlink)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<SymbolicLink>(Client);
sfApiQuery.From("Items");
sfApiQuery.Action("SymbolicLink");
sfApiQuery.ActionIds(id);
sfApiQuery.Body = symlink;
sfApiQuery.HttpMethod = "PATCH";
return sfApiQuery;
}
示例13: UpdateNote
/// <summary>
/// Update Note
/// </summary>
/// <example>
/// {
/// "Name":"Name",
/// "Description":"Description",
/// "Parent": { "Id": "parentid" },
/// }
/// </example>
/// <remarks>
/// Updates a Note object
/// </remarks>
/// <param name="id"></param>
/// <param name="note"></param>
/// <param name="notify"></param>
/// <returns>
/// The modified Note object
/// </returns>
public IQuery<Note> UpdateNote(string id, Note note, bool notify = false)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<Note>(Client);
sfApiQuery.From("Items");
sfApiQuery.Action("Note");
sfApiQuery.ActionIds(id);
sfApiQuery.QueryString("notify", notify);
sfApiQuery.Body = note;
sfApiQuery.HttpMethod = "PATCH";
return sfApiQuery;
}
示例14: GetByFolder
/// <summary>
/// Get List of AsyncOperations by Folder
/// </summary>
/// <remarks>
/// Retrieves all AsyncOperations associated with the calling user and the Item ID
/// </remarks>
/// <param name="id"></param>
/// <returns>
/// A Feed of AsyncOperation objects, containing all pending operations in the specific folder,
/// for the authenticated SDK user
/// </returns>
public IQuery<ODataFeed<AsyncOperation>> GetByFolder(string id)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<ODataFeed<AsyncOperation>>(Client);
sfApiQuery.From("AsyncOperations");
sfApiQuery.Action("GetByFolder");
sfApiQuery.ActionIds(id);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}
示例15: GetZones
/// <summary>
/// Get the Connector Group by Service ID
/// </summary>
/// <remarks>
/// Retrieves a Connector Group
/// </remarks>
/// <param name="id"></param>
/// <returns>
/// A single ConnectorGroup object matching the query
/// </returns>
public IQuery<ConnectorGroupZone> GetZones(Uri url, string id)
{
var sfApiQuery = new ShareFile.Api.Client.Requests.Query<ConnectorGroupZone>(Client);
sfApiQuery.Action("Zones");
sfApiQuery.Uri(url);
sfApiQuery.ActionIds(id);
sfApiQuery.HttpMethod = "GET";
return sfApiQuery;
}