Поділитися через


DataCache.GetObjectsByAllTags Method

Gets an enumerable list of all cached objects in the specified region that have all the same tags in common.

Namespace: Microsoft.ApplicationServer.Caching
Assembly: Microsoft.ApplicationServer.Caching.Client (in microsoft.applicationserver.caching.client.dll)

Usage

'Usage
Dim instance As DataCache
Dim tags As IEnumerable(Of DataCacheTag)
Dim region As String
Dim returnValue As IEnumerable(Of KeyValuePair(Of String, Object))

returnValue = instance.GetObjectsByAllTags(tags, region)

Syntax

'Declaration
Public Function GetObjectsByAllTags ( _
    tags As IEnumerable(Of DataCacheTag), _
    region As String _
) As IEnumerable(Of KeyValuePair(Of String, Object))
public IEnumerable<KeyValuePair<string,Object>> GetObjectsByAllTags (
    IEnumerable<DataCacheTag> tags,
    string region
)
public:
IEnumerable<KeyValuePair<String^, Object^>>^ GetObjectsByAllTags (
    IEnumerable<DataCacheTag^>^ tags, 
    String^ region
)
public IEnumerable<KeyValuePair<String,Object>> GetObjectsByAllTags (
    IEnumerable<DataCacheTag> tags, 
    String region
)
public function GetObjectsByAllTags (
    tags : IEnumerable<DataCacheTag>, 
    region : String
) : IEnumerable<KeyValuePair<String,Object>>

Parameters

  • tags
    A list of tags for which to search.
  • region
    The name of the region to search. Tags are not supported outside regions. Therefore, a region name is required.

Return Value

An enumerable list of all cached objects in the specified region that have all the same tags in common.

Remarks

Cached objects returned in the list have all the tags listed in the tags array parameter. If you want the list to also include those objects that only have some of the tags listed in the tags array parameter, use the GetObjectsByAnyTag method.

Tags are supported only for objects stored in regions.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Development Platforms

Visual Studio 2010 and later, .NET Framework 4

Target Platforms

Windows 7; Windows Server 2008 R2; Windows Server 2008 Service Pack 2; Windows Vista Service Pack 2

See Also

Reference

DataCache Class
DataCache Members
Microsoft.ApplicationServer.Caching Namespace

  ff425062(v=azure.10).md 2011-08-26