示例#1
0
 SampleDataset(string name, SampleDownload.Format format)
 {
     Name   = name;
     Format = format;
     Dpi    = LookupDpi(name);
     Layout = new SampleLayout(SampleDownload.Unpack(name, format));
 }
示例#2
0
 public static List <SampleDataset> AllInFormat(SampleDownload.Format format)
 {
     return(SampleDownload.Available.Select(n => Get(n, format)).ToList());
 }
示例#3
0
 public static SampleDataset Get(string name, SampleDownload.Format format)
 {
     return(Cache.GetOrAdd(Tuple.Create(name, format), t => new SampleDataset(t.Item1, t.Item2)));
 }