• Facebook
  • Twitter
  • Youtube
  • LinedIn
  • RSS
  • Docs
  • Comparisons
  • Blogs
  • Download
  • Contact Us
Download
Show / Hide Table of Contents

Interface IMutableEntry

Assembly: Alachisoft.NCache.Runtime.dll
Syntax
public interface IMutableEntry

Properties

Key

Gets the key of cache entry on which entry processor has to be executed.

Declaration
string Key { get; }
Property Value
Type Description
System.String

Returns key of the associated cahe entry.

Examples

Example looks for string Product in Key property of Mutable Entry

if (entry.Exists())
{
    if (entry.Key.Contains("Product"))
    {
        return "It is a product.";
    }
    else
    {
        return "Unknown data";
    }
}

Value

Sets/Gets data for relevant key.

Declaration
object Value { get; set; }
Property Value
Type Description
System.Object

The data of the relevant key.

Examples

Example get the value of the entry and returns its type

if (entry.Exists())
{
    return entry.Value.GetType().FullName;
}

Methods

Exists()

Checks, if the required key for Entry Processor exists in cache or not.

Declaration
bool Exists()
Returns
Type Description
System.Boolean

Returns true, if key exists or vice versa.

Examples

Example returns string based on existence of entry to be processed in cache

if (entry.Exists())
{
    return "Key exists.";
}
else
{
    return "Key does not exist.";
}

Remove()

Removes the key from cache after executing the entry processor.

Declaration
void Remove()
Examples

Example removes entry from cache after processing

if (entry.Key.Contains("Product"))
{
   entry.Remove();
   return "Removed.";
}

UnWrap(Type)

Convert data type of the value.

Declaration
object UnWrap(Type type)
Parameters
Type Name Description
System.Type type

New data Type.

Returns
Type Description
System.Object

Value with updated data type.

Examples

Example unwraps the entry into string and returns

if (entry.Exists())
{
    return entry.UnWrap(typeof(string));
}

Contact Us

PHONE

+1 (214) 764-6933   (US)

+44 20 7993 8327   (UK)

 
EMAIL

sales@alachisoft.com

support@alachisoft.com

NCache
  • NCache Enterprise
  • NCache Community
  • Edition Comparison
  • NCache Architecture
  • Benchmarks
Download
Pricing
Try Playground

Deployments
  • Cloud (SaaS & Software)
  • On-Premises
  • Kubernetes
  • Docker
Technical Use Cases
  • ASP.NET Sessions
  • ASP.NET Core Sessions
  • Pub/Sub Messaging
  • Real-Time ASP.NET SignalR
  • Internet of Things (IoT)
  • NoSQL Database
  • Stream Processing
  • Microservices
Resources
  • Magazine Articles
  • Third-Party Articles
  • Articles
  • Videos
  • Whitepapers
  • Shows
  • Talks
  • Blogs
  • Docs
Customer Case Studies
  • Testimonials
  • Customers
Support
  • Schedule a Demo
  • Forum (Google Groups)
  • Tips
Company
  • Leadership
  • Partners
  • News
  • Events
  • Careers
Contact Us

  • EnglishChinese (Simplified)FrenchGermanItalianJapaneseKoreanPortugueseSpanish

  • Contact Us
  •  
  • Sitemap
  •  
  • Terms of Use
  •  
  • Privacy Policy
© Copyright Alachisoft 2002 - . All rights reserved. NCache is a registered trademark of Diyatech Corp.
Back to top