/// <summary>
        /// Initializes a new instance of <see cref="CreateSpreadsheetDialog"/>.
        /// </summary>
        /// <param name="webProvider">The <see cref="ExcelAllGrade.controller.WebAdapterProvider"/> necessary for the connection with the server.</param>
        /// <param name="vLoader">The <see cref="ExcelAllGrade.controller.VariableLoader"/> to load the variables.</param>
        /// <param name="eVariablesLoaded">The <see cref="System.Threading.AutoResetEvent"/> to indicate when <see cref="ExcelAllGrade.controller.VariableLoader"/> is done loading.</param>
        /// <param name="teacher">The <c>teacher-token</c>.</param>
        public ManageLessonsDialog(string teacher, WebAdapterProvider webProvider, VariableLoader vLoader, AutoResetEvent eVariablesLoaded)
        {
            InitializeComponent();

            this.teacher = teacher;
            this.webProvider = webProvider;
            this.vLoader = vLoader;
            this.eVariablesLoaded = eVariablesLoaded;

            loadingThread = new Thread(new ThreadStart(initializeVariables));
        }
Beispiel #2
0
        public WebAdapterService(StatelessServiceContext context)
            : base(context)
        {
            this.baseLogString = $"{this.GetType()} [{this.GetHashCode()}] =>{Environment.NewLine}";
            Logger.LogDebug($"{baseLogString} Ctor => Logger initialized");

            try
            {
                this.webAdapterProvider       = new WebAdapterProvider();
                this.notifySubscriberProvider = new NotifySubscriberProvider(MicroserviceNames.WebAdapterService);

                this.registerSubscriberClient = RegisterSubscriberClient.CreateClient();
            }
            catch (Exception e)
            {
                string errorMessage = $"{baseLogString} Ctor => exception {e.Message}";
                Logger.LogError(errorMessage, e);
                ServiceEventSource.Current.ServiceMessage(this.Context, $"[WebAdapterService | Error] {errorMessage}");
            }
        }
 /// <summary>
 /// Initializes a new instance of <see cref="LogtableController"/>.
 /// </summary>
 /// <param name="webProvider">The <see cref="ExcelAllGrade.controller.WebAdapterProvider"/> necessary for the connection with the server.</param>
 public LogtableController(WebAdapterProvider webProvider)
 {
     this.webProvider = webProvider;
 }
 /// <summary>
 /// Initializes a new instance of <see cref="GradelogController"/>.
 /// </summary>
 /// <param name="webProvider">The <see cref="ExcelAllGrade.controller.WebAdapterProvider"/> necessary for the connection with the server.</param>
 public GradelogController(WebAdapterProvider webProvider)
 {
     this.webProvider = webProvider;
 }