Tripod.Sources.SqliteCache.SqliteCachedPhotoSource.Start C# (CSharp) Method

Start() public method

public Start ( IPhotoSourceCache cache ) : void
cache IPhotoSourceCache
return void
        public void Start (IPhotoSourceCache cache)
        {
            Core.Scheduler.Add (new StartPhotoSourceJob (this, cache));
        }

Usage Example

示例#1
0
 public void RegisterPhotoSource (ICacheablePhotoSource source)
 {
     if (source.CacheId != 0) {
         throw new Exception ("Can't register an already registered source!");
     }
     
     var cache = new SqliteCachedPhotoSource (source);
     cache.AvailabilityChanged += OnCachedSourceAvailabilityChanged;
     source_provider.Save (cache);
     
     source.CacheId = cache.CacheId;
     source.Persist ();
     cache.Start (this);
 }