Thursday

caching in .net system.runtime.caching example

 
using System.Runtime.Caching;
public class UseCacheSample {
private static void UseCacheSampleMethod()
{

Demo demo;
ObjectCache cache = MemoryCache.Default;
if (cache.Contains("demo"))
{
demo = (Demo)cache.Get("demo");
}
else
{
demo = new Demo();
demo.SetTimes();
cache.Add("demo", demo, new CacheItemPolicy());
}

}
}

No comments:

imagemagic add text to image

rem different types of text annotations on existing images rem cyan yellow orange gold rem -gravity SouthWest rem draw text and anno...