├── .gitignore ├── ARESCore ├── Resources │ ├── Crosshair.bmp │ ├── PatchSpacingOutlineGray.png │ ├── IResourceManager.cs │ ├── EditorHighlighting.xshd │ └── ResourceManager.cs ├── UI │ ├── Views │ │ ├── SplashScreenBackground.png │ │ ├── AresSplashScreen.xaml.cs │ │ ├── Settings │ │ │ ├── UserPreferences.xaml.cs │ │ │ ├── ApplicationStyleView.xaml.cs │ │ │ ├── SettingsWindow.xaml.cs │ │ │ ├── FilesAndUsers.xaml.cs │ │ │ └── SettingsWindow.xaml │ │ ├── AppKiller.xaml.cs │ │ ├── IPAddressPortView.xaml.cs │ │ ├── AresNotifier.xaml.cs │ │ ├── AppKiller.xaml │ │ ├── LicenseWindow.xaml.cs │ │ ├── ProjectSelectionView.xaml.cs │ │ ├── CompletionWindowStyle.xaml │ │ ├── AresNotifier.xaml │ │ └── ConsoleWindow.xaml │ ├── Helpers │ │ ├── IClosable.cs │ │ ├── UIHelper.cs │ │ └── DialogCloser.cs │ ├── IAresConsole.cs │ ├── ILoadingStatus.cs │ ├── AresNotification.cs │ ├── ViewModels │ │ ├── AresSplashScreenViewModel.cs │ │ ├── Settings │ │ │ ├── UserPreferencesViewModel.cs │ │ │ └── FilesAndUsersViewModel.cs │ │ ├── AresNotifierViewModel.cs │ │ └── IPAddressPortViewModel.cs │ ├── Converters │ │ ├── NullToBoolConverter.cs │ │ ├── NullToVisibilityConverter.cs │ │ ├── StringCompareConverter.cs │ │ ├── NegateBooleanConverter.cs │ │ ├── NegateBooleanToVisibilityConverter.cs │ │ ├── EnumBoolConverter.cs │ │ ├── IconConverter.cs │ │ ├── DoubleAdditionConverter.cs │ │ ├── UsersEqualToNegateVisibilityConverter.cs │ │ └── NegateNumberConverter.cs │ ├── LoadingStatus.cs │ └── FlyoutsControlRegionAdapter.cs ├── DeviceSupport │ ├── Usb │ │ ├── IUsbDevice.cs │ │ ├── UsbDevice.cs │ │ ├── UsbDeviceView.xaml.cs │ │ └── USBDeviceInfo.cs │ ├── IAresDeviceState.cs │ ├── IAresDeviceViewModel.cs │ ├── AresDeviceState.cs │ ├── IAresDeviceCommand.cs │ ├── ICalibrationPeak.cs │ ├── Serial │ │ ├── Rs232Config.xaml.cs │ │ ├── SerialTerminal.xaml.cs │ │ └── IRs232Device.cs │ ├── ConstrainedValue.cs │ ├── IDeviceScriptData.cs │ └── IAresDevice.cs ├── Experiment │ ├── Results │ │ ├── ExecutionStatus.cs │ │ ├── ICommandExecutionSummary.cs │ │ ├── IExecutionSummary.cs │ │ ├── ICampaignExecutionSummary.cs │ │ ├── IStepExecutionSummary.cs │ │ ├── IExperimentExecutionSummary.cs │ │ └── impl │ │ │ ├── CommandExecutionSummary.cs │ │ │ ├── ExecutionSummary.cs │ │ │ ├── CampaignExecutionSummary.cs │ │ │ ├── StepExecutionExecutionSummary.cs │ │ │ └── ExperimentExecutionSummary.cs │ ├── Scripting │ │ ├── IAresScriptCommand.cs │ │ ├── IScriptExecutor.cs │ │ ├── Commands │ │ │ ├── StepEndCommand.cs │ │ │ ├── DelayCommand.cs │ │ │ └── WaitCommand.cs │ │ ├── AresScriptCommand.cs │ │ └── Impl │ │ │ └── ScriptStep.cs │ ├── ICampaignExecutor.cs │ ├── IExperimentBatch.cs │ ├── UI │ │ ├── Views │ │ │ ├── BatchResultsView.xaml.cs │ │ │ ├── BatchInputDataView.xaml.cs │ │ │ ├── ExperimentEditorWindow.xaml.cs │ │ │ ├── PlanResultsView.xaml │ │ │ └── CampaignExecutionView.xaml.cs │ │ └── ViewModels │ │ │ └── BatchResultsViewModel.cs │ ├── IPlannedExperimentInputs.cs │ ├── ICampaign.cs │ ├── impl │ │ ├── ARESExperimentBatch.cs │ │ ├── ExperimentBatchRunner_Base.cs │ │ ├── ExperimentParameter.cs │ │ └── PlannedExperimentInputs.cs │ ├── Experiment.cs │ ├── CampaignCanRunMask.cs │ └── IPlannedExperimentBatchInputs.cs ├── UserSession │ ├── StartupStateType.cs │ ├── IUserSession.cs │ ├── IUserSessionFactory.cs │ ├── IUserInfo.cs │ ├── ICurrentConfig.cs │ ├── Impl │ │ ├── UserSessionFactory.cs │ │ ├── CurrentConfig.cs │ │ └── UserInfo.cs │ └── UserSessionSelection.xaml.cs ├── Database │ ├── Tables │ │ ├── IPlanningEntity.cs │ │ ├── IAOIDataEntity.cs │ │ ├── IPostProcessEntity.cs │ │ ├── IMachineState.cs │ │ ├── InnerContent │ │ │ ├── ExperimentExecutionResults.cs │ │ │ ├── ExperimentData.cs │ │ │ └── PlannerOutputValues.cs │ │ ├── StepCommand.cs │ │ ├── DataEntity.cs │ │ ├── MachineStateEntity.cs │ │ ├── StepResult.cs │ │ ├── GenericDbRepository.cs │ │ ├── ScriptStepEntity.cs │ │ └── PlannerEntity.cs │ ├── Views │ │ ├── IMachineStateUI.cs │ │ ├── IAnalysisUIs.cs │ │ ├── EditTabView.xaml.cs │ │ ├── EditTabView.xaml │ │ ├── ExportTabView.xaml.cs │ │ ├── FilterTabView.xaml.cs │ │ ├── DatabaseView.xaml.cs │ │ ├── DatabaseTableView.xaml │ │ └── DatabaseView.xaml │ ├── Management │ │ ├── IDbCreator.cs │ │ ├── IDbConfigLoader.cs │ │ ├── IDbConfig.cs │ │ ├── Impl │ │ │ ├── DbConfig.cs │ │ │ ├── PersistentAttribute.cs │ │ │ ├── NpgSqlConfiguration.cs │ │ │ ├── DbContextExtensions.cs │ │ │ ├── AresDbContextFactory.cs │ │ │ ├── DbCreator.cs │ │ │ ├── DbConfigLoader.cs │ │ │ └── DbChecker.cs │ │ └── IDbChecker.cs │ ├── Filtering │ │ ├── IDbColumnCreator.cs │ │ ├── IFilterOptions.cs │ │ ├── IDbFilterManager.cs │ │ ├── IMachineStateFilterOptions.cs │ │ ├── IDbFilter.cs │ │ ├── Impl │ │ │ ├── MachineStateFilterOptions.cs │ │ │ ├── DbColumnCreator.cs │ │ │ └── FilterOptions.cs │ │ ├── IExperimentFilter.cs │ │ └── IExperimentFilterOptions.cs │ └── ViewModels │ │ └── DatabaseViewerViewModel.cs ├── TMPDbMigration │ ├── Migrators │ │ ├── PlannerDocs │ │ │ ├── IPlannerMigrator.cs │ │ │ └── IPlanningMigrator.cs │ │ ├── ExperimentDocs │ │ │ ├── IExperimentMigrator.cs │ │ │ └── IPostProcessMigrator.cs │ │ ├── MachineStateDocs │ │ │ └── IMachineStateMigrator.cs │ │ ├── DataDocs │ │ │ ├── IDataMigrator.cs │ │ │ ├── IAnalysisMigrator.cs │ │ │ └── Impl │ │ │ │ └── DataMigrator.cs │ │ ├── IMigrator.cs │ │ ├── ICollectionMigrator.cs │ │ └── PointJsonConverter.cs │ ├── UI │ │ ├── Views │ │ │ ├── DbMigratorView.xaml.cs │ │ │ └── DbMigratorView.xaml │ │ └── ViewModels │ │ │ └── DbMigratorViewModel.cs │ └── DbMigrationModule.cs ├── ErrorSupport │ ├── IErroredObjectRepo.cs │ ├── Impl │ │ ├── ErroredObjectRepo.cs │ │ ├── ErroredBundle.cs │ │ ├── ErrorResponse.cs │ │ ├── ErrorSeverity.cs │ │ ├── RetryInfos │ │ │ ├── CampaignRetryInfo.cs │ │ │ ├── ExperimentRetryInfo.cs │ │ │ ├── StepRetryInfo.cs │ │ │ └── CommandRetryInfo.cs │ │ └── AresError.cs │ ├── IErroredBundle.cs │ ├── IErrorable.cs │ ├── IAresError.cs │ └── UI │ │ ├── ErrorHandlingView.xaml.cs │ │ └── ErrorSeverityToIconConverter.cs ├── PluginSupport │ ├── IAresPlugin.cs │ ├── IAresModule.cs │ └── AresModule.cs ├── Properties │ ├── launchSettings.json │ ├── Settings.settings │ └── Settings.Designer.cs ├── DataHub │ ├── IDataHubEntry.cs │ ├── IDataHub.cs │ └── impl │ │ ├── DataHub.cs │ │ └── DataHubEntry.cs ├── DisposePatternHelpers │ ├── IModuleEntrypoint.cs │ ├── IReactiveSubscriber.cs │ ├── DisposableDebugger.cs │ └── IBasicDisposable.cs ├── Registries │ ├── Impl │ │ ├── AresCommandRegistry.cs │ │ ├── AresPlannerRegistry.cs │ │ ├── AresAnalyzerRegistry.cs │ │ ├── AresPlannerManagerRegistry.cs │ │ ├── ConfigManagerRegistry.cs │ │ └── MachineStateRegistry.cs │ ├── IAresUserConfigRegistry.cs │ ├── IAresAnalyzerRegistry.cs │ ├── IAresCommandRegistry.cs │ ├── IAresPlannerRegistry.cs │ ├── IAresPlannerManagerRegistry.cs │ └── IMachineStateRegistry.cs ├── Starter │ ├── IAresStarter.cs │ └── IScreenMapper.cs ├── Video │ └── Vlc.cs ├── PlanningSupport │ ├── IAresPlanningRequest.cs │ ├── IPlanningParameters.cs │ ├── ISelectedPlannersRepository.cs │ ├── IPlannerStatus.cs │ ├── Impl │ │ ├── SelectedPlannersRepository.cs │ │ ├── PlanResults.cs │ │ ├── PlannerStatus.cs │ │ ├── ManualPlanningView.xaml.cs │ │ ├── ManualPlanner.cs │ │ ├── ManualPlannerManager.cs │ │ └── ManualPlanningView.xaml │ ├── IPlanResults.cs │ ├── IAresPlanner.cs │ └── IAresPlannerManager.cs ├── Commands │ ├── IAresCommandPopulator.cs │ ├── IAresCommand.cs │ └── AresCommandPopulator.cs ├── Configurations │ ├── IAppDeviceConfig.cs │ ├── IUserDeviceConfig.cs │ ├── IConfigManager.cs │ ├── IApplicationConfiguration.cs │ ├── ISerialPortConfig.cs │ └── IProjectInfo.cs ├── ARESCore.csproj.user ├── AnalysisSupport │ ├── CustomAnalysisDbFilter.xaml │ ├── CustomAnalysisDbFilter.xaml.cs │ └── IAresAnalyzer.cs ├── Util │ ├── JsonTypeConverter.cs │ └── UnitEnums.cs ├── App.xaml ├── AresKernel.cs └── Extensions │ └── SimpleDisposable.cs ├── documents ├── ARES OS User Guide & Documentation.docx └── README.md ├── ARESSampleDevicesPlugin ├── AresSampleDevicesPlugin.csproj.user ├── SampleDevice │ ├── Config │ │ ├── ISampleDeviceAppConfig.cs │ │ ├── ISampleDeviceConfigManager.cs │ │ ├── ISampleDeviceUserDeviceConfig.cs │ │ ├── SampleDeviceConfigManager.cs │ │ └── SampleDeviceAppConfig.cs │ ├── UI │ │ ├── Config │ │ │ ├── SampleDeviceUserConfigViewModel.cs │ │ │ ├── SampleDeviceUserConfigView.xaml.cs │ │ │ ├── SampleDeviceAppConfigView.xaml.cs │ │ │ └── SampleDeviceAppConfigViewModel.cs │ │ ├── Control │ │ │ └── SampleDeviceControlView.xaml.cs │ │ └── BooleanToStringConverter.cs │ ├── SampleDeviceDoubleConstrainedValue.cs │ ├── ISampleDevice.cs │ └── Commands │ │ └── SampleDeviceGetBoolValCommand.cs └── AresSampleDevicesPlugin.csproj ├── ARESSamplePlanningPlugin ├── AresSamplePlanningPlugin.csproj.user ├── Planners │ ├── Parameters │ │ ├── ISamplePlanningParameter.cs │ │ └── Impl │ │ │ ├── SamplePlanningParameters.cs │ │ │ └── SamplePlanningParameter.cs │ ├── GradientDescent │ │ ├── GradientDescentPlanningParameters.cs │ │ ├── GradientDescentPlanningRequest.cs │ │ └── Views │ │ │ ├── GradientDescentPlannerView.xaml.cs │ │ │ └── ViewModels │ │ │ └── GradientDescentPlannerViewModel.cs │ └── Simple │ │ ├── Views │ │ ├── SimplePlannerView.xaml.cs │ │ └── ViewModels │ │ │ └── SimplePlannerViewModel.cs │ │ ├── SimplePlanningRequest.cs │ │ └── SimplePlanningParameters.cs └── ARESSamplePlanningPlugin.csproj ├── SECURITY.md ├── ARES_OS.sln.DotSettings ├── AresSampleAnalysisPlugin ├── AresSampleAnalysisPlugin.csproj.user ├── Analyzers │ └── Sample │ │ └── Ui │ │ └── Views │ │ └── SampleAnalyzerView.xaml.cs ├── AresSampleAnalysisPlugin.csproj └── Resources │ └── PlotAreaStyle.xaml └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | **/bin 2 | **/obj 3 | .vs 4 | *.orig 5 | -------------------------------------------------------------------------------- /ARESCore/Resources/Crosshair.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AFRL-ARES/ARES_OS/HEAD/ARESCore/Resources/Crosshair.bmp -------------------------------------------------------------------------------- /ARESCore/UI/Views/SplashScreenBackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AFRL-ARES/ARES_OS/HEAD/ARESCore/UI/Views/SplashScreenBackground.png -------------------------------------------------------------------------------- /ARESCore/Resources/PatchSpacingOutlineGray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AFRL-ARES/ARES_OS/HEAD/ARESCore/Resources/PatchSpacingOutlineGray.png -------------------------------------------------------------------------------- /ARESCore/UI/Helpers/IClosable.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace ARESCore.UI.Helpers 3 | { 4 | public interface IClosable 5 | { 6 | void Close(); 7 | } 8 | } -------------------------------------------------------------------------------- /documents/ARES OS User Guide & Documentation.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AFRL-ARES/ARES_OS/HEAD/documents/ARES OS User Guide & Documentation.docx -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/Usb/IUsbDevice.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.DeviceSupport.Usb 2 | { 3 | public interface IUsbDevice 4 | { 5 | USBDeviceInfo USBDeviceInfo { get; set; } 6 | } 7 | } -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/ExecutionStatus.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.Experiment.Results 2 | { 3 | public enum ExecutionStatus 4 | { 5 | DONE, PENDING, EXECUTING, ERROR 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /ARESCore/UserSession/StartupStateType.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.UserSession 2 | { 3 | public enum StartupStateType 4 | { 5 | DO_NOTHING, 6 | LAST_USED, 7 | SET_DEFAULTS 8 | } 9 | } -------------------------------------------------------------------------------- /ARESCore/Database/Tables/IPlanningEntity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ARESCore.Database.Tables 4 | { 5 | public interface IPlanningEntity 6 | { 7 | Guid Id { get; set; } 8 | } 9 | } -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/PlannerDocs/IPlannerMigrator.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.TMPDbMigration.Migrators.PlannerDocs 2 | { 3 | public interface IPlannerMigrator : IMigrator 4 | { 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/IAOIDataEntity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ARESCore.Database.Tables 4 | { 5 | public interface IAOIDataEntity 6 | { 7 | Guid Id { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/IErroredObjectRepo.cs: -------------------------------------------------------------------------------- 1 | using DynamicData.Binding; 2 | 3 | namespace ARESCore.ErrorSupport 4 | { 5 | public interface IErroredObjectRepo : IObservableCollection 6 | { 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /ARESCore/PluginSupport/IAresPlugin.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.PluginSupport 6 | { 7 | public interface IAresPlugin 8 | { 9 | } 10 | } -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/AresSampleDevicesPlugin.csproj.user: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/AresSamplePlanningPlugin.csproj.user: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/IMachineStateUI.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace ARESCore.Database.Views 4 | { 5 | public interface IMachineStateUI 6 | { 7 | UserControl MachineStateFilterView { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/ErroredObjectRepo.cs: -------------------------------------------------------------------------------- 1 | using DynamicData.Binding; 2 | 3 | namespace ARESCore.ErrorSupport.Impl 4 | { 5 | public class ErroredObjectRepo : ObservableCollectionExtended, IErroredObjectRepo 6 | { 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /ARESCore/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "profiles": { 3 | "ARESCore": { 4 | "commandName": "Project", 5 | "environmentVariables": { 6 | "ENABLE_XAML_DIAGNOSTICS_SOURCE_INFO": "1" 7 | } 8 | } 9 | } 10 | } -------------------------------------------------------------------------------- /ARESCore/Experiment/Scripting/IAresScriptCommand.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Commands; 2 | 3 | namespace ARESCore.Experiment.Scripting 4 | { 5 | public interface IAresScriptCommand : IAresCommand 6 | { 7 | bool IsComplete { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/Config/ISampleDeviceAppConfig.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Configurations; 2 | 3 | namespace AresSampleDevicesPlugin.SampleDevice.Config 4 | { 5 | public interface ISampleDeviceAppConfig : IAppDeviceConfig 6 | { 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/IDbCreator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.Database.Management 6 | { 7 | public interface IDbCreator 8 | { 9 | void Create(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/ICommandExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.Experiment.Results 2 | { 3 | public interface ICommandExecutionSummary : IExecutionSummary 4 | { 5 | string Command { get; set; } 6 | string Value { get; set; } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/Config/ISampleDeviceConfigManager.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Configurations; 2 | 3 | namespace AresSampleDevicesPlugin.SampleDevice.Config 4 | { 5 | public interface ISampleDeviceConfigManager : IConfigManager 6 | { 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /ARESCore/DataHub/IDataHubEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ARESCore.DataHub 4 | { 5 | public interface IDataHubEntry 6 | { 7 | Type DataType { get; set; } 8 | Object Data { get; set; } 9 | String Source { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/DisposePatternHelpers/IModuleEntrypoint.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.DisposePatternHelpers 6 | { 7 | public interface IModuleEntrypoint : IDisposable 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/PlannerDocs/IPlanningMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Newtonsoft.Json.Linq; 3 | 4 | namespace ARESCore.TMPDbMigration.Migrators.PlannerDocs 5 | { 6 | public interface IPlanningMigrator 7 | { 8 | Guid Migrate(JToken token); 9 | } 10 | } -------------------------------------------------------------------------------- /ARESCore/Registries/Impl/AresCommandRegistry.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Commands; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Registries.Impl 5 | { 6 | internal class AresCommandRegistry : ObservableCollectionExtended, IAresCommandRegistry 7 | { 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/IDbConfigLoader.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.Database.Management 6 | { 7 | public interface IDbConfigLoader 8 | { 9 | IDbConfig Load(); 10 | void Save(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IDbColumnCreator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.Database.Filtering 6 | { 7 | public interface IDbColumnCreator 8 | { 9 | List> GetRows( Type inputType ); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IFilterOptions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.Database.Filtering 8 | { 9 | public interface IFilterOptions 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/IAresDeviceState.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.DeviceSupport 7 | { 8 | public interface IAresDeviceState:IReactiveSubscriber 9 | { 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Starter/IAresStarter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.Starter 8 | { 9 | public interface IAresStarter 10 | { 11 | void Start(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/UserSession/IUserSession.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace ARESCore.UserSession 3 | { 4 | public interface IUserSession 5 | { 6 | string Username { get; set; } 7 | string SaveDirectory { get; set; } 8 | string FileNameAndPath { get; set; } 9 | bool SaveSession(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Video/Vlc.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.Video 7 | { 8 | public class Vlc : ReactiveSubscriber 9 | { 10 | public Vlc() 11 | { 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/UI/Config/SampleDeviceUserConfigViewModel.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | 3 | namespace AresSampleDevicesPlugin.SampleDevice.UI.Config 4 | { 5 | public class SampleDeviceUserConfigViewModel : ReactiveSubscriber 6 | { 7 | 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/IDbConfig.cs: -------------------------------------------------------------------------------- 1 | 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | 6 | namespace ARESCore.Database.Management 7 | { 8 | public interface IDbConfig 9 | { 10 | string Ip { get; set; } 11 | 12 | int Port { get; set; } 13 | } 14 | } -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/IAresDeviceViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.DeviceSupport 7 | { 8 | public interface IAresDeviceViewModel:IReactiveSubscriber 9 | { 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/IAresPlanningRequest.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.PlanningSupport 8 | { 9 | public interface IAresPlanningRequest 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/Registries/Impl/AresPlannerRegistry.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.PlanningSupport; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Registries.Impl 5 | { 6 | internal class AresPlannerRegistry: ObservableCollectionExtended, IAresPlannerRegistry 7 | { 8 | 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/ExperimentDocs/IExperimentMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.TMPDbMigration.Migrators.ExperimentDocs 6 | { 7 | public interface IExperimentMigrator : IMigrator 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/Parameters/ISamplePlanningParameter.cs: -------------------------------------------------------------------------------- 1 | namespace AresSamplePlanningPlugin.Planners.Parameters 2 | { 3 | public interface ISamplePlanningParameter 4 | { 5 | double Value { get; set; } 6 | bool IsPlanned { get; set; } 7 | string ScriptLabel { get; } 8 | } 9 | } -------------------------------------------------------------------------------- /ARESCore/DataHub/IDataHub.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using Prism.Common; 3 | 4 | namespace ARESCore.DataHub 5 | { 6 | public interface IDataHub : IReactiveSubscriber 7 | { 8 | IDataHubEntry Data { get; set; } 9 | // void PutData(IDataHubEntry dataHubEntry); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/ErroredBundle.cs: -------------------------------------------------------------------------------- 1 | using DynamicData.Binding; 2 | 3 | namespace ARESCore.ErrorSupport.Impl 4 | { 5 | public class ErroredBundle: IErroredBundle 6 | { 7 | public IErrorable ErrorHandler { get; set; } 8 | public IErrorable ErrorNotifier { get; set; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/Registries/Impl/AresAnalyzerRegistry.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.AnalysisSupport; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Registries.Impl 5 | { 6 | internal class AresAnalyzerRegistry : ObservableCollectionExtended, IAresAnalyzerRegistry 7 | { 8 | 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/IAnalysisUIs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.Database.Views 7 | { 8 | public interface IAnalysisUIs 9 | { 10 | UserControl DbDocFilterView { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/MachineStateDocs/IMachineStateMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.TMPDbMigration.Migrators.MachineStateDocs 6 | { 7 | public interface IMachineStateMigrator : IMigrator 8 | { 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/Commands/IAresCommandPopulator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.Commands 8 | { 9 | public interface IAresCommandPopulator 10 | { 11 | void Populate(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/IPlanningParameters.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading; 5 | 6 | namespace ARESCore.PlanningSupport 7 | { 8 | public interface IPlanningParameters 9 | { 10 | IAresPlanningRequest GenerateRequest( ); 11 | } 12 | } -------------------------------------------------------------------------------- /ARESCore/Registries/IAresUserConfigRegistry.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Configurations; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Registries 5 | { 6 | public interface IConfigManagerRegistry : IObservableCollection 7 | { 8 | T GetManager() where T : IConfigManager; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/PluginSupport/IAresModule.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Prism.Modularity; 7 | 8 | namespace ARESCore.PluginSupport 9 | { 10 | public interface IAresModule: IModule 11 | { 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Registries/IAresAnalyzerRegistry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using ARESCore.AnalysisSupport; 4 | using DynamicData.Binding; 5 | 6 | namespace ARESCore.Registries 7 | { 8 | public interface IAresAnalyzerRegistry: IObservableCollection 9 | { 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/Impl/DbConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.Database.Management.Impl 6 | { 7 | public class DbConfig: IDbConfig 8 | { 9 | public string Ip { get; set; } 10 | 11 | public int Port { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/IPostProcessEntity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.Database.Tables 8 | { 9 | public interface IPostProcessEntity 10 | { 11 | Guid Id { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Registries/IAresCommandRegistry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.Commands; 5 | using DynamicData.Binding; 6 | 7 | namespace ARESCore.Registries 8 | { 9 | public interface IAresCommandRegistry: IObservableCollection 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/Registries/Impl/AresPlannerManagerRegistry.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.PlanningSupport; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Registries.Impl 5 | { 6 | internal class AresPlannerManagerRegistry: ObservableCollectionExtended, IAresPlannerManagerRegistry 7 | { 8 | 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /ARESCore/Resources/IResourceManager.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.Resources 8 | { 9 | public interface IResourceManager 10 | { 11 | string GetString( string inputString ); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/ErrorResponse.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.ErrorSupport.Impl 8 | { 9 | public enum ErrorResponse 10 | { 11 | IgnoreAndContinue, Stop, Estop, Retry 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/ErrorSeverity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.ErrorSupport.Impl 8 | { 9 | public enum ErrorSeverity 10 | { 11 | Info, Warn, Error, Severe, Catastrophic 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/DataDocs/IDataMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.TMPDbMigration.Migrators.DataDocs 8 | { 9 | public interface IDataMigrator: IMigrator 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/Configurations/IAppDeviceConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.Configurations 7 | { 8 | public interface IAppDeviceConfig : IReactiveSubscriber 9 | { 10 | void Load(); 11 | void Save(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/IExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ARESCore.DisposePatternHelpers; 3 | 4 | namespace ARESCore.Experiment.Results 5 | { 6 | public interface IExecutionSummary : IReactiveSubscriber 7 | { 8 | TimeSpan ExecutionDuration { get; set; } 9 | ExecutionStatus Status { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Configurations/IUserDeviceConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.Configurations 7 | { 8 | public interface IUserDeviceConfig : IReactiveSubscriber 9 | { 10 | void Load(); 11 | void Save(); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IDbFilterManager.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using ARESCore.DisposePatternHelpers; 3 | 4 | namespace ARESCore.Database.Filtering 5 | { 6 | public interface IDbFilterManager: IReactiveSubscriber 7 | { 8 | void DoFilter(); 9 | 10 | IEnumerable LastFilterResult { get; set; } 11 | 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Experiment/ICampaignExecutor.cs: -------------------------------------------------------------------------------- 1 | using System.Threading.Tasks; 2 | using ARESCore.DisposePatternHelpers; 3 | 4 | namespace ARESCore.Experiment 5 | { 6 | public interface ICampaignExecutor : IReactiveSubscriber 7 | { 8 | Task Execute(); 9 | bool IsComplete { get; set; } 10 | bool ShouldExecute { get; set; } 11 | } 12 | } -------------------------------------------------------------------------------- /ARESCore/UserSession/IUserSessionFactory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.UserSession 8 | { 9 | public interface IUserSessionFactory 10 | { 11 | IUserSession CreateSession(string userPath); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IMachineStateFilterOptions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ARESCore.Database.Filtering 5 | { 6 | public interface IMachineStateFilterOptions : IFilterOptions 7 | { 8 | bool FilterChipDescriptions { get; set; } 9 | IList Chips { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Registries/IAresPlannerRegistry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using ARESCore.AnalysisSupport; 4 | using ARESCore.PlanningSupport; 5 | using DynamicData.Binding; 6 | 7 | namespace ARESCore.Registries 8 | { 9 | public interface IAresPlannerRegistry: IObservableCollection 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/AresSplashScreen.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.UI.Views 2 | { 3 | /// 4 | /// Interaction logic for SplashScreen.xaml 5 | /// 6 | public partial class AresSplashScreen 7 | { 8 | public AresSplashScreen() 9 | { 10 | InitializeComponent(); 11 | // Topmost = true; 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /ARESCore/UI/IAresConsole.cs: -------------------------------------------------------------------------------- 1 | using ICSharpCode.AvalonEdit.Document; 2 | 3 | namespace ARESCore.UI 4 | { 5 | public interface IAresConsole 6 | { 7 | void WriteLine(string text); 8 | 9 | void Write(string text); 10 | 11 | void WriteLine(); 12 | 13 | int MaxLength { get; } 14 | 15 | TextDocument Document { get; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/Usb/UsbDevice.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.DeviceSupport.Usb 7 | { 8 | public abstract class UsbDevice : ReactiveSubscriber, IUsbDevice 9 | { 10 | public abstract USBDeviceInfo USBDeviceInfo { get; set; } 11 | } 12 | } -------------------------------------------------------------------------------- /ARESCore/Database/Management/Impl/PersistentAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.Database.Management.Impl 8 | { 9 | [AttributeUsage( AttributeTargets.Class )] 10 | public class PersistentAttribute : Attribute 11 | { 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Registries/IAresPlannerManagerRegistry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using ARESCore.AnalysisSupport; 4 | using ARESCore.PlanningSupport; 5 | using DynamicData.Binding; 6 | 7 | namespace ARESCore.Registries 8 | { 9 | public interface IAresPlannerManagerRegistry: IObservableCollection 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/ARESCore.csproj.user: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Designer 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /ARESCore/Database/ViewModels/DatabaseViewerViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.DisposePatternHelpers; 5 | 6 | namespace ARESCore.Database.ViewModels 7 | { 8 | /// 9 | /// DatabaseViewer 10 | /// 11 | public class DatabaseViewerViewModel : ReactiveSubscriber 12 | { 13 | } 14 | } -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/AresDeviceState.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ARESCore.DisposePatternHelpers; 7 | 8 | namespace ARESCore.DeviceSupport 9 | { 10 | public abstract class AresDeviceState:ReactiveSubscriber, IAresDeviceState 11 | { 12 | 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/IErroredBundle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace ARESCore.ErrorSupport 8 | { 9 | public interface IErroredBundle 10 | { 11 | IErrorable ErrorHandler { get; set; } 12 | 13 | IErrorable ErrorNotifier { get; set; } 14 | } 15 | } -------------------------------------------------------------------------------- /ARESCore/Experiment/IExperimentBatch.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.AnalysisSupport; 2 | using ARESCore.PlanningSupport; 3 | 4 | namespace ARESCore.Experiment 5 | { 6 | public interface IExperimentBatch 7 | { 8 | IPlannedExperimentBatchInputs Inputs { get; set; } 9 | IAresAnalyzer Analyzer { get; set; } 10 | IAresPlannerManager PlannerManager { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/Registries/IMachineStateRegistry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.Database.Tables; 5 | using DynamicData.Binding; 6 | 7 | namespace ARESCore.Registries 8 | { 9 | public interface IMachineStateRegistry : IObservableCollection 10 | { 11 | int MsBetweenWrites { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/IMachineState.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.Database.Tables 6 | { 7 | public interface IMachineState 8 | { 9 | string JsonTitle { get; set; } 10 | void TryParse( string currentDesc, string lineToken, bool tokenHasValue ); 11 | 12 | IMachineState Clone(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/RetryInfos/CampaignRetryInfo.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Experiment.Results; 2 | 3 | namespace ARESCore.ErrorSupport.Impl.RetryInfos 4 | { 5 | public class CampaignRetryInfo 6 | { 7 | // TODO: Property for the campaign 8 | // TODO: Property for data to build the campaign 9 | public ICampaignExecutionSummary CampaignResult { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/RetryInfos/ExperimentRetryInfo.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Experiment; 2 | using ARESCore.Experiment.Results; 3 | 4 | namespace ARESCore.ErrorSupport.Impl.RetryInfos 5 | { 6 | public class ExperimentRetryInfo 7 | { 8 | public IPlannedExperimentInputs Inputs { get; set; } 9 | public IExperimentExecutionSummary ExperimentResult { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/ISelectedPlannersRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using DynamicData.Binding; 7 | 8 | namespace ARESCore.PlanningSupport 9 | { 10 | public interface ISelectedPlannersRepository: IObservableCollection 11 | { 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/ICampaignExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Experiment.Results 5 | { 6 | public interface ICampaignExecutionSummary : IExecutionSummary 7 | { 8 | TimeSpan ETC { get; set; } 9 | ObservableCollectionExtended ExperimentExecutionSummaries { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/IMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using Newtonsoft.Json.Linq; 5 | 6 | namespace ARESCore.TMPDbMigration.Migrators 7 | { 8 | public interface IMigrator 9 | { 10 | void Migrate( JToken jToken); 11 | void Migrate( JToken jToken, Guid refId ); 12 | string TypeString { get; } 13 | } 14 | } -------------------------------------------------------------------------------- /ARESCore/UI/ILoadingStatus.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using MahApps.Metro.IconPacks; 7 | 8 | namespace ARESCore.UI 9 | { 10 | public interface ILoadingStatus 11 | { 12 | string StatusInfo { get; set; } 13 | 14 | PackIconMaterialKind Icon { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/ICollectionMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace ARESCore.TMPDbMigration.Migrators 7 | { 8 | public interface ICollectionMigrator : IMigrator 9 | { 10 | Task MigrateFile( string file,bool doParallel); 11 | bool Migrating { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/Config/ISampleDeviceUserDeviceConfig.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Configurations; 2 | using ARESCore.UserSession; 3 | 4 | namespace AresSampleDevicesPlugin.SampleDevice.Config 5 | { 6 | public interface ISampleDeviceUserDeviceConfig : IUserDeviceConfig 7 | { 8 | StartupStateType StartupType { get; set; } 9 | double DoubleValue { get; set; } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/SampleDeviceDoubleConstrainedValue.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DeviceSupport; 2 | 3 | namespace AresSampleDevicesPlugin.SampleDevice 4 | { 5 | public class SampleDeviceDoubleConstrainedValue : ConstrainedValue 6 | { 7 | public SampleDeviceDoubleConstrainedValue() 8 | { 9 | MaxValue = 6.0; 10 | MinValue = 0.01; 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/IErrorable.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | using ARESCore.ErrorSupport.Impl; 4 | 5 | namespace ARESCore.ErrorSupport 6 | { 7 | public interface IErrorable 8 | { 9 | List AvailableErrorResponses { get; } 10 | 11 | IAresError Error { get; set; } 12 | 13 | Task Handle( ErrorResponse response ); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/IPlannerStatus.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows.Controls; 7 | 8 | namespace ARESCore.PlanningSupport 9 | { 10 | public interface IPlannerStatus 11 | { 12 | string StatusText { get; set; } 13 | 14 | ContentControl Image { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/DataDocs/IAnalysisMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Newtonsoft.Json.Linq; 7 | 8 | namespace ARESCore.TMPDbMigration.Migrators.DataDocs 9 | { 10 | public interface IAnalysisMigrator 11 | { 12 | void Migrate( JToken token, Guid refId ); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IDbFilter.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using ARESCore.Database.Tables; 3 | 4 | namespace ARESCore.Database.Filtering 5 | { 6 | public interface IDbFilter 7 | { 8 | IEnumerable Filter( IEnumerable preFilteredData ); 9 | IEnumerable FilterExperimentsOn( IEnumerable expData, IEnumerable typeData ); 10 | 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/ExperimentDocs/IPostProcessMigrator.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Newtonsoft.Json.Linq; 7 | 8 | namespace ARESCore.TMPDbMigration.Migrators.ExperimentDocs 9 | { 10 | public interface IPostProcessMigrator 11 | { 12 | Guid Migrate( JToken token ); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/UI/Config/SampleDeviceUserConfigView.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace AresSampleDevicesPlugin.SampleDevice.UI.Config 2 | { 3 | /// 4 | /// Interaction logic for MfcUserConfigView.xaml 5 | /// 6 | public partial class SampleDeviceUserConfigView 7 | { 8 | public SampleDeviceUserConfigView() 9 | { 10 | InitializeComponent(); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/Parameters/Impl/SamplePlanningParameters.cs: -------------------------------------------------------------------------------- 1 | using DynamicData.Binding; 2 | 3 | namespace AresSamplePlanningPlugin.Planners.Parameters.Impl 4 | { 5 | public class SamplePlanningParameters : ObservableCollectionExtended 6 | { 7 | public SamplePlanningParameters() 8 | { 9 | Add(new SamplePlanningParameter()); 10 | } 11 | 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/UI/Config/SampleDeviceAppConfigView.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace AresSampleDevicesPlugin.SampleDevice.UI.Config 2 | { 3 | /// 4 | /// Interaction logic for SampleDeviceAppConfigView.xaml 5 | /// 6 | public partial class SampleDeviceAppConfigView 7 | { 8 | public SampleDeviceAppConfigView() 9 | { 10 | InitializeComponent(); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/IDbChecker.cs: -------------------------------------------------------------------------------- 1 | 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | 6 | namespace ARESCore.Database.Management 7 | { 8 | public enum DBState 9 | { 10 | OK, 11 | BadConnection, 12 | BadDb 13 | }; 14 | public interface IDBChecker 15 | { 16 | DBState Check( string ip, int port ); 17 | 18 | string CheckResults { get; set; } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/IAresDeviceCommand.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ARESCore.Commands; 3 | 4 | namespace ARESCore.DeviceSupport 5 | { 6 | public interface IAresDeviceCommand: IAresCommand 7 | { 8 | Enum UnitType { get; set; } 9 | 10 | bool IsWriteOnly { get; } 11 | 12 | string Serialize(); 13 | 14 | void Deserialize(string val); 15 | 16 | Type AssociatedDeviceType { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/Impl/SelectedPlannersRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using DynamicData.Binding; 7 | 8 | namespace ARESCore.PlanningSupport.Impl 9 | { 10 | internal class SelectedPlannersRepository: ObservableCollectionExtended, ISelectedPlannersRepository 11 | { 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/GradientDescent/GradientDescentPlanningParameters.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ARESCore.PlanningSupport; 3 | 4 | namespace AresSamplePlanningPlugin.Planners.GradientDescent 5 | { 6 | public class GradientDescentPlanningParameters : IPlanningParameters 7 | { 8 | public IAresPlanningRequest GenerateRequest() 9 | { 10 | throw new NotImplementedException(); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/RetryInfos/StepRetryInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using ARESCore.Commands; 3 | using ARESCore.Experiment.Results; 4 | 5 | namespace ARESCore.ErrorSupport.Impl.RetryInfos 6 | { 7 | public class StepRetryInfo 8 | { 9 | public IAresCommand Step { get; set; } 10 | public List SubList { get; set; } 11 | public IStepExecutionSummary StepResult { get; set; } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ARESCore/Starter/IScreenMapper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using WpfScreenHelper; 7 | 8 | namespace ARESCore.Starter 9 | { 10 | public interface IScreenMapper 11 | { 12 | Screen PrimaryScreen { get; set; } 13 | 14 | Screen SecondaryScreen { get; set; } 15 | 16 | Screen TopScreen { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/Impl/MachineStateFilterOptions.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using ARESCore.DisposePatternHelpers; 3 | 4 | namespace ARESCore.Database.Filtering.Impl 5 | { 6 | public class MachineStateFilterOptions : ReactiveSubscriber, IMachineStateFilterOptions 7 | { 8 | public bool FilterChipDescriptions { get; set; } 9 | public IList Chips { get; set; } = new List(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Scripting/IScriptExecutor.cs: -------------------------------------------------------------------------------- 1 | using System.Threading.Tasks; 2 | using ARESCore.DisposePatternHelpers; 3 | 4 | namespace ARESCore.Experiment.Scripting 5 | { 6 | public interface IScriptExecutor : IReactiveSubscriber 7 | { 8 | Task Run( string script, IPlannedExperimentInputs inputs ); 9 | 10 | bool Validate( string script, IPlannedExperimentInputs inputs ); 11 | bool IsComplete { get; set; } 12 | } 13 | } -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/IPlanResults.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ARESCore.DisposePatternHelpers; 7 | using ARESCore.Experiment; 8 | 9 | namespace ARESCore.PlanningSupport 10 | { 11 | public interface IPlanResults : IReactiveSubscriber 12 | { 13 | IPlannedExperimentBatchInputs Results { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/InnerContent/ExperimentExecutionResults.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using DynamicData.Annotations; 5 | 6 | namespace ARESCore.Database.Tables.InnerContent 7 | { 8 | public class ExperimentExecutionResults 9 | { 10 | [CanBeNull] 11 | public TimeSpan Runtime { get; set; } 12 | [CanBeNull] 13 | public DateTime Started { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/ISampleDevice.cs: -------------------------------------------------------------------------------- 1 | using System.Threading.Tasks; 2 | using ARESCore.DeviceSupport; 3 | 4 | namespace AresSampleDevicesPlugin.SampleDevice 5 | { 6 | public interface ISampleDevice : IAresDevice 7 | { 8 | Task SetDouble(double value); 9 | Task SetBool(bool value); 10 | Task GetDouble(); 11 | Task GetBool(); 12 | double DoubleValue { get; } 13 | bool BoolValue { get; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/Simple/Views/SimplePlannerView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace AresSamplePlanningPlugin.Planners.Simple.Views 4 | { 5 | /// 6 | /// Interaction logic for SimplePlannerView.xaml 7 | /// 8 | public partial class SimplePlannerView : UserControl 9 | { 10 | public SimplePlannerView() 11 | { 12 | InitializeComponent(); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /SECURITY.md: -------------------------------------------------------------------------------- 1 | # Security Policy 2 | 3 | ## Supported Versions 4 | 5 | Use this section to tell people about which versions of your project are 6 | currently being supported with security updates. 7 | 8 | | Version | Supported | 9 | | ------- | ------------------ | 10 | | Pending | :white_check_mark: | 11 | 12 | ## Reporting a Vulnerability 13 | 14 | Please inform AFRL.RX.AREScontact@us.af.mil if any vulnerabilities are discovered. 15 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/ARESSamplePlanningPlugin.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | net5.0-windows 5 | true 6 | Debug;Release 7 | x64 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/EditTabView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.Database.Views 7 | { 8 | /// 9 | /// Interaction logic for EditTabView.xaml 10 | /// 11 | public partial class EditTabView : UserControl 12 | { 13 | public EditTabView() 14 | { 15 | InitializeComponent(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/IStepExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using DynamicData.Binding; 2 | 3 | namespace ARESCore.Experiment.Results 4 | { 5 | public interface IStepExecutionSummary : IExecutionSummary 6 | { 7 | string StepName { get; set; } 8 | ObservableCollectionExtended CommandExecutionSummaries { get; set; } 9 | // I don't think knowing whether or not the step was parallel matters after execution 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/Simple/SimplePlanningRequest.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using ARESCore.PlanningSupport; 3 | using AresSamplePlanningPlugin.Planners.Parameters.Impl; 4 | 5 | namespace AresSamplePlanningPlugin.Planners.Simple 6 | { 7 | public class SimplePlanningRequest : IAresPlanningRequest 8 | { 9 | public List Experiments { get; set; } = new List(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/Settings/UserPreferences.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | using ARESCore.Registries; 3 | using Ninject; 4 | 5 | namespace ARESCore.UI.Views.Settings 6 | { 7 | /// 8 | /// Interaction logic for UserPreferences.xaml 9 | /// 10 | public partial class UserPreferences : UserControl 11 | { 12 | 13 | public UserPreferences() 14 | { 15 | InitializeComponent(); 16 | 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /ARESCore/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | False 7 | 8 | 9 | -------------------------------------------------------------------------------- /ARESCore/Registries/Impl/ConfigManagerRegistry.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | using ARESCore.Configurations; 3 | using DynamicData.Binding; 4 | 5 | namespace ARESCore.Registries.Impl 6 | { 7 | internal class ConfigManagerRegistry : ObservableCollectionExtended, IConfigManagerRegistry 8 | { 9 | public T GetManager() where T : IConfigManager 10 | { 11 | return (T)this.FirstOrDefault( manager => manager is T ); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/ICalibrationPeak.cs: -------------------------------------------------------------------------------- 1 | 2 | using System.Windows.Media; 3 | using ARESCore.DisposePatternHelpers; 4 | 5 | namespace ARESCore.DeviceSupport 6 | { 7 | public interface ICalibrationPeak : IReactiveSubscriber 8 | { 9 | Color DefaultColor { get; } 10 | string Name { get; set; } 11 | double WaveNumber { get; set; } 12 | double PixelNumber { get; set; } 13 | Color ColorId { get; set; } 14 | bool DrawOnMain { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/Serial/Rs232Config.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.DeviceSupport.Serial 7 | { 8 | /// 9 | /// Interaction logic for Rs232Config.xaml 10 | /// 11 | public partial class Rs232Config : UserControl 12 | { 13 | 14 | public Rs232Config() 15 | { 16 | InitializeComponent(); 17 | } 18 | 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/Serial/SerialTerminal.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.DeviceSupport.Serial 7 | { 8 | /// 9 | /// Interaction logic for SerialTerminal.xaml 10 | /// 11 | public partial class SerialTerminal : UserControl 12 | { 13 | public SerialTerminal() 14 | { 15 | InitializeComponent(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/Experiment/UI/Views/BatchResultsView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.Experiment.UI.Views 7 | { 8 | /// 9 | /// Interaction logic for BatchResultsView.xaml 10 | /// 11 | public partial class BatchResultsView : UserControl 12 | { 13 | public BatchResultsView() 14 | { 15 | InitializeComponent(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/UI/Views/DbMigratorView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.TMPDbMigration.UI.Views 7 | { 8 | /// 9 | /// Interaction logic for DbMigratorView.xaml 10 | /// 11 | public partial class DbMigratorView : UserControl 12 | { 13 | public DbMigratorView() 14 | { 15 | InitializeComponent(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/UserSession/IUserInfo.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Reactive; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using ReactiveUI; 8 | 9 | namespace ARESCore.UserSession 10 | { 11 | public interface IUserInfo 12 | { 13 | string Username { get; set; } 14 | string SaveFileName { get; set; } 15 | string SaveDirectory { get; set; } 16 | DateTime LastLoadedDate { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/Settings/ApplicationStyleView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | 6 | namespace ARESCore.UI.Views.Settings 7 | { 8 | /// 9 | /// Interaction logic for AccentStyleWindow.xaml 10 | /// 11 | public partial class ApplicationStyleView : UserControl 12 | { 13 | public ApplicationStyleView() 14 | { 15 | InitializeComponent(); 16 | 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/GradientDescent/GradientDescentPlanningRequest.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using ARESCore.PlanningSupport; 3 | using AresSamplePlanningPlugin.Planners.Parameters.Impl; 4 | 5 | namespace AresSamplePlanningPlugin.Planners.GradientDescent 6 | { 7 | public class GradientDescentPlanningRequest : IAresPlanningRequest 8 | { 9 | public List Experiments { get; set; } = new List(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /ARESCore/UI/AresNotification.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Prism.Interactivity.InteractionRequest; 7 | 8 | namespace ARESCore.UI 9 | { 10 | public class AresNotification : Notification 11 | { 12 | public event EventHandler CloseRequested; 13 | 14 | public void RequestClose() 15 | { 16 | CloseRequested?.Invoke( this, EventArgs.Empty ); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/GradientDescent/Views/GradientDescentPlannerView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Controls; 2 | 3 | namespace AresSamplePlanningPlugin.Planners.GradientDescent.Views 4 | { 5 | /// 6 | /// Interaction logic for GradientDescentPlannerView.xaml 7 | /// 8 | public partial class GradientDescentPlannerView : UserControl 9 | { 10 | public GradientDescentPlannerView() 11 | { 12 | InitializeComponent(); 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESCore/Experiment/IPlannedExperimentInputs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Drawing.Text; 4 | using System.Linq; 5 | using ARESCore.DisposePatternHelpers; 6 | using ARESCore.Experiment.impl; 7 | 8 | 9 | namespace ARESCore.Experiment 10 | { 11 | public interface IPlannedExperimentInputs : IReactiveSubscriber 12 | { 13 | IList Inputs { get; } 14 | void SetInputs( List variableStrings, List inputs); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /ARESCore/UserSession/ICurrentConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ARESCore.Configurations; 7 | 8 | namespace ARESCore.UserSession 9 | { 10 | public interface ICurrentConfig 11 | { 12 | IUserInfo User { get; set; } 13 | 14 | IProjectInfo Project { get; set; } 15 | 16 | IUserSession UserSession { get; set; } 17 | 18 | double TimerPrecision { get; set; } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/StepCommand.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel.DataAnnotations; 3 | using System.ComponentModel.DataAnnotations.Schema; 4 | using System.Linq; 5 | using DynamicData.Annotations; 6 | 7 | namespace ARESCore.Database.Tables 8 | { 9 | [Table( "StepCommands", Schema = "public" )] 10 | public class ScriptStepCommandEntity 11 | { 12 | [Key] 13 | public Guid Id { get; set; } 14 | 15 | public string CommandText { get; set; } = "Default"; 16 | 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/RetryInfos/CommandRetryInfo.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.Commands; 5 | using ARESCore.Experiment.Results; 6 | 7 | namespace ARESCore.ErrorSupport.Impl.RetryInfos 8 | { 9 | public class CommandRetryInfo 10 | { 11 | public IAresCommand Command { get; set; } 12 | public List RevisedTokens { get; set; } 13 | public ICommandExecutionSummary CommandExecutionSummary { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/Impl/PlanResults.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using ARESCore.Experiment; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.PlanningSupport.Impl 6 | { 7 | internal class PlanResults : ReactiveSubscriber, IPlanResults 8 | { 9 | private IPlannedExperimentBatchInputs _results; 10 | 11 | public IPlannedExperimentBatchInputs Results 12 | { 13 | get => _results; 14 | set => this.RaiseAndSetIfChanged( ref _results, value ); 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /ARESCore/DisposePatternHelpers/IReactiveSubscriber.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using ARESCore.ErrorSupport; 5 | using ReactiveUI; 6 | 7 | namespace ARESCore.DisposePatternHelpers 8 | { 9 | /// 10 | /// Interface definition for classes which must implement both and . 11 | /// 12 | public interface IReactiveSubscriber : IReactiveObject, IBasicDisposable, IErrorable 13 | { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/IExperimentExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Experiment.impl; 2 | using DynamicData.Binding; 3 | 4 | namespace ARESCore.Experiment.Results 5 | { 6 | public interface IExperimentExecutionSummary : IExecutionSummary 7 | { 8 | int ExperimentNumber { get; set; } 9 | ExperimentParameter[] Parameters { get; set; } 10 | double Result { get; set; } 11 | object ResultBase { get; set; } 12 | ObservableCollectionExtended StepExecutionSummaries { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/DataEntity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel.DataAnnotations; 3 | using System.ComponentModel.DataAnnotations.Schema; 4 | using ARESCore.Database.Management.Impl; 5 | using DynamicData.Annotations; 6 | 7 | namespace ARESCore.Database.Tables 8 | { 9 | [Table("Data", Schema = "public")] 10 | public class DataEntity 11 | { 12 | [Key] 13 | public Guid Id { get; set; } 14 | [NotNull] 15 | public DateTime TimeStamp { get; set; } = DateTime.Now; 16 | public Guid FromStep { get; set; } 17 | } 18 | } -------------------------------------------------------------------------------- /ARESCore/Database/Tables/MachineStateEntity.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel.DataAnnotations; 3 | using System.ComponentModel.DataAnnotations.Schema; 4 | using DynamicData.Annotations; 5 | 6 | 7 | namespace ARESCore.Database.Tables 8 | { 9 | [Table( "MachineState", Schema = "public")] 10 | public class MachineStateEntity 11 | { 12 | [Key] 13 | public Guid Id { get; set; } 14 | 15 | public DateTime TimeStamp { get; set; } = DateTime.Now; 16 | 17 | [CanBeNull] 18 | public Guid FromStep { get; set; } 19 | } 20 | } -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/ConstrainedValue.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ReactiveUI; 3 | 4 | namespace ARESCore.DeviceSupport 5 | { 6 | public class ConstrainedValue : ReactiveObject where T : IComparable 7 | { 8 | public T MaxValue { get; set; } 9 | 10 | public T MinValue { get; set; } 11 | 12 | public virtual T Constrain(T input) 13 | { 14 | if (input.CompareTo(MaxValue) > 0) 15 | return MaxValue; 16 | if (input.CompareTo(MinValue) < 0) 17 | return MinValue; 18 | return input; 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/Impl/AresError.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows.Media; 7 | using MahApps.Metro.IconPacks; 8 | 9 | namespace ARESCore.ErrorSupport.Impl 10 | { 11 | public class AresError: IAresError 12 | { 13 | public ErrorSeverity Severity { get; set; } 14 | public string Text { get; set; } 15 | public PackIconMaterialKind Icon { get; set; } 16 | public string DecoratorText { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /ARESCore/Experiment/ICampaign.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | 3 | namespace ARESCore.Experiment 4 | { 5 | public interface ICampaign : IReactiveSubscriber 6 | { 7 | int NumExperimentsToRun { get; set; } 8 | int ReplanInterval { get; set; } 9 | string ExpScript { get; set; } 10 | bool CanRun { get; set; } 11 | bool IsExecuting { get; set; } 12 | string InterExpScript { get; set; } 13 | string CampaignCloseScript { get; set; } 14 | byte CanRunMask { get; set; } 15 | bool InitiatingEStop { get; set; } 16 | } 17 | } -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/IAresError.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows.Media; 7 | using ARESCore.ErrorSupport.Impl; 8 | using MahApps.Metro.IconPacks; 9 | 10 | namespace ARESCore.ErrorSupport 11 | { 12 | public interface IAresError 13 | { 14 | ErrorSeverity Severity { get; set; } 15 | 16 | string Text { get; set; } 17 | 18 | PackIconMaterialKind Icon { get; set; } 19 | 20 | string DecoratorText { get; set; } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /ARESCore/DisposePatternHelpers/DisposableDebugger.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.DisposePatternHelpers 6 | { 7 | internal class DisposableDebugger 8 | { 9 | public string Stack; 10 | public static uint Count; 11 | 12 | public DisposableDebugger() 13 | { 14 | Stack = Environment.StackTrace; 15 | Count++; 16 | } 17 | 18 | public void OnExit() 19 | { 20 | throw new InvalidOperationException( "Destroyed without being disposed" ); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ARESCore/DataHub/impl/DataHub.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using ReactiveUI; 3 | 4 | namespace ARESCore.DataHub.impl 5 | { 6 | public class DataHub : ReactiveSubscriber, IDataHub 7 | { 8 | private IDataHubEntry _data; 9 | 10 | public IDataHubEntry Data 11 | { 12 | get => _data; 13 | set 14 | { //changing it because it will only notify if the value changes. It needs to notify regardless. NO IFS,ANDS, or BUTS. YOU DO IT!! 15 | _data = value; 16 | this.RaisePropertyChanged("Data"); 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /ARESSamplePlanningPlugin/Planners/Simple/SimplePlanningParameters.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.PlanningSupport; 2 | using AresSamplePlanningPlugin.Planners.Parameters.Impl; 3 | 4 | namespace AresSamplePlanningPlugin.Planners.Simple 5 | { 6 | public class SimplePlanningParameters : IPlanningParameters 7 | { 8 | public IAresPlanningRequest GenerateRequest() 9 | { 10 | var request = new SimplePlanningRequest(); 11 | var parameters = new SamplePlanningParameters(); 12 | request.Experiments.Add(parameters); 13 | return request; 14 | } 15 | 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /ARES_OS.sln.DotSettings: -------------------------------------------------------------------------------- 1 | 2 | <data><IncludeFilters /><ExcludeFilters /></data> 3 | <data /> -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/IDeviceScriptData.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ARESCore.Experiment.Scripting; 7 | 8 | namespace ARESCore.DeviceSupport 9 | { 10 | public interface IDeviceScriptData 11 | { 12 | string ExpScript { get; set; } 13 | string InterExpScript { get; set; } 14 | string CampaignCloseScript { get; set; } 15 | 16 | string DefaultExpScript(); 17 | string DefaultCampaignCloseScript(); 18 | string DefaultInterExpScript(); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/UI/Control/SampleDeviceControlView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows.Input; 2 | 3 | namespace AresSampleDevicesPlugin.SampleDevice.UI.Control 4 | { 5 | 6 | public partial class SampleDeviceControlView 7 | { 8 | public SampleDeviceControlView() 9 | { 10 | InitializeComponent(); 11 | } 12 | 13 | private void NumericUpDownKeyDown(object sender, KeyEventArgs e) 14 | { 15 | if (e.Key == Key.Enter) 16 | { 17 | (DataContext as SampleDeviceControlViewModel).CommitDoubleValue(); 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ARESCore/Commands/IAresCommand.cs: -------------------------------------------------------------------------------- 1 | using System.Threading.Tasks; 2 | using ARESCore.DisposePatternHelpers; 3 | 4 | namespace ARESCore.Commands 5 | { 6 | public interface IAresCommand : IReactiveSubscriber 7 | { 8 | string ScriptName { get; } 9 | 10 | int ArgCount { get; } 11 | 12 | bool ArgCountEnforced { get; } 13 | 14 | string HelpString { get; } 15 | 16 | bool Validate( string[] args ); 17 | 18 | bool IsPlannable { get; set; } 19 | 20 | string PlanValueString { get; set; } 21 | string CloserCmd { get; } 22 | 23 | Task Execute( string[] args ); 24 | 25 | } 26 | } -------------------------------------------------------------------------------- /ARESCore/UI/Helpers/UIHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows; 5 | using System.Windows.Media; 6 | 7 | namespace ARESCore.UI.Helpers 8 | { 9 | public static class UIHelper 10 | { 11 | public static T FindAncestorOrSelf( DependencyObject obj ) where T : DependencyObject 12 | { 13 | while ( obj != null ) 14 | { 15 | T objTest = obj as T; 16 | if ( objTest != null ) 17 | return objTest; 18 | obj = VisualTreeHelper.GetParent( obj ); 19 | } 20 | return null; 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /ARESCore/UI/Views/AppKiller.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows; 5 | using MahApps.Metro.Controls; 6 | 7 | namespace ARESCore.UI.Views 8 | { 9 | /// 10 | /// Interaction logic for AppKiller.xaml 11 | /// 12 | public partial class AppKiller : MetroWindow 13 | { 14 | public AppKiller() 15 | { 16 | InitializeComponent(); 17 | } 18 | 19 | protected override void OnContentRendered( EventArgs e ) 20 | { 21 | Close(); 22 | Application.Current.Shutdown(); 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /ARESCore/UI/ViewModels/AresSplashScreenViewModel.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using Ninject; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.UI.ViewModels 6 | { 7 | public class AresSplashScreenViewModel : ReactiveSubscriber 8 | { 9 | public AresSplashScreenViewModel() 10 | { 11 | Status = AresKernel._kernel.Get(); 12 | Status.StatusInfo = "Initializing..."; 13 | } 14 | private ILoadingStatus _status; 15 | 16 | public ILoadingStatus Status 17 | { 18 | get => _status; 19 | set => this.RaiseAndSetIfChanged(ref _status, value); 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/impl/CommandExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using ReactiveUI; 2 | 3 | namespace ARESCore.Experiment.Results.impl 4 | { 5 | public class CommandExecutionSummary : ExecutionSummary, ICommandExecutionSummary 6 | { 7 | private string _value = string.Empty; 8 | private string _command = string.Empty; 9 | 10 | public string Command 11 | { 12 | get => _command; 13 | set => this.RaiseAndSetIfChanged( ref _command, value ); 14 | } 15 | 16 | public string Value 17 | { 18 | get => _value; 19 | set => this.RaiseAndSetIfChanged( ref _value, value ); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /ARESCore/Configurations/IConfigManager.cs: -------------------------------------------------------------------------------- 1 | using System.Reactive; 2 | using System.Windows; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.Configurations 6 | { 7 | public interface IConfigManager 8 | { 9 | FrameworkElement AppConfigView { get; set; } 10 | 11 | FrameworkElement UserConfigView { get; set; } 12 | 13 | IUserDeviceConfig UserDeviceConfig { get; set; } 14 | 15 | IAppDeviceConfig AppConfig { get; set; } 16 | 17 | string DeviceName { get; set; } 18 | ReactiveCommand SaveUserConfigCommand { get; set; } 19 | 20 | void LoadConfigs(); 21 | 22 | void SaveUserConfig(); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/StepResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel.DataAnnotations; 3 | using System.ComponentModel.DataAnnotations.Schema; 4 | using System.Linq; 5 | using DynamicData.Annotations; 6 | 7 | namespace ARESCore.Database.Tables 8 | { 9 | [Table( "StepResults", Schema = "public" )] 10 | public class ScriptStepResultEntity 11 | { 12 | [Key] 13 | public Guid Id { get; set; } 14 | 15 | public DateTime Started { get; set; } = DateTime.MaxValue; 16 | 17 | public TimeSpan Runtime { get; set; } = TimeSpan.Zero; 18 | 19 | public Guid StepId { get; set; } = Guid.Empty; 20 | 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/IPAddressPortView.xaml.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.UI.Helpers; 2 | using MahApps.Metro.Controls; 3 | using System.Windows; 4 | 5 | namespace ARESCore.UI.Views 6 | { 7 | /// 8 | /// Interaction logic for IPAddressPortView.xaml 9 | /// 10 | public partial class IPAddressPortView : MetroWindow, IClosable 11 | { 12 | public IPAddressPortView() 13 | { 14 | InitializeComponent(); 15 | WindowStartupLocation = WindowStartupLocation.CenterScreen; 16 | } 17 | 18 | private void OkClicked(object sender, RoutedEventArgs e) 19 | { 20 | DialogResult = true; 21 | this.Close(); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /ARESCore/AnalysisSupport/CustomAnalysisDbFilter.xaml: -------------------------------------------------------------------------------- 1 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/EditTabView.xaml: -------------------------------------------------------------------------------- 1 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/Settings/SettingsWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.UI.Converters; 2 | using MahApps.Metro.Controls; 3 | using MahApps.Metro.IconPacks; 4 | using System.Windows; 5 | 6 | namespace ARESCore.UI.Views.Settings 7 | { 8 | /// 9 | /// Interaction logic for SettingsWindow.xaml 10 | /// 11 | public partial class SettingsWindow : MetroWindow 12 | { 13 | public SettingsWindow() 14 | { 15 | InitializeComponent(); 16 | } 17 | 18 | private void SettingsWindowLoaded(object sender, RoutedEventArgs e) 19 | { 20 | this.Icon = IconConverter.Convert(PackIconMaterialKind.ApplicationSettings); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /AresSampleAnalysisPlugin/AresSampleAnalysisPlugin.csproj.user: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Code 7 | 8 | 9 | 10 | 11 | Designer 12 | 13 | 14 | Designer 15 | 16 | 17 | -------------------------------------------------------------------------------- /ARESCore/DataHub/impl/DataHubEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ARESCore.DataHub.impl 4 | { 5 | public class DataHubEntry : IDataHubEntry 6 | { 7 | public Type DataType { get; set; } 8 | public object Data { get; set; } 9 | public string Source { get; set; } 10 | 11 | public DataHubEntry() 12 | { 13 | 14 | } 15 | 16 | public DataHubEntry(Type dataType, object data) 17 | { 18 | DataType = dataType; 19 | Data = data; 20 | } 21 | 22 | public DataHubEntry(Type dataType, object data, string dataSource) 23 | { 24 | DataType = dataType; 25 | Data = data; 26 | Source = dataSource; 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /ARESCore/Experiment/impl/ARESExperimentBatch.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.AnalysisSupport; 2 | using ARESCore.PlanningSupport; 3 | 4 | namespace ARESCore.Experiment.impl 5 | { 6 | public class ARESExperimentBatch : IExperimentBatch 7 | { 8 | public IPlannedExperimentBatchInputs Inputs { get { return BatchInputs; } set { } } 9 | public IAresAnalyzer Analyzer { get; set; } 10 | public IPlannedExperimentBatchInputs BatchInputs { get; set; } = new PlannedExperimentBatchInputs(); 11 | public IAresPlannerManager PlannerManager { get; set; } = null; 12 | 13 | 14 | public ARESExperimentBatch() 15 | { 16 | Inputs = null; 17 | } 18 | 19 | 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/IAresDevice.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.ObjectModel; 2 | using ARESCore.PluginSupport; 3 | using Prism.Ioc; 4 | 5 | namespace ARESCore.DeviceSupport 6 | { 7 | public interface IAresDevice: IAresPlugin 8 | { 9 | void Init(); 10 | void Activate(); 11 | string Name { get; set; } 12 | IAresDeviceState CurrentState { get; set; } 13 | IAresDeviceState TargetState { get; set; } 14 | void IssueCommand( IAresDeviceCommand command); 15 | void RegisterCommands( IContainerRegistry registry ); 16 | string GetSampleScriptEntry(); 17 | int ReadRate { get; set; } 18 | string Validate(); 19 | bool Connected { get; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/AresNotifier.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows; 5 | using System.Windows.Controls; 6 | using ARESCore.UI.ViewModels; 7 | 8 | namespace ARESCore.UI.Views 9 | { 10 | /// 11 | /// Interaction logic for AresNotification.xaml 12 | /// 13 | public partial class AresNotifier : UserControl 14 | { 15 | public AresNotifier() 16 | { 17 | InitializeComponent(); 18 | } 19 | 20 | private void ButtonBase_OnClick( object sender, RoutedEventArgs e ) 21 | { 22 | ( DataContext as AresNotifierViewModel ).FinishInteraction(); 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/GenericDbRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Data.Entity; 4 | using System.Linq; 5 | using ARESCore.Database.Management.Impl; 6 | 7 | namespace ARESCore.Database.Tables 8 | { 9 | public class GenericDbRepository where T : class 10 | { 11 | internal AresContext _context; 12 | internal DbSet _dbSet; 13 | 14 | public GenericDbRepository(AresContext context) 15 | { 16 | _context = context; 17 | _dbSet = _context.Set(); 18 | } 19 | 20 | public virtual void Insert(T entity) 21 | { 22 | _dbSet.Add( entity ); 23 | _context.SaveChanges(); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/AppKiller.xaml: -------------------------------------------------------------------------------- 1 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /ARESCore/DisposePatternHelpers/IBasicDisposable.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace ARESCore.DisposePatternHelpers 6 | { 7 | /// 8 | /// Interface definition for classes which must implement . Rather than simply using 9 | /// the built in interface, this is provided to encourage the use of 10 | /// and abstract classes which implement 11 | /// properly and provide additional debugging assistance. 12 | /// 13 | public interface IBasicDisposable : IDisposable 14 | { 15 | 16 | } 17 | } -------------------------------------------------------------------------------- /ARESCore/Database/Management/Impl/NpgSqlConfiguration.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Data.Entity; 4 | using System.Linq; 5 | using Npgsql; 6 | 7 | namespace ARESCore.Database.Management.Impl 8 | { 9 | public class NpgSqlConfiguration : DbConfiguration 10 | { 11 | public NpgSqlConfiguration() 12 | { 13 | var name = "Npgsql"; 14 | 15 | SetProviderFactory( providerInvariantName: name, providerFactory: NpgsqlFactory.Instance ); 16 | 17 | SetProviderServices( providerInvariantName: name, provider: NpgsqlServices.Instance ); 18 | 19 | SetDefaultConnectionFactory( connectionFactory: new NpgsqlConnectionFactory() ); 20 | 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ARESCore/UI/ViewModels/Settings/UserPreferencesViewModel.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using ARESCore.Registries; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.UI.ViewModels.Settings 6 | { 7 | public class UserPreferencesViewModel: ReactiveSubscriber 8 | { 9 | private IConfigManagerRegistry _registry; 10 | 11 | public UserPreferencesViewModel( IConfigManagerRegistry registry) 12 | { 13 | Registry = registry; 14 | } 15 | 16 | public UserPreferencesViewModel() 17 | { 18 | } 19 | 20 | public IConfigManagerRegistry Registry 21 | { 22 | get => _registry; 23 | set => this.RaiseAndSetIfChanged( ref _registry, value ); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ARESCore/Configurations/IApplicationConfiguration.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Collections.ObjectModel; 3 | using ARESCore.DisposePatternHelpers; 4 | using ARESCore.UserSession; 5 | 6 | namespace ARESCore.Configurations 7 | { 8 | public interface IApplicationConfiguration : IReactiveSubscriber 9 | { 10 | void SetDefaults(); 11 | void LoadConfig(string configPath); 12 | bool SaveConfig(string configPath); 13 | string ApplicationRootDirectory { get; set; } 14 | string CurrentAppConfigPath { get; set; } 15 | ObservableCollection UserList { get; set; } 16 | List ProjectList { get; set; } 17 | void RemoveUser( IUserInfo userInfo ); 18 | } 19 | } -------------------------------------------------------------------------------- /ARESCore/Experiment/Experiment.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ComponentModel.DataAnnotations; 3 | using System.ComponentModel.DataAnnotations.Schema; 4 | using DynamicData.Annotations; 5 | 6 | namespace ARESCore.Experiment 7 | { 8 | [Table( "Experiments", Schema = "public" )] 9 | public class Experiment 10 | { 11 | [Key] 12 | public Guid Id { get; set; } 13 | 14 | public DateTime TimeStamp { get; set; } 15 | 16 | [CanBeNull] 17 | public string Project { get; set; } 18 | [CanBeNull] 19 | public string OriginalWorkingFolder { get; set; } 20 | 21 | public bool Imported { get; set; } = false; 22 | [CanBeNull] 23 | public string Notes { get; set; } 24 | 25 | 26 | 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/impl/ExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ARESCore.DisposePatternHelpers; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.Experiment.Results.impl 6 | { 7 | public abstract class ExecutionSummary : ReactiveSubscriber, IExecutionSummary 8 | { 9 | private TimeSpan _executionDuration; 10 | private ExecutionStatus _status = ExecutionStatus.PENDING; 11 | 12 | public TimeSpan ExecutionDuration 13 | { 14 | get => _executionDuration; 15 | set => this.RaiseAndSetIfChanged( ref _executionDuration, value ); 16 | } 17 | 18 | public ExecutionStatus Status 19 | { 20 | get => _status; 21 | set => this.RaiseAndSetIfChanged( ref _status, value ); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/IAresPlanner.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | using ARESCore.Database.Tables; 4 | using ARESCore.DisposePatternHelpers; 5 | using ARESCore.Experiment; 6 | 7 | namespace ARESCore.PlanningSupport 8 | { 9 | public interface IAresPlanner : IReactiveSubscriber 10 | { 11 | int NumExperimentsToPlan { get; set; } 12 | Task DoPlanning(); 13 | 14 | List PlanningDatabase { get; set; } 15 | 16 | IPlannerStatus PlannerStatus { get; set; } 17 | bool CanPlan { get; set; } 18 | IPlannedExperimentBatchInputs SeedExperimentBatchInputs { get; set; } 19 | int RequiredNumberOfSeedExperiments { get; set; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/NullToBoolConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Globalization; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | using System.Windows.Data; 9 | 10 | namespace ARESCore.UI.Converters 11 | { 12 | public class NullToBoolConverter : IValueConverter 13 | { 14 | public object Convert( object value, Type targetType, object parameter, CultureInfo culture ) 15 | { 16 | if(value == null) 17 | return false; 18 | return true; 19 | } 20 | 21 | public object ConvertBack( object value, Type targetType, object parameter, CultureInfo culture ) 22 | { 23 | return true; 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/Impl/PlannerStatus.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | using ARESCore.DisposePatternHelpers; 6 | using ReactiveUI; 7 | 8 | namespace ARESCore.PlanningSupport.Impl 9 | { 10 | internal class PlannerStatus : ReactiveSubscriber, IPlannerStatus 11 | { 12 | private string _statusText; 13 | private ContentControl _image; 14 | 15 | public string StatusText 16 | { 17 | get => _statusText; 18 | set => this.RaiseAndSetIfChanged( ref _statusText, value ); 19 | } 20 | 21 | public ContentControl Image 22 | { 23 | get => _image; 24 | set => this.RaiseAndSetIfChanged( ref _image, value ); 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /ARESCore/UI/Converters/NullToVisibilityConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Globalization; 4 | using System.Linq; 5 | using System.Windows; 6 | using System.Windows.Data; 7 | 8 | namespace ARESCore.UI.Converters 9 | { 10 | public class NullToVisibilityConverter : IValueConverter 11 | { 12 | public object Convert( object value, Type targetType, object parameter, CultureInfo culture ) 13 | { 14 | if ( value == null ) 15 | return Visibility.Collapsed; 16 | return Visibility.Visible; 17 | } 18 | 19 | public object ConvertBack( object value, Type targetType, object parameter, CultureInfo culture ) 20 | { 21 | throw new NotImplementedException(); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /ARESCore/Util/JsonTypeConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Newtonsoft.Json; 7 | 8 | namespace ARESCore.Util 9 | { 10 | public class JsonTypeConverter : JsonConverter 11 | { 12 | public override bool CanConvert( Type objectType ) => true; 13 | 14 | public override object ReadJson( JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer ) 15 | { 16 | return serializer.Deserialize( reader ); 17 | } 18 | 19 | public override void WriteJson( JsonWriter writer, object value, JsonSerializer serializer ) 20 | { 21 | serializer.Serialize( writer, value ); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /ARESCore/PlanningSupport/IAresPlannerManager.cs: -------------------------------------------------------------------------------- 1 | using System.Threading.Tasks; 2 | using System.Windows.Controls; 3 | using ARESCore.DisposePatternHelpers; 4 | using ARESCore.Experiment; 5 | using ARESCore.PluginSupport; 6 | 7 | namespace ARESCore.PlanningSupport 8 | { 9 | public interface IAresPlannerManager : IAresPlugin, IReactiveSubscriber 10 | { 11 | string PlannerName { get; set; } 12 | UserControl PlannerTile { get; set; } 13 | 14 | IPlanningParameters PlanningParameters { get; set; } 15 | int NumExpsToPlan { get; set; } 16 | 17 | Task DoPlanning(); 18 | IPlanningParameters TryParse( string currentDesc, string lineToken, bool tokenHasValue ); 19 | IAresPlanner Planner { get; } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/LicenseWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Linq; 5 | using System.Windows; 6 | using System.Windows.Media; 7 | using System.Windows.Media.Imaging; 8 | using ARESCore.UI.Converters; 9 | using MahApps.Metro.Controls; 10 | using MahApps.Metro.IconPacks; 11 | 12 | namespace ARESCore.UI.Views 13 | { 14 | /// 15 | /// Interaction logic for SettingsWindow.xaml 16 | /// 17 | public partial class LicenseWindow : MetroWindow 18 | { 19 | private void CloseWindow(object sender, RoutedEventArgs e) 20 | { 21 | Close(); 22 | } 23 | public LicenseWindow() 24 | { 25 | InitializeComponent(); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/UI/BooleanToStringConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows.Data; 4 | 5 | namespace AresSampleDevicesPlugin.SampleDevice.UI 6 | { 7 | public class BooleanToStringConverter : IValueConverter 8 | { 9 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 10 | { 11 | if (!(value is bool)) 12 | return "Make this True"; 13 | if ((bool)value) 14 | return "Make this False"; 15 | return "Make this True"; 16 | } 17 | 18 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 19 | { 20 | throw new NotImplementedException(); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ARESCore/Experiment/UI/ViewModels/BatchResultsViewModel.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using ARESCore.Experiment.Results; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.Experiment.UI.ViewModels 6 | { 7 | public class BatchResultsViewModel : ReactiveSubscriber 8 | { 9 | private ICampaignExecutionSummary _campaignExecutionSummary; 10 | 11 | public BatchResultsViewModel( ICampaignExecutionSummary campaignExecutionSummary ) 12 | { 13 | CampaignExecutionSummary = campaignExecutionSummary; 14 | } 15 | 16 | public ICampaignExecutionSummary CampaignExecutionSummary 17 | { 18 | get => _campaignExecutionSummary; 19 | set => this.RaiseAndSetIfChanged( ref _campaignExecutionSummary, value ); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /ARESSampleDevicesPlugin/SampleDevice/Config/SampleDeviceConfigManager.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Configurations.impl; 2 | using AresSampleDevicesPlugin.SampleDevice.UI.Config; 3 | 4 | namespace AresSampleDevicesPlugin.SampleDevice.Config 5 | { 6 | public class SampleDeviceConfigManager : ConfigManager, ISampleDeviceConfigManager 7 | { 8 | 9 | public SampleDeviceConfigManager(ISampleDeviceUserDeviceConfig userConfig, ISampleDeviceAppConfig appConfig, SampleDeviceUserConfigView userConfigView, SampleDeviceAppConfigView appConfigView) 10 | { 11 | UserDeviceConfig = userConfig; 12 | AppConfig = appConfig; 13 | UserConfigView = userConfigView; 14 | AppConfigView = appConfigView; 15 | DeviceName = "Sample Device"; 16 | 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /ARESCore/Commands/AresCommandPopulator.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.Experiment.Scripting.Commands; 2 | using ARESCore.Registries; 3 | using Ninject; 4 | 5 | namespace ARESCore.Commands 6 | { 7 | internal class AresCommandPopulator : IAresCommandPopulator 8 | { 9 | public void Populate() 10 | { 11 | var repo = AresKernel._kernel.Get(); 12 | var sec = new StepEndCommand(); 13 | var sspc = AresKernel._kernel.Get(); 14 | var sssc = AresKernel._kernel.Get(); 15 | var wc = new WaitCommand(); 16 | var dc = new DelayCommand(); 17 | repo.Add(sec); 18 | repo.Add(sspc); 19 | repo.Add(sssc); 20 | repo.Add(wc); 21 | repo.Add(dc); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IExperimentFilter.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Data.Entity; 3 | using System.Linq; 4 | using ARESCore.Database.Filtering.Impl; 5 | using ARESCore.Database.Tables; 6 | 7 | namespace ARESCore.Database.Filtering 8 | { 9 | interface IExperimentFilter: IDbFilter 10 | { 11 | List FilterExperiments( FilterOptions opts ); 12 | IQueryable FilterExperimentsOnPlans( FilterOptions opts, IQueryable initExps ); 13 | IQueryable FilterExperimentsOnMachine( FilterOptions opts, IQueryable initSet ); 14 | IQueryable FilterExperimentsOnData( FilterOptions opts, IQueryable initSet ); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/ExportTabView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Data; 9 | using System.Windows.Documents; 10 | using System.Windows.Input; 11 | using System.Windows.Media; 12 | using System.Windows.Media.Imaging; 13 | using System.Windows.Navigation; 14 | using System.Windows.Shapes; 15 | 16 | namespace ARESCore.Database.Views 17 | { 18 | /// 19 | /// Interaction logic for ExportTabView.xaml 20 | /// 21 | public partial class ExportTabView : UserControl 22 | { 23 | public ExportTabView() 24 | { 25 | InitializeComponent(); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/UI/ViewModels/AresNotifierViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using Prism.Interactivity.InteractionRequest; 5 | using Prism.Mvvm; 6 | 7 | namespace ARESCore.UI.ViewModels 8 | { 9 | public class AresNotifierViewModel: BindableBase, IInteractionRequestAware 10 | { 11 | private INotification _notification; 12 | 13 | public INotification Notification 14 | { 15 | get { return _notification; } 16 | set 17 | { 18 | if ( value is AresNotification ) 19 | { 20 | _notification = (AresNotification)value; 21 | RaisePropertyChanged( nameof(Notification) ); 22 | } 23 | } 24 | } 25 | 26 | public Action FinishInteraction { get; set; } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/FilterTabView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows.Controls; 5 | using ARESCore.Configurations; 6 | using ARESCore.Database.ViewModels; 7 | 8 | namespace ARESCore.Database.Views 9 | { 10 | /// 11 | /// Interaction logic for FilterTabView.xaml 12 | /// 13 | public partial class FilterTabView : UserControl 14 | { 15 | public FilterTabView() 16 | { 17 | InitializeComponent(); 18 | } 19 | 20 | private void ListViewSelectionChanged( object sender, SelectionChangedEventArgs e ) 21 | { 22 | var vm = (FilterTabViewModel)DataContext; 23 | vm.SelectedProjects = _listView.SelectedItems.Cast().ToList(); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ARESCore/UI/Views/Settings/FilesAndUsers.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Data; 9 | using System.Windows.Documents; 10 | using System.Windows.Input; 11 | using System.Windows.Media; 12 | using System.Windows.Media.Imaging; 13 | using System.Windows.Navigation; 14 | using System.Windows.Shapes; 15 | 16 | namespace ARESCore.UI.Views.Settings 17 | { 18 | /// 19 | /// Interaction logic for FilesAndSettings.xaml 20 | /// 21 | public partial class FilesAndUsers : UserControl 22 | { 23 | public FilesAndUsers() 24 | { 25 | InitializeComponent(); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/Database/Tables/InnerContent/ExperimentData.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Linq; 3 | using DynamicData.Annotations; 4 | 5 | namespace ARESCore.Database.Tables.InnerContent 6 | { 7 | public class ExperimentData 8 | { 9 | [CanBeNull] 10 | public string InternalDescs { get; set; } 11 | 12 | public string[] Descs 13 | { 14 | get => InternalDescs.Split( ';' ); 15 | set => InternalDescs = string.Join( ";", value ); 16 | } 17 | 18 | [CanBeNull] 19 | public string InternalData { get; set; } 20 | 21 | public double[] Data 22 | { 23 | get { return Array.ConvertAll( InternalData.Split( ';' ), v => double.Parse( v ) ); } 24 | set { InternalData = string.Join( ";", value.Select( p => p.ToString() ).ToArray() ); } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /ARESCore/UserSession/Impl/UserSessionFactory.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.UI; 2 | using Newtonsoft.Json; 3 | using Ninject; 4 | using System; 5 | using System.IO; 6 | 7 | namespace ARESCore.UserSession.Impl 8 | { 9 | public class UserSessionFactory : IUserSessionFactory 10 | { 11 | public IUserSession CreateSession(string sessionPath) 12 | { 13 | if (File.Exists(sessionPath)) 14 | { 15 | try 16 | { 17 | string sessionJson = File.ReadAllText(sessionPath); 18 | return JsonConvert.DeserializeObject(sessionJson); 19 | } 20 | catch (Exception ex) 21 | { 22 | AresKernel._kernel.Get().WriteLine(ex.Message); 23 | return null; 24 | } 25 | } 26 | return null; 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /ARESCore/Configurations/ISerialPortConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO.Ports; 4 | using System.Linq; 5 | using ARESCore.DisposePatternHelpers; 6 | 7 | namespace ARESCore.Configurations 8 | { 9 | public interface ISerialPortConfig : IReactiveSubscriber 10 | { 11 | int MaxWaitTries { get; set; } 12 | int DataBits { get; set; } 13 | int BaudRate { get; set; } 14 | Parity Parity { get; set; } 15 | int ReadTimeout { get; set; } 16 | string PortName { get; set; } 17 | StopBits StopBits { get; set; } 18 | int ReadBufferSize { get; set; } 19 | 20 | void SetSerialFields( string portName, int dataBits, int baudRate, Parity parity, StopBits stopBits, int readBufferSize, int maxWaits = 100, int readTimeout = 180 ); 21 | 22 | 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Scripting/Commands/StepEndCommand.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace ARESCore.Experiment.Scripting.Commands 7 | { 8 | public class StepEndCommand : AresScriptCommand 9 | { 10 | public override string ScriptName { get; } = "STEP_END"; 11 | public override int ArgCount { get; } = 0; 12 | public override string HelpString { get; } = "Denotes the end of a step."; 13 | 14 | public override bool Validate( string[] args ) 15 | { 16 | if ( args.Length > 0 ) 17 | return false; 18 | return true; 19 | } 20 | 21 | public override Task Execute(string[] lines) 22 | { 23 | // do nothing? 24 | return Task.FromResult( 0 ); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /AresSampleAnalysisPlugin/Analyzers/Sample/Ui/Views/SampleAnalyzerView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | using System.Windows.Controls; 3 | using AresSampleAnalysisPlugin.Analyzers.Sample.Ui.Vms; 4 | 5 | namespace AresSampleAnalysisPlugin.Analyzers.Sample.Ui.Views 6 | { 7 | /// 8 | /// Interaction logic for SampleAnalyzerView.xaml 9 | /// 10 | public partial class SampleAnalyzerView 11 | { 12 | public SampleAnalyzerView() 13 | { 14 | InitializeComponent(); 15 | } 16 | 17 | private void SampleAnalyzerView_OnLoaded(object sender, RoutedEventArgs e) 18 | { 19 | var vm = DataContext as SampleAnalyzerViewModel; 20 | if (vm.SamplePlot == null) 21 | { 22 | vm.SamplePlot = SamplePlot; 23 | vm.Setup(); 24 | } 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /ARESCore/AnalysisSupport/CustomAnalysisDbFilter.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Data; 9 | using System.Windows.Documents; 10 | using System.Windows.Input; 11 | using System.Windows.Media; 12 | using System.Windows.Media.Imaging; 13 | using System.Windows.Navigation; 14 | using System.Windows.Shapes; 15 | 16 | namespace ARESCore.AnalysisSupport 17 | { 18 | /// 19 | /// Interaction logic for CustomAnalysisDbFilter.xaml 20 | /// 21 | public partial class CustomAnalysisDbFilter : UserControl 22 | { 23 | public CustomAnalysisDbFilter() 24 | { 25 | InitializeComponent(); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/DeviceSupport/Usb/UsbDeviceView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Data; 9 | using System.Windows.Documents; 10 | using System.Windows.Input; 11 | using System.Windows.Media; 12 | using System.Windows.Media.Imaging; 13 | using System.Windows.Navigation; 14 | using System.Windows.Shapes; 15 | 16 | namespace ARESCore.DeviceSupport.Usb 17 | { 18 | /// 19 | /// Interaction logic for UsbDeviceView.xaml 20 | /// 21 | public partial class UsbDeviceView : UserControl 22 | { 23 | public UsbDeviceView() 24 | { 25 | InitializeComponent(); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/UI/LoadingStatus.cs: -------------------------------------------------------------------------------- 1 | using ARESCore.DisposePatternHelpers; 2 | using MahApps.Metro.IconPacks; 3 | using ReactiveUI; 4 | using System.Windows; 5 | 6 | namespace ARESCore.UI 7 | { 8 | internal class LoadingStatus : ReactiveSubscriber, ILoadingStatus 9 | { 10 | private string _statusInfo; 11 | private PackIconMaterialKind _iconKind = PackIconMaterialKind.Cookie; 12 | 13 | public string StatusInfo 14 | { 15 | get => _statusInfo; 16 | set => Application.Current.Dispatcher.Invoke(delegate () { this.RaiseAndSetIfChanged(ref _statusInfo, value); }); 17 | } 18 | 19 | public PackIconMaterialKind Icon 20 | { 21 | get => _iconKind; 22 | set => Application.Current.Dispatcher.Invoke(delegate () { this.RaiseAndSetIfChanged(ref _iconKind, value); }); 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/Impl/DbContextExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Data.Entity; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace ARESCore.Database.Management.Impl 9 | { 10 | public static class DbContextExtensions 11 | { 12 | public static IEnumerable SetOf( this DbContext dbContext ) where T : class 13 | { 14 | List types = new List(); 15 | foreach ( var assembly in AppDomain.CurrentDomain.GetAssemblies() ) 16 | { 17 | types.AddRange( assembly.GetTypes() ); 18 | } 19 | return types.Where( type => typeof( T ).IsAssignableFrom( type ) && !type.IsInterface ) 20 | .SelectMany( t => Enumerable.Cast( dbContext.Set( t ) )); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/StringCompareConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows.Data; 4 | 5 | namespace ARESCore.UI.Converters 6 | { 7 | public class StringCompareConverter : IMultiValueConverter 8 | { 9 | public object Convert( object[] values, Type targetType, object parameter, CultureInfo culture ) 10 | { 11 | if ( values.Length != 2 ) 12 | { 13 | return false; 14 | } 15 | 16 | if ( !( values[0] is string str1 ) || !( values[1] is string str2 ) ) 17 | { 18 | return false; 19 | } 20 | 21 | return str1.Equals( str2 ); 22 | } 23 | 24 | public object[] ConvertBack( object value, Type[] targetTypes, object parameter, CultureInfo culture ) 25 | { 26 | return value as object[]; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /ARESCore/Database/Views/DatabaseView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Windows; 5 | using ARESCore.UI.Converters; 6 | using MahApps.Metro.Controls; 7 | using MahApps.Metro.IconPacks; 8 | 9 | namespace ARESCore.Database.Views 10 | { 11 | /// 12 | /// Interaction logic for DatabaseView.xaml 13 | /// 14 | public partial class DatabaseView : MetroWindow 15 | { 16 | public DatabaseView() 17 | { 18 | InitializeComponent(); 19 | } 20 | 21 | private void DatabaseViewLoaded( object sender, RoutedEventArgs e ) 22 | { 23 | Icon = IconConverter.Convert( PackIconMaterialKind.Database ); 24 | } 25 | 26 | private void ButtonBase_OnClick( object sender, RoutedEventArgs e ) 27 | { 28 | this.Close(); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /ARESCore/Experiment/impl/ExperimentBatchRunner_Base.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using ARESCore.DisposePatternHelpers; 6 | 7 | namespace ARESCore.Experiment.impl 8 | { 9 | public abstract class ExperimentBatchRunner_Base : ReactiveSubscriber 10 | { 11 | private IExperimentBatch _experimentBatch; 12 | 13 | public ExperimentBatchRunner_Base(IExperimentBatch expBatch) 14 | { 15 | ExperimentBatch = expBatch; 16 | } 17 | 18 | public abstract Task RunExperimentBatchAsync(int expIndexStart, int batchSize); 19 | 20 | public IExperimentBatch ExperimentBatch 21 | { 22 | get { return _experimentBatch; } 23 | protected set { _experimentBatch = value; } 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ARESCore/UI/Helpers/DialogCloser.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | 3 | namespace ARESCore.UI.Helpers 4 | { 5 | public static class DialogCloser 6 | { 7 | public static readonly DependencyProperty DialogResultProperty = 8 | DependencyProperty.RegisterAttached( 9 | "DialogResult", 10 | typeof(bool?), 11 | typeof(DialogCloser), 12 | new PropertyMetadata(DialogResultChanged)); 13 | 14 | private static void DialogResultChanged( 15 | DependencyObject d, 16 | DependencyPropertyChangedEventArgs e) 17 | { 18 | var window = d as Window; 19 | if (window != null) 20 | window.DialogResult = e.NewValue as bool?; 21 | } 22 | public static void SetDialogResult(Window target, bool? value) 23 | { 24 | target.SetValue(DialogResultProperty, value); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/impl/CampaignExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using DynamicData.Binding; 3 | using ReactiveUI; 4 | 5 | namespace ARESCore.Experiment.Results.impl 6 | { 7 | public class CampaignExecutionSummary : ExecutionSummary, ICampaignExecutionSummary 8 | { 9 | private TimeSpan _etc; 10 | private ObservableCollectionExtended _experimentResults = new ObservableCollectionExtended(); 11 | 12 | public TimeSpan ETC 13 | { 14 | get => _etc; 15 | set => this.RaiseAndSetIfChanged( ref _etc, value ); 16 | } 17 | 18 | public ObservableCollectionExtended ExperimentExecutionSummaries 19 | { 20 | get => _experimentResults; 21 | set => this.RaiseAndSetIfChanged( ref _experimentResults, value ); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /ARESCore/Experiment/CampaignCanRunMask.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.Experiment 2 | { 3 | public enum CampaignCanRunMask 4 | { 5 | // Valid values should be "OR"ed ( | ) and Invalid values should be "AND"ed ( & ) 6 | 7 | // LSB 8 | Planner = 0b1, 9 | NoPlanner = 0b11111110, 10 | // 7th bit 11 | Experiments = 0b10, 12 | NoExperiments = 0b11111101, 13 | // 6th bit 14 | ValidExperimentScript = 0b100, 15 | InvalidExperimentScript = 0b11111011, 16 | // 5th bit 17 | PlanResults = 0b1000, 18 | NoPlanResults = 0b11110111, 19 | // 4th bit 20 | ValidInterScript = 0b10000, 21 | InvalidInterScript = 0b11101111, 22 | // 3rd bit 23 | ValidCloseScript = 0b100000, 24 | InvalidCloseScript = 0b11011111, 25 | // 2nd bit 26 | CampaignPending = 0b1000000, 27 | CampaignRunning = 0b10111111, 28 | // MSB 29 | 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/NegateBooleanConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Globalization; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | using System.Windows.Data; 9 | 10 | namespace ARESCore.UI.Converters 11 | { 12 | public class NegateBooleanConverter : IValueConverter 13 | { 14 | public object Convert( object value, Type targetType, object parameter, CultureInfo culture ) 15 | { 16 | bool flag = true; 17 | if ( value is bool ) 18 | flag = (bool)value; 19 | return !flag; 20 | } 21 | 22 | public object ConvertBack( object value, Type targetType, object parameter, CultureInfo culture ) 23 | { 24 | bool flag = true; 25 | if ( value is bool ) 26 | flag = (bool)value; 27 | return !flag; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /ARESCore/Util/UnitEnums.cs: -------------------------------------------------------------------------------- 1 | namespace ARESCore.Util 2 | { 3 | public enum Power 4 | { 5 | Watt, 6 | Milliwatt, 7 | Kilowatt 8 | } 9 | 10 | public enum Length 11 | { 12 | Meter, 13 | Centimeter, 14 | Millimeter, 15 | Micrometer, 16 | Nanometer 17 | } 18 | 19 | public enum FlowRate 20 | { 21 | SCCM, 22 | SLPM, 23 | ULMIN, 24 | ULHR, 25 | MLMIN, 26 | MLHR, 27 | MGHR 28 | } 29 | 30 | public enum Pressure 31 | { 32 | Torr, 33 | Pascal, 34 | Atmosphere, 35 | InHg 36 | } 37 | 38 | public enum Temperature 39 | { 40 | Celcius, 41 | Kelvin 42 | } 43 | 44 | public enum Concentration 45 | { 46 | PPM 47 | } 48 | 49 | public enum Volume 50 | { 51 | Milliliters, 52 | Microliters 53 | } 54 | 55 | public enum ElectricPotential 56 | { 57 | Volt 58 | } 59 | 60 | } -------------------------------------------------------------------------------- /ARESCore/ErrorSupport/UI/ErrorHandlingView.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Data; 9 | using System.Windows.Documents; 10 | using System.Windows.Input; 11 | using System.Windows.Media; 12 | using System.Windows.Media.Imaging; 13 | using System.Windows.Navigation; 14 | using System.Windows.Shapes; 15 | using Ninject; 16 | 17 | namespace ARESCore.ErrorSupport.UI 18 | { 19 | /// 20 | /// Interaction logic for ErrorHandlingView.xaml 21 | /// 22 | public partial class ErrorHandlingView : UserControl 23 | { 24 | public ErrorHandlingView() 25 | { 26 | InitializeComponent(); 27 | DataContext = AresKernel._kernel.Get(); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /ARESCore/Experiment/Results/impl/StepExecutionExecutionSummary.cs: -------------------------------------------------------------------------------- 1 | using DynamicData.Binding; 2 | using ReactiveUI; 3 | 4 | namespace ARESCore.Experiment.Results.impl 5 | { 6 | public class StepExecutionExecutionSummary : ExecutionSummary, IStepExecutionSummary 7 | { 8 | private ObservableCollectionExtended _commandExecutionSummaries = new ObservableCollectionExtended(); 9 | private string _stepName = string.Empty; 10 | 11 | public string StepName 12 | { 13 | get => _stepName; 14 | set => this.RaiseAndSetIfChanged( ref _stepName, value ); 15 | } 16 | 17 | public ObservableCollectionExtended CommandExecutionSummaries 18 | { 19 | get => _commandExecutionSummaries; 20 | set => this.RaiseAndSetIfChanged( ref _commandExecutionSummaries, value ); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/NegateBooleanToVisibilityConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Globalization; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | using System.Windows.Data; 9 | 10 | namespace ARESCore.UI.Converters 11 | { 12 | public sealed class NegateBooleanToVisibilityConverter : IValueConverter 13 | { 14 | public object Convert( object value, Type targetType, object parameter, CultureInfo culture ) 15 | { 16 | bool flag = false; 17 | if ( value is bool ) 18 | flag = (bool)value; 19 | return flag ? Visibility.Collapsed : Visibility.Visible; 20 | } 21 | 22 | public object ConvertBack( object value, Type targetType, object parameter, CultureInfo culture ) 23 | { 24 | return value as Visibility? == Visibility.Collapsed; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /AresSampleAnalysisPlugin/AresSampleAnalysisPlugin.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | true 5 | net5.0-windows 6 | true 7 | Debug;Release 8 | x64 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | $(DefaultXamlRuntime) 24 | Designer 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /ARESCore/Experiment/IPlannedExperimentBatchInputs.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using ARESCore.DisposePatternHelpers; 3 | using ARESCore.Experiment.impl; 4 | 5 | namespace ARESCore.Experiment 6 | { 7 | 8 | 9 | public interface IPlannedExperimentBatchInputs : IReactiveSubscriber 10 | { 11 | int Count(); 12 | bool HasInputs(); 13 | List PlannedInputs { get; } 14 | 15 | double GetInput(string desc, int expNum); 16 | void SetExperimentBatchInputs(List dataDesc, List> data); 17 | void SetExperimentBatchInputs(IEnumerable> experimentParameterEnums); 18 | void SetExperimentBatchInputs(IEnumerable plannedExperimentInputsEnum); 19 | 20 | void LoadInputsFromFile(string fileName, char delim = ','); 21 | IPlannedExperimentInputs GetExperimentInputs(int expNum); 22 | 23 | } 24 | } -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/Migrators/PointJsonConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Drawing; 3 | using Newtonsoft.Json; 4 | using Newtonsoft.Json.Linq; 5 | 6 | namespace ARESCore.TMPDbMigration.Migrators 7 | { 8 | public class PointJsonConverter : JsonConverter 9 | { 10 | public override void WriteJson( JsonWriter writer, object value, JsonSerializer serializer ) 11 | { 12 | throw new NotImplementedException(); 13 | } 14 | 15 | public override object ReadJson( JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer ) 16 | { 17 | var jPoint = JObject.Load( reader ); 18 | 19 | var x = jPoint["X"].Value(); 20 | var y = jPoint["Y"].Value(); 21 | return new Point( x, y ); 22 | } 23 | 24 | public override bool CanConvert( Type objectType ) 25 | { 26 | return objectType == typeof( Point ); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/EnumBoolConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Data; 8 | 9 | namespace ARESCore.UI.Converters 10 | { 11 | public class EnumBooleanConverter : IValueConverter 12 | { 13 | #region IValueConverter Members 14 | public object Convert( object value, Type targetType, object parameter, System.Globalization.CultureInfo culture ) 15 | { 16 | 17 | 18 | if ( Enum.IsDefined( value.GetType(), value ) == false ) 19 | return DependencyProperty.UnsetValue; 20 | 21 | return parameter.Equals( value ); 22 | } 23 | 24 | public object ConvertBack( object value, Type targetType, object parameter, System.Globalization.CultureInfo culture ) 25 | { 26 | return parameter; 27 | } 28 | #endregion 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /ARESCore/AnalysisSupport/IAresAnalyzer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Windows.Controls; 4 | using ARESCore.DisposePatternHelpers; 5 | using ARESCore.PluginSupport; 6 | 7 | namespace ARESCore.AnalysisSupport 8 | { 9 | public interface IAresAnalyzer : IAresPlugin, IReactiveSubscriber 10 | { 11 | List Headers { get; set; } 12 | 13 | UserControl AnalysisDbFilter { get; set; } 14 | string GetPostProcessOverview(IAresAnalyzer referenceProcess); 15 | void TrySet(string currentDesc, string lineToken); 16 | string Tokenize(string header); 17 | IEnumerable GetPrimaryAnalysisValues(); 18 | IEnumerable GetSecondaryAnalysisValues(); 19 | List> GetFilteredDataInRows(Type inputType); 20 | 21 | Type DbTypeSupported { get; } 22 | 23 | string AnalyzerName { get; set; } 24 | bool IsSelected { get; set; } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ARESCore/Configurations/IProjectInfo.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ARESCore.DisposePatternHelpers; 3 | using Newtonsoft.Json; 4 | 5 | namespace ARESCore.Configurations 6 | { 7 | public interface IProjectInfo: IReactiveSubscriber 8 | { 9 | [JsonProperty] 10 | string Creator { get; set; } 11 | [JsonProperty] 12 | string Description { get; set; } 13 | [JsonProperty] 14 | DateTime LastLoadedDate { get; set; } 15 | [JsonProperty] 16 | string SaveDirectory { get; set; } 17 | 18 | [JsonIgnore] 19 | string SaveDirectory_Scripts { get; } 20 | [JsonIgnore] 21 | string SaveDirectory_ExportedManualData { get; } 22 | [JsonIgnore] 23 | string SaveDirectory_ExportedPlanningDBs { get; } 24 | [JsonIgnore] 25 | string SaveDirectory_ExportedBatchData { get; } 26 | [JsonIgnore] 27 | string SaveDirectory_ExportedData { get; } 28 | bool CreateDirectories(); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /ARESCore/Database/Filtering/IExperimentFilterOptions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ARESCore.AnalysisSupport; 7 | using ARESCore.PlanningSupport; 8 | 9 | namespace ARESCore.Database.Filtering 10 | { 11 | public interface IExperimentFilterOptions: IFilterOptions 12 | { 13 | bool StrictFiltering { get; set; } 14 | bool FilterBatchType { get; set; } 15 | bool FilterProjectDescription { get; set; } 16 | bool FilterExperimentDate { get; set; } 17 | bool FilterPlannerType { get; set; } 18 | 19 | 20 | IAresAnalyzer BatchTypeFilter { get; set; } 21 | Type PostProcessingDataType { get; set; } 22 | List Projects { get; set; } 23 | DateTime FromDate { get; set; } 24 | DateTime ToDate { get; set; } 25 | IAresPlannerManager Planner { get; set; } 26 | 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/IconConverter.cs: -------------------------------------------------------------------------------- 1 | using System.Windows; 2 | using System.Windows.Media; 3 | using MahApps.Metro.IconPacks; 4 | 5 | namespace ARESCore.UI.Converters 6 | { 7 | public class IconConverter 8 | { 9 | public static ImageSource Convert( PackIconMaterialKind kind ) 10 | { 11 | var material = new PackIconMaterial() 12 | { 13 | Kind = kind, 14 | VerticalAlignment = VerticalAlignment.Center 15 | }; 16 | var brush = new SolidColorBrush( Colors.White ) 17 | ; var geometryDrawing = new GeometryDrawing 18 | { 19 | Geometry = Geometry.Parse( material.Data ), 20 | Brush = brush, 21 | Pen = new Pen( brush, 0.1 ) 22 | }; 23 | 24 | var drawingGroup = new DrawingGroup { Children = { geometryDrawing } }; 25 | 26 | var img = new DrawingImage { Drawing = drawingGroup }; 27 | 28 | return img; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /ARESCore/Database/Management/Impl/AresDbContextFactory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Data.Entity.Infrastructure; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using Ninject; 8 | using Npgsql; 9 | 10 | namespace ARESCore.Database.Management.Impl 11 | { 12 | public class AresDbContextFactory:IDbContextFactory 13 | { 14 | public AresContext Create() 15 | { 16 | // Admittedly this is a little funky. We need the config file, but we also MUST call the constructor with the args 17 | // since there isn't a property to set it later. Thus, this static call and some Ninject games in the module. 18 | var connstr = "Server=127.0.0.1;Port=5432;Database=aresdatabase;" + "User Id=postgres;Password=a"; 19 | var connection = new NpgsqlConnection( connstr ); 20 | return new AresContext( connection ); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ARESCore/UI/Converters/DoubleAdditionConverter.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Windows.Data; 4 | 5 | namespace ARESCore.UI.Converters 6 | { 7 | public class DoubleAdditionConverter : IValueConverter 8 | { 9 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) 10 | { 11 | if (value == null || parameter == null) 12 | { 13 | return 0; 14 | } 15 | var addition = double.Parse(parameter.ToString()); 16 | if (value is int i) 17 | { 18 | var newVal = i + addition; 19 | return newVal; 20 | } 21 | if (value is double d) 22 | { 23 | return d + addition; 24 | } 25 | return 0; 26 | } 27 | 28 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) 29 | { 30 | throw new NotImplementedException(); 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /ARESCore/TMPDbMigration/UI/Views/DbMigratorView.xaml: -------------------------------------------------------------------------------- 1 | 13 |