ymikulski 2002/08/13 05:57:20
Added: csframework/src/cs/Activity ISuspendable.cs IStartable.cs
IInitializable.cs IExecutable.cs IDisposable.cs
Log:
no message
Revision Changes Path
1.1
jakarta-avalon-excalibur/csframework/src/cs/Activity/ISuspendable.cs
Index: ISuspendable.cs
===================================================================
///
/// Copyright (C) The Apache Software Foundation. All rights reserved.
///
/// This software is published under the terms of the Apache Software License
/// version 1.1, a copy of which has been included with this distribution in
/// the LICENSE.txt file.
///
using System;
namespace Apache.Avalon.Activity
{
/// <summary>
/// The ISuspendable interface is used when a component
/// will need to temporarily halt execution of a component.
/// The execution may be halted so that you can reconfigure/
/// recompose/recontextualize component.
/// </summary>
public interface ISuspendable
{
/// <summary>
/// Suspends the component.
/// </summary>
void Suspend();
/// <summary>
/// Resumes the component.
/// </summary>
void Resume();
}
}
1.1
jakarta-avalon-excalibur/csframework/src/cs/Activity/IStartable.cs
Index: IStartable.cs
===================================================================
///
/// Copyright (C) The Apache Software Foundation. All rights reserved.
///
/// This software is published under the terms of the Apache Software License
/// version 1.1, a copy of which has been included with this distribution in
/// the LICENSE.txt file.
///
using System;
namespace Apache.Avalon.Activity
{
/// <summary>
/// The IStartable interface is used when components need to
/// be "running" to be active. It provides a method through
/// which components can be "started" and "stopped" without
/// requiring a thread.
/// </summary>
/// <remarks>
/// These methods should start the component but return
/// immediately.
/// </remarks>
public interface IStartable
{
/// <summary>
/// Starts the component.
/// </summary>
/// <exception cref="System.Exception">
/// The Exception if Component can not be started.
/// </exception>
void Start();
/// <summary>
/// Stops the component.
/// </summary>
/// <exception cref="System.Exception">
/// The Exception if the Component can not be stopped.
/// </exception>
void Stop();
}
}
1.1
jakarta-avalon-excalibur/csframework/src/cs/Activity/IInitializable.cs
Index: IInitializable.cs
===================================================================
///
/// Copyright (C) The Apache Software Foundation. All rights reserved.
///
/// This software is published under the terms of the Apache Software License
/// version 1.1, a copy of which has been included with this distribution in
/// the LICENSE.txt file.
///
using System;
namespace Apache.Avalon.Activity
{
/// <summary>
/// The IInitializable interface is used by components
/// that need to allocate resources prior
/// to them becoming active.
/// </summary>
public interface IInitializable
{
/// <summary>
/// Initialializes the component.
/// An Initialization includes allocating any resources
/// required throughout the components lifecycle.
/// </summary>
/// <exception cref="System.Exception">
/// The Exception if an error occurs.
/// </exception>
void Initialize();
}
}
1.1
jakarta-avalon-excalibur/csframework/src/cs/Activity/IExecutable.cs
Index: IExecutable.cs
===================================================================
///
/// Copyright (C) The Apache Software Foundation. All rights reserved.
///
/// This software is published under the terms of the Apache Software License
/// version 1.1, a copy of which has been included with this distribution in
/// the LICENSE.txt file.
///
using System;
namespace Apache.Avalon.Activity
{
/// <summary>
/// The IExecutable can be implemented by components
/// that need to perform some work.
/// </summary>
/// <remarks>
/// The work done may be short lived (ie a simple task) or it could
/// be a long running.
/// </remarks>
public interface IExecutable
{
/// <summary>
/// Executes the action associated with this component.
/// </summary>
/// <exception cref="System.Exception">
/// The Exception if an error occurs.
/// </exception>
void Execute();
}
}
1.1
jakarta-avalon-excalibur/csframework/src/cs/Activity/IDisposable.cs
Index: IDisposable.cs
===================================================================
///
/// Copyright (C) The Apache Software Foundation. All rights reserved.
///
/// This software is published under the terms of the Apache Software License
/// version 1.1, a copy of which has been included with this distribution in
/// the LICENSE.txt file.
///
using System;
namespace Apache.Avalon.Activity
{
/// <summary>
/// The IDisposable interface is used when components need to
/// deallocate and dispose resources prior to their destruction.
/// </summary>
public interface IDisposable
{
/// <summary>
/// The Dispose operation is called at the end of a components
lifecycle.
/// This method will be called after IStartable.stop() method (if
implemented
/// by component). Components use this method to release and destroy
any
/// resources that the Component owns.
/// </summary>
void Dispose();
}
}
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>