init
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using Microsoft.Practices.Prism.Events;
|
||||
|
||||
namespace DTS.Common.Events.Database
|
||||
{
|
||||
/// <summary>
|
||||
/// Event to inform app that a db switch event has occurred
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
///
|
||||
/// </remarks>
|
||||
public class DbStatusEvent : CompositePresentationEvent<DbStatusArg> { }
|
||||
|
||||
public class DbStatusArg
|
||||
{
|
||||
public enum EventTypes
|
||||
{
|
||||
FailedToConnectToRemote,
|
||||
FailedToBackupLocal,
|
||||
FailedToCopy,
|
||||
FailedToRestoreLocal,
|
||||
FailedToBackupLocalFileNotFound,
|
||||
Complete,
|
||||
LegacyStatus
|
||||
}
|
||||
public EventTypes Status { get; }
|
||||
|
||||
public Exception Exception { get; }
|
||||
|
||||
public DbStatusArg(EventTypes error, Exception exception)
|
||||
{
|
||||
Status = error;
|
||||
Exception = exception;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Windows.Data;
|
||||
|
||||
namespace DTS.Common.Converters
|
||||
{
|
||||
[ValueConversion(typeof(List<string>), typeof(string))]
|
||||
public class ListToStringConverter : IValueConverter
|
||||
{
|
||||
|
||||
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
if (targetType != typeof(string))
|
||||
throw new InvalidOperationException("The target must be a String");
|
||||
|
||||
return String.Join(", ", ((List<string>)value)?.ToArray() ?? throw new InvalidOperationException());
|
||||
}
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
using System;
|
||||
|
||||
namespace DTS.Common.Interface.DASFactory
|
||||
{
|
||||
public interface IUDPQATSEntry
|
||||
{
|
||||
string ResponseHostMac { get; }
|
||||
string ResponseClientMacAddress { get; }
|
||||
string SerialNumber { get; }
|
||||
byte ArmState { get; }
|
||||
byte ArmMode { get; }
|
||||
byte Started { get; }
|
||||
byte Triggered { get; }
|
||||
byte FaultFlags { get; }
|
||||
uint SampleRate { get; }
|
||||
ulong TotalSamples { get; }
|
||||
ulong CurrentSample { get; }
|
||||
ushort EventNumber { get; }
|
||||
ulong FaultSampleNumber { get; }
|
||||
ushort LegacyFaultFlags { get; }
|
||||
float InputVoltage { get; }
|
||||
float BackupVoltage { get; }
|
||||
float BatterySOC { get; }
|
||||
ulong EstimateMaxSamples { get; }
|
||||
short TiltSensorCh1 { get; }
|
||||
short TiltSensorCh2 { get; }
|
||||
short TiltSensorCh3 { get; }
|
||||
float SysTempC { get; }
|
||||
byte SyncClockEnable { get; }
|
||||
byte ADCExtClockSyncEnable { get; }
|
||||
byte SyncClockStatus { get; }
|
||||
byte ADCExtClockSyncStatus { get; }
|
||||
ulong EventTriggerSample { get; }
|
||||
float [] ChannelOffsetMV { get; }
|
||||
|
||||
float [] ShuntDeviationPercent { get; }
|
||||
DateTime Timestamp { get; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
using DTS.Common.Interface.TestSetups.Imports.TTS.ReadFile;
|
||||
using Microsoft.Practices.Prism.Events;
|
||||
|
||||
namespace DTS.Common.Events
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// The TTSImportHardwareScanRunEvent event.
|
||||
/// </summary>
|
||||
///
|
||||
/// <remarks>This event is used by the Hardware Scan step to tell the page to ping hardware.</remarks>
|
||||
///
|
||||
public class TTSImportHardwareScanRunEvent : CompositePresentationEvent<ITTSSetup> { }
|
||||
}
|
||||
Reference in New Issue
Block a user