Ejemplo n.º 1
0
        /// <summary>
        /// Saves widget settings into datastore
        /// </summary>
        /// <param name="settings">Settings object (key/values)</param>
        /// <param name="widgetId">Widget Id</param>
        public static void SaveSettings(StringDictionary settings, string widgetId)
        {
            var cacheId = string.Format("be_widget_{0}", widgetId);

            var ws = new WidgetSettings(widgetId);
            ws.SaveSettings(settings);

            Blog.CurrentInstance.Cache[cacheId] = settings;
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Saves settings to data store
        /// </summary>
        /// <param name="settings">
        /// The settings
        /// </param>
        protected virtual void SaveSettings(StringDictionary settings)
        {
            var cacheId = string.Format("be_widget_{0}", WidgetId);

            var ws = new WidgetSettings(WidgetId.ToString());
            ws.SaveSettings(settings);

            Blog.CurrentInstance.Cache[cacheId] = settings;
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Saves the XML document.
 /// </summary>
 /// <param name="doc">The doc.</param>
 /// <param name="zone">The zone to save the Xml Document for.</param>
 private void SaveXmlDocument(XmlDocument doc, string zone)
 {
     WidgetSettings ws = new WidgetSettings(zone);
     ws.SettingsBehavior = new XMLDocumentBehavior();
     ws.SaveSettings(doc);
     Cache[zone] = doc;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Saves the XML document.
 /// </summary>
 /// <param name="doc">The doc.</param>
 private void SaveXmlDocument(XmlDocument doc)
 {
     WidgetSettings ws = new WidgetSettings(_zoneId);
     ws.SettingsBehavior = new XMLDocumentBehavior();
     ws.SaveSettings(doc);
     Cache[_zoneId] = doc;
 }
 /// <summary>
 /// Saves the XML document.
 /// </summary>
 /// <param name="doc">
 /// The document.
 /// </param>
 /// <param name="zone">
 /// The zone to save the Xml Document for.
 /// </param>
 private void SaveXmlDocument(XmlDocument doc, string zone)
 {
     var ws = new WidgetSettings(zone) { SettingsBehavior = new XmlDocumentBehavior() };
     ws.SaveSettings(doc);
     this.Cache[zone] = doc;
 }
Ejemplo n.º 6
0
    /// <summary>
    /// Saves settings to data store
    /// </summary>
    /// <param name="settings">Settings</param>
    protected virtual void SaveSettings(StringDictionary settings)
    {
        string cacheId = "be_widget_" + WidgetID;

        WidgetSettings ws = new WidgetSettings(WidgetID.ToString());
        ws.SaveSettings(settings);

        Cache[cacheId] = settings;
    }
Ejemplo n.º 7
0
        /// <summary>
        /// Saves settings to data store
        /// </summary>
        /// <param name="settings">
        /// The settings
        /// </param>
        protected virtual void SaveSettings(StringDictionary settings)
        {
            var cacheId = string.Format("be_widget_{0}", this.WidgetId);

            var ws = new WidgetSettings(this.WidgetId.ToString());
            ws.SaveSettings(settings);

            this.Cache[cacheId] = settings;
        }