Ejemplo n.º 1
0
        public XEMailClient(string ServiceURI)
        {
            // Internal Dataset
            xEMailsDS = new DataSet("XEMailDS");

            // Web Service Initialization
            prxy     = new XEMailWebserviceProxy();
            prxy.Url = ServiceURI;

            prxy.GetAllPop3EMailsHeadersDSCompleted += new GetAllPop3EMailsHeadersDSCompletedEventHandler(RetrieveAllEMailsHeadersEnded);

            // Config Object
            this.configurationObject = new XEMailClientConfiguration();
            this.configurationObject.AutoCheckEnabled = false;
            this.configurationObject.WebserviceUrl    = ServiceURI;
            UpdateClientConfiguration(false);

            this.configurationObject.ConfigurationChanged += new ConfigChangedEventHandler(configurationObject_ConfigurationChanged);

            // Status Object
            status = new XEMailProcessStatusManager();
            status.ProcessFinished += new XEMailProcessFinishedEventHandler(NotifyFinish);

            // The datatables
            this.emailsTable = InitializeLocalDataTable();
            this.xEMailsDS.Tables.Add(emailsTable);
        }
        public XEMailClientConfiguration Clone()
        {
            XEMailClientConfiguration result = new XEMailClientConfiguration();

            result.checkInterval         = this.checkInterval;
            result.autoCheckEnabled      = this.autoCheckEnabled;
            result.accounts              = this.accounts;
            result.WebserviceUrl         = this.WebserviceUrl;
            result.networkProxy.Enabled  = this.networkProxy.Enabled;
            result.NetworkProxy.Url      = this.NetworkProxy.Url;
            result.networkProxy.Port     = this.networkProxy.Port;
            result.NetworkProxy.User     = this.NetworkProxy.User;
            result.NetworkProxy.Password = this.NetworkProxy.Password;
            result.networkProxy.Domain   = this.networkProxy.Domain;

            return(result);
        }