//******************************************************************************************************
// IAdapter.cs - Gbtc
//
// Copyright © 2012, Grid Protection Alliance. All Rights Reserved.
//
// Licensed to the Grid Protection Alliance (GPA) under one or more contributor license agreements. See
// the NOTICE file distributed with this work for additional information regarding copyright ownership.
// The GPA licenses this file to you under the MIT License (MIT), the "License"; you may
// not use this file except in compliance with the License. You may obtain a copy of the License at:
//
// http://www.opensource.org/licenses/MIT
//
// Unless agreed to in writing, the subject software distributed under the License is distributed on an
// "AS-IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. Refer to the
// License for the specific language governing permissions and limitations.
//
// Code Modification History:
// ----------------------------------------------------------------------------------------------------
// 09/23/2010 - Pinal C. Patel
// Generated original version of source code.
// 03/08/2011 - Pinal C. Patel
// Added StatusUpdate and Disposed events.
// Added Type and File properties to support serialized adapter instances.
// 04/05/2011 - Pinal C. Patel
// Changed properties Type to TypeName and File to HostFile to avoid naming conflict.
// 04/08/2011 - Pinal C. Patel
// Added ExecutionException event.
// Renamed StatusUpdate event to StatusMessage.
// 11/23/2011 - J. Ritchie Carroll
// Modified to support buffer optimized ISupportBinaryImage.
// 12/13/2012 - Starlynn Danyelle Gilliam
// Modified Header.
//
//******************************************************************************************************
using System;
using GSF.Configuration;
namespace GSF.Adapters
{
///
/// Defines an adapter that could execute in isolation in a separate .
///
public interface IAdapter : ISupportLifecycle, IProvideStatus, IPersistSettings
{
#region [ Members ]
// Events
///
/// Occurs when the wants to provide a status update.
///
///
/// is the .
/// is the update message.
///
event EventHandler> StatusUpdate;
///
/// Occurs when the encounters an during execution.
///
///
/// is the text that describes the activity that was being performed by the .
/// is the encountered .
///
event EventHandler> ExecutionException;
#endregion
#region [ Properties ]
///
/// Gets or sets the text representation of the 's .
///
string TypeName
{
get;
set;
}
///
/// Gets or sets the path to the file where the is housed.
///
string HostFile
{
get;
set;
}
///
/// Gets the in which the is executing.
///
AppDomain Domain
{
get;
}
///
/// Gets the memory utilization of the in bytes if executing in a separate , otherwise .
///
double MemoryUsage
{
get;
}
///
/// Gets the % processor utilization of the if executing in a separate otherwise .
///
double ProcessorUsage
{
get;
}
#endregion
}
}