Ejemplo n.º 1
0
        //Constructor to instantiate based on how dictionary
        public LogPull(Dictionary <string, string> arguments)
        {
            Auth             = new ISOLogPullLibrary.Authentication();
            StartTime        = null;
            EndTime          = null;
            SubscriptionType = "Exchange";

            // check for key values in dictionary and set variables
            // Checks for proper format should be done by the application
            if (arguments.ContainsKey("starttime"))
            {
                StartTime = arguments["starttime"];
                Debug.WriteLine("Start: {0}", StartTime);
            }
            if (arguments.ContainsKey("endtime"))
            {
                EndTime = arguments["endtime"];
                Debug.WriteLine("End: {0}", EndTime);
            }

            if (arguments.ContainsKey("subtype"))
            {
                SubscriptionType = arguments["subtype"];
            }
            SafeWriter = new Writer(SubscriptionType);

            if (arguments.ContainsKey("output"))
            {
                // call Writer class method to set file path
                SafeWriter.SetFilePath(arguments["output"]);
            }
        }
Ejemplo n.º 2
0
 //Constructor No args set everything to null
 public LogPull()
 {
     Auth             = new ISOLogPullLibrary.Authentication();
     StartTime        = null;
     EndTime          = null;
     SubscriptionType = "Exchange";
     SafeWriter       = new Writer(SubscriptionType);
 }