Exemplo n.º 1
0
            public RuntimeVariables()
            {
                string filename = "settings.xml";

                persistence = new XMLPersistenceDictionary(logger, filename, false);
                if (!System.IO.File.Exists(filename))
                {
                    persistence.save();
                }
            }
Exemplo n.º 2
0
            public string savenow(BotFunctionData BotInput)
            {
                StringBuilder responsebuilder = new StringBuilder();

                System.Diagnostics.Stopwatch swatch = new System.Diagnostics.Stopwatch();
                swatch.Start();
                lock (persistence)
                {
                    persistence.save(persistence.filename);
                }
                swatch.Stop();
                responsebuilder.AppendFormat("Saved to {0} in {1}ms!", persistence.filename, swatch.ElapsedMilliseconds);
                return(responsebuilder.ToString());
            }
Exemplo n.º 3
0
            public RuntimeVariables()
            {
                string filename = "settings.xml";

                persistence = new XMLPersistenceDictionary(logger, filename, false);
                if (!System.IO.File.Exists(filename))
                    persistence.save();
            }