// **********************************************************************
//
// Copyright (c) 2002
// IONA Technologies, Inc.
// Waltham, MA, USA
//
// All Rights Reserved
//
// **********************************************************************

#ifndef OB_IMR_TYPES_IDL
#define OB_IMR_TYPES_IDL

#pragma prefix "ooc.com"

#include <OB/Types.idl>

/**
 *
 * The Implementation Repository.
 *
 **/
module IMR
{

/** A process ID. */
typedef unsigned long ProcessID;

/** A POA is a sequence of names from the Root POA. */
typedef CORBA::StringSeq POAName;

/** A sequence of POANames */
typedef sequence<POAName> POANameSeq;

/** A sequence of command line arguments. */
typedef CORBA::StringSeq ArgList;

/**
 *
 * A NoSuchOAD exception indicates that the OAD detailed in the
 * member <code>name</code> doesn't exist.
 *
 */
exception NoSuchOAD
{
    string name;
};

/**
 *
 * A NoSuchServer exception indicates that the server detailed in the
 * member <code>name</code> doesn't exist.
 *
 */
exception NoSuchServer
{
    string name;
};

/**
 *
 * A OADNotRunning exception indicates that the OAD detailed in the
 * member <code>host</code> isn't up.
 *
 */
exception OADNotRunning
{
    string host;
};

/**
 *
 * A NoSuchPOA exception indicates that the poa detailed in the member
 * <code>poa</code> doesn't exist.
 *
 */
exception NoSuchPOA
{
    POAName poa;
};

/**
 *
 * A ServerAlreadyRegistered exception indicates that the server
 * detailed in the member <code>name</code> already exists.
 **/
exception ServerAlreadyRegistered
{
    string name;
};

/**
 *
 * This enumeration contains the various activation modes of a server.
 *
 **/
enum ServerActivationMode
{
    SHARED,
    PERSISTENT
};

/**
 *
 * This enumeration contains the various states of a server.
 *
 **/
enum ServerStatus
{
    FORKED,
    STARTING,
    RUNNING,
    STOPPING,
    STOPPED
};

/** A server ID. */
typedef long ServerID;

/**
 *
 * This enumeration contains the various states of a server.
 *
 **/
enum POAStatus
{
    INACTIVE,
    ACTIVE,
    HOLDING,
    DISCARDING,
    NON_EXISTENT
};

};

#endif
