2019-06-07 15:26:03 +02:00
|
|
|
|
/*
|
2024-03-05 18:37:42 +01:00
|
|
|
|
* Copyright (c) 2024 ETH Zürich, IT Services
|
2019-06-07 15:26:03 +02:00
|
|
|
|
*
|
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
|
*/
|
|
|
|
|
|
2019-06-18 10:18:56 +02:00
|
|
|
|
using System.Threading;
|
2019-08-30 09:55:26 +02:00
|
|
|
|
using SafeExamBrowser.Configuration.Contracts;
|
|
|
|
|
using SafeExamBrowser.Lockdown.Contracts;
|
2019-06-11 09:53:33 +02:00
|
|
|
|
|
2019-06-07 15:26:03 +02:00
|
|
|
|
namespace SafeExamBrowser.Service
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Holds all configuration and runtime data required for the session handling.
|
|
|
|
|
/// </summary>
|
|
|
|
|
internal class SessionContext
|
|
|
|
|
{
|
2019-06-26 10:13:11 +02:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// The mechanism trying to restore all changes after an application or system failure.
|
|
|
|
|
/// </summary>
|
|
|
|
|
internal IAutoRestoreMechanism AutoRestoreMechanism { get; set; }
|
|
|
|
|
|
2019-06-07 15:26:03 +02:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// The configuration of the currently active session.
|
|
|
|
|
/// </summary>
|
2019-06-18 10:18:56 +02:00
|
|
|
|
internal ServiceConfiguration Configuration { get; set; }
|
2019-06-07 15:26:03 +02:00
|
|
|
|
|
2019-06-27 08:32:37 +02:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Indicates whether a session is currently running.
|
|
|
|
|
/// </summary>
|
|
|
|
|
internal bool IsRunning { get; set; }
|
|
|
|
|
|
2019-06-07 15:26:03 +02:00
|
|
|
|
/// <summary>
|
2019-06-18 10:18:56 +02:00
|
|
|
|
/// The global inter-process event used for status synchronization with the runtime component.
|
2019-06-07 15:26:03 +02:00
|
|
|
|
/// </summary>
|
2019-06-18 15:51:35 +02:00
|
|
|
|
internal EventWaitHandle ServiceEvent { get; set; }
|
2019-06-07 15:26:03 +02:00
|
|
|
|
}
|
|
|
|
|
}
|