你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Cache interface

表示缓存的接口。

方法

createOrUpdate(string, string, string, CacheContract, CacheCreateOrUpdateOptionalParams)

创建或更新要用于 Api 管理实例的外部缓存。

delete(string, string, string, string, CacheDeleteOptionalParams)

删除特定的缓存。

get(string, string, string, CacheGetOptionalParams)

获取由其标识符指定的缓存的详细信息。

getEntityTag(string, string, string, CacheGetEntityTagOptionalParams)

获取由其标识符指定的缓存的实体状态 (Etag) 版本。

listByService(string, string, CacheListByServiceOptionalParams)

列出指定服务实例中所有外部缓存的集合。

update(string, string, string, string, CacheUpdateParameters, CacheUpdateOptionalParams)

更新由其标识符指定的缓存的详细信息。

方法详细信息

createOrUpdate(string, string, string, CacheContract, CacheCreateOrUpdateOptionalParams)

创建或更新要用于 Api 管理实例的外部缓存。

function createOrUpdate(resourceGroupName: string, serviceName: string, cacheId: string, parameters: CacheContract, options?: CacheCreateOrUpdateOptionalParams): Promise<CacheCreateOrUpdateResponse>

参数

resourceGroupName

string

资源组的名称。 名称不区分大小写。

serviceName

string

API 管理服务的名称。

cacheId

string

缓存实体的标识符。 缓存标识符(应为“默认”或有效的 Azure 区域标识符)。

parameters
CacheContract

创建或更新参数。

options
CacheCreateOrUpdateOptionalParams

选项参数。

返回

delete(string, string, string, string, CacheDeleteOptionalParams)

删除特定的缓存。

function delete(resourceGroupName: string, serviceName: string, cacheId: string, ifMatch: string, options?: CacheDeleteOptionalParams): Promise<void>

参数

resourceGroupName

string

资源组的名称。 名称不区分大小写。

serviceName

string

API 管理服务的名称。

cacheId

string

缓存实体的标识符。 缓存标识符(应为“默认”或有效的 Azure 区域标识符)。

ifMatch

string

实体的 ETag。 ETag 应与 GET 请求的标头响应中的当前实体状态匹配,或者它应为 * 进行无条件更新。

options
CacheDeleteOptionalParams

选项参数。

返回

Promise<void>

get(string, string, string, CacheGetOptionalParams)

获取由其标识符指定的缓存的详细信息。

function get(resourceGroupName: string, serviceName: string, cacheId: string, options?: CacheGetOptionalParams): Promise<CacheGetResponse>

参数

resourceGroupName

string

资源组的名称。 名称不区分大小写。

serviceName

string

API 管理服务的名称。

cacheId

string

缓存实体的标识符。 缓存标识符(应为“默认”或有效的 Azure 区域标识符)。

options
CacheGetOptionalParams

选项参数。

返回

Promise<CacheGetResponse>

getEntityTag(string, string, string, CacheGetEntityTagOptionalParams)

获取由其标识符指定的缓存的实体状态 (Etag) 版本。

function getEntityTag(resourceGroupName: string, serviceName: string, cacheId: string, options?: CacheGetEntityTagOptionalParams): Promise<CacheGetEntityTagHeaders>

参数

resourceGroupName

string

资源组的名称。 名称不区分大小写。

serviceName

string

API 管理服务的名称。

cacheId

string

缓存实体的标识符。 缓存标识符(应为“默认”或有效的 Azure 区域标识符)。

options
CacheGetEntityTagOptionalParams

选项参数。

返回

listByService(string, string, CacheListByServiceOptionalParams)

列出指定服务实例中所有外部缓存的集合。

function listByService(resourceGroupName: string, serviceName: string, options?: CacheListByServiceOptionalParams): PagedAsyncIterableIterator<CacheContract, CacheContract[], PageSettings>

参数

resourceGroupName

string

资源组的名称。 名称不区分大小写。

serviceName

string

API 管理服务的名称。

options
CacheListByServiceOptionalParams

选项参数。

返回

update(string, string, string, string, CacheUpdateParameters, CacheUpdateOptionalParams)

更新由其标识符指定的缓存的详细信息。

function update(resourceGroupName: string, serviceName: string, cacheId: string, ifMatch: string, parameters: CacheUpdateParameters, options?: CacheUpdateOptionalParams): Promise<CacheUpdateResponse>

参数

resourceGroupName

string

资源组的名称。 名称不区分大小写。

serviceName

string

API 管理服务的名称。

cacheId

string

缓存实体的标识符。 缓存标识符(应为“默认”或有效的 Azure 区域标识符)。

ifMatch

string

实体的 ETag。 ETag 应与 GET 请求的标头响应中的当前实体状态匹配,或者它应为 * 进行无条件更新。

parameters
CacheUpdateParameters

更新参数。

options
CacheUpdateOptionalParams

选项参数。

返回