Files
GenericTeProgramLibrary/Source/Interfaces/IInstrumentManager/IInstrumentManager.cs
2025-01-03 09:50:39 -07:00

159 lines
7.3 KiB
C#

// ******************************************************************************************
// ** **
// ** RAYTHEON PROPRIETARY: THIS DOCUMENT CONTAINS DATA OR INFORMATION **
// ** PROPRIETARY TO RAYTHEON COMPANY AND IS RESTRICTED TO USE ONLY BY PERSONS **
// ** AUTHORIZED BY RAYTHEON COMPANY IN WRITING TO USE IT.DISCLOSURE TO **
// ** UNAUTHORIZED PERSONS WOULD LIKELY CAUSE SUBSTANTIAL COMPETITIVE HARM TO **
// ** RAYTHEON COMPANY'S BUSINESS POSITION. NEITHER SAID DOCUMENT NOR ITS **
// ** CONTENTS SHALL BE FURNISHED OR DISCLOSED TO OR COPIED OR USED BY PERSONS **
// ** OUTSIDE RAYTHEON COMPANY WITHOUT THE EXPRESS WRITTEN APPROVAL OF RAYTHEON **
// ** COMPANY. **
// ** **
// ** THIS PROPRIETARY NOTICE IS NOT APPLICABLE IF DELIVERED TO THE U.S. **
// ** GOVERNMENT. **
// ** **
// ** UNPUBLISHED WORK - COPYRIGHT RAYTHEON COMPANY. **
// ** **
// ** WARNING: THIS DOCUMENT CONTAINS TECHNICAL DATA AND / OR TECHNOLOGY WHOSE **
// ** EXPORT OR DISCLOSURE TO NON-U.S.PERSONS, WHEREVER LOCATED, IS RESTRICTED **
// ** BY THE INTERNATIONAL TRAFFIC IN ARMS REGULATIONS (ITAR) (22 C.F.R.SECTION **
// ** 120-130) OR THE EXPORT ADMINISTRATION REGULATIONS(EAR) (15 C.F.R.SECTION **
// ** 730-774). THIS DOCUMENT CANNOT BE EXPORTED(E.G., PROVIDED TO A SUPPLIER **
// ** OUTSIDE OF THE UNITED STATES) OR DISCLOSED TO A NON-U.S.PERSON, WHEREVER **
// ** LOCATED, UNTIL A FINAL JURISDICTION AND CLASSIFICATION DETERMINATION HAS **
// ** BEEN COMPLETED AND APPROVED BY RAYTHEON, AND ANY REQUIRED U.S.GOVERNMENT **
// ** APPROVALS HAVE BEEN OBTAINED. VIOLATIONS ARE SUBJECT TO SEVERE CRIMINAL **
// ** PENALTIES. **
// ** **
// ** CAPITAL EQUIPMENT/SOFTWARE: THIS TECHNICAL DATA WAS DEVELOPED OR ACQUIRED **
// ** EXCLUSIVELY AT CONTRACTOR EXPENSE AND IS INTENDED FOR USE ON MULTIPLE **
// ** PROJECTS/PROGRAMS. **
// ** **
// *******************************************************************************************
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Raytheon.Communication;
using System.Diagnostics.CodeAnalysis;
namespace Raytheon.Instruments
{
/// <summary>
/// Instrument manager interface.
/// </summary>
/// <remarks>
/// An instrument manager is responsible for loading all of the instrument plugins and providing an interface for retrieving those instruments.
/// </remarks>
[UmsContract]
public interface IInstrumentManager
{
/// <summary>
/// Gets an instrument by name.
/// </summary>
/// <param name="name">The name.</param>
/// <returns>The instrument</returns>
/// <remarks>This function cannot be named the same as the Generic method GetInstrument/<T/>
/// because certain test executives do not support generics, and will throw an AmbiguousMatchException.</remarks>
IInstrument GetGenericInstrument(string name);
/// <summary>
/// Gets an instrument by name.
/// </summary>
/// <param name="name">The name.</param>
/// <returns>The instrument</returns>
T GetInstrument<T>(string name) where T : class;
/// <summary>
/// Gets all instruments currently loaded.
/// </summary>
/// <returns>collection of all known instruments</returns>
ICollection<object> GetInstruments();
/// <summary>
/// Gets all instruments currently loaded.
/// </summary>
/// <returns>array of all known instruments</returns>
[UmsCommand("IInstrumentManager.GetInstrumentsArray")]
object[] GetInstrumentsArray();
/// <summary>
/// Gets the instruments of the given type.
/// </summary>
/// <param name="type">The type.</param>
/// <returns>all known instruments of a certain type</returns>
ICollection<object> GetInstruments(Type type);
/// <summary>
/// Gets the instruments of the given type.
/// </summary>
/// <param name="type">The type.</param>
/// <returns>array of instruments of the specified type</returns>
object[] GetInstrumentsArray(Type type);
/// <summary>
/// Initializes the instrument manager
/// </summary>
[UmsCommand("IInstrumentManager.Initialize")]
void Initialize();
/// <summary>
/// Sets/Gets the part location
/// Added Dec 2013 to better clarify where the part locations are loading from
/// and to be able to set it before initialization
/// </summary>
string _partsLocation
{
get;
set;
}
/// <summary>
/// Closes the instrument manager
/// </summary>
void Shutdown();
/// <summary>
/// Returns a collection of instrument names loaded.
/// </summary>
/// <returns>all the known instrument's unique name</returns>
[SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
[UmsCommand("IInstrumentManager.GetInstrumentNames")]
ICollection<string> GetInstrumentNames();
/// <summary>
/// Returns a collection of instrument names loaded.
/// </summary>
/// <returns>all the known instrument names in array form</returns>
[UmsCommand("IInstrumentManager.GetInstrumentNamesArray")]
string[] GetInstrumentNamesArray();
/// <summary>
/// Initializes all of the instruments.
/// </summary>
[UmsCommand("IInstrumentManager.InitializeInstruments")]
void InitializeInstruments();
/// <summary>
/// Initializes the instrument.
/// </summary>
/// <param name="instName">Name of the inst.</param>
[UmsCommand("IInstrumentManager.InitializeInstrument")]
void InitializeInstrument(string instName);
/// <summary>
/// Shuts down all of the instruments.
/// </summary>
[UmsCommand("IInstrumentManager.ShutdownInstruments")]
void ShutdownInstruments();
/// <summary>
/// Shutdowns the instrument.
/// </summary>
/// <param name="instName">Name of the inst.</param>
[UmsCommand("IInstrumentManager.ShutdownInstrument")]
void ShutdownInstrument(string instName);
}
}