/// <summary>
 ///     Persist the task metadata cache to disk.
 /// </summary>
 public void PersistTaskMetadataCache()
 {
     if (!TaskMetadataCacheFile.Directory.Exists)
     {
         ExtensionDataDirectory.Create();
     }
 }
        /// <summary>
        ///     Persist the task metadata cache to disk.
        /// </summary>
        public void PersistTaskMetadataCache()
        {
            if (!TaskMetadataCache.IsDirty)
            {
                return; // Nothing new to persist.
            }
            if (!TaskMetadataCacheFile.Directory.Exists)
            {
                ExtensionDataDirectory.Create();
            }

            TaskMetadataCache.Save(TaskMetadataCacheFile.FullName);
        }