ReportingService2010.GetCacheOptions(String, ExpirationDefinition) Method

Definition

返回项的缓存配置以及说明项的缓存副本何时到期的设置。Returns the cache configuration for an item and the settings that describe when the cached copy of the item expires. 此方法适用于ReportDataset项类型。This method applies to the Report and Dataset item types.

public:
 bool GetCacheOptions(System::String ^ ItemPath, [Runtime::InteropServices::Out] ReportService2010::ExpirationDefinition ^ % Item);
[System.Web.Services.Protocols.SoapDocumentMethod("http://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/GetCacheOptions", ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped, RequestNamespace="http://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", ResponseNamespace="http://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", Use=System.Web.Services.Description.SoapBindingUse.Literal)]
[System.Web.Services.Protocols.SoapHeader("ServerInfoHeaderValue", Direction=System.Web.Services.Protocols.SoapHeaderDirection.Out)]
[System.Web.Services.Protocols.SoapHeader("TrustedUserHeaderValue")]
public bool GetCacheOptions (string ItemPath, out ReportService2010.ExpirationDefinition Item);
[<System.Web.Services.Protocols.SoapDocumentMethod("http://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/GetCacheOptions", ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped, RequestNamespace="http://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", ResponseNamespace="http://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", Use=System.Web.Services.Description.SoapBindingUse.Literal)>]
[<System.Web.Services.Protocols.SoapHeader("ServerInfoHeaderValue", Direction=System.Web.Services.Protocols.SoapHeaderDirection.Out)>]
[<System.Web.Services.Protocols.SoapHeader("TrustedUserHeaderValue")>]
member this.GetCacheOptions : string * ExpirationDefinition -> bool
Public Function GetCacheOptions (ItemPath As String, ByRef Item As ExpirationDefinition) As Boolean

Parameters

ItemPath
String

项的完全限定 URL,其中包括文件名(在 SharePoint 模式下,还有扩展名)。The fully qualified URL of the item including the file name and, in SharePoint mode, the extension.

Item
ExpirationDefinition

[out] 一个 ExpirationDefinition 对象,该对象定义确定缓存副本到期的时间(以分钟为单位)或计划。[out] An ExpirationDefinition object that defines either the time, in minutes, or the schedule upon which the cached copy expires.

Returns

Boolean

如果将已执行项的副本放入缓存,则为 true;否则为 falsetrue if a copy of an executed item is put in cache; otherwise, false.

Attributes

Remarks

下表显示了有关此操作的标头和权限信息。The table below shows header and permissions information on this operation.

SOAP 标头用法SOAP Header Usage (In) TrustedUserHeaderValue(In) TrustedUserHeaderValue

(Out) ServerInfoHeaderValue(Out) ServerInfoHeaderValue
纯模式所需的权限Native Mode Required Permissions ReadPolicy
SharePoint 模式所需的权限SharePoint Mode Required Permissions ViewListItems

使用此方法的返回值计算该项是否设置为缓存。Use the return value of this method to evaluate whether the item is set to be cached. 如果值为 false ,则该方法将返回 null (或 Nothing Visual Basic) 中 ItemIf the value is false, the method returns a null (or Nothing in Visual Basic) for Item.

仅当执行选项配置为按需运行时,才使用此方法。Use this method only if the execution option is configured to run on demand. 有关项的缓存设置的详细信息,请参阅 (SSRS) 缓存报表 For more information about the cache settings of an item, see Caching Reports (SSRS). 有关以编程方式设置项的缓存选项的信息,请参见 SetCacheOptions 方法。For information about programmatically setting the caching options of an item, see the SetCacheOptions method.

Applies to