-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathImageSize.cs
More file actions
executable file
·43 lines (39 loc) · 1.46 KB
/
ImageSize.cs
File metadata and controls
executable file
·43 lines (39 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
namespace ImageVerifier.MVAProxy
{
using System;
using System.Collections;
using System.Collections.Generic;
/// <summary>
/// Holds information about an image size.
/// Partial. Other code is auto-generated from the WebService wsdl.
/// </summary>
public partial class ImageSize : IProxyKey<Int32>
{
private static ProxyCache<Int32, ImageSize> cache = new ProxyCache<Int32, ImageSize>(
new ProxyCache<Int32, ImageSize>.DataLoaderDelegate(CatalogServices.Catalog.GetImageSize),
Settings.GetCacheExpirationPeriod());
/// <summary>
/// Retirieves the list of all ImageSizes known to the system
/// </summary>
public static List<ImageSize> Get()
{
return cache.Get();
}
/// <summary>
/// Retrieves the ImageSize information for an image size
/// <summary>
/// <param name="imageSizeId">The id of the image size to retrieve</param>
/// <returns>The ImageSize object matching the id if one exists, otherwise null</returns>
public static ImageSize Get(Int32 imageSizeId)
{
return cache.Get(imageSizeId);
}
/// <summary>
/// Refreshes the ClientSide Cache
/// </summary>
public static void RefreshCache()
{
cache.Refresh();
}
}
}