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

#ifndef POA_POLICIES_IDL
#define POA_POLICIES_IDL

#include <OB/Policy.idl>

#pragma prefix "omg.org"

module PortableServer
{
#pragma version PortableServer 2.3

const CORBA::PolicyType THREAD_POLICY_ID = 16;
const CORBA::PolicyType LIFESPAN_POLICY_ID = 17;
const CORBA::PolicyType ID_UNIQUENESS_POLICY_ID = 18;
const CORBA::PolicyType ID_ASSIGNMENT_POLICY_ID = 19;
const CORBA::PolicyType IMPLICIT_ACTIVATION_POLICY_ID = 20;
const CORBA::PolicyType SERVANT_RETENTION_POLICY_ID = 21;
const CORBA::PolicyType REQUEST_PROCESSING_POLICY_ID = 22;

enum ThreadPolicyValue
{
    ORB_CTRL_MODEL,
    SINGLE_THREAD_MODEL
};

enum LifespanPolicyValue
{
    TRANSIENT, PERSISTENT
};

enum IdUniquenessPolicyValue
{
    UNIQUE_ID, MULTIPLE_ID
};

enum IdAssignmentPolicyValue
{
    USER_ID, SYSTEM_ID
};

enum ImplicitActivationPolicyValue
{
    IMPLICIT_ACTIVATION,
    NO_IMPLICIT_ACTIVATION
};

enum ServantRetentionPolicyValue
{
    RETAIN,
    NON_RETAIN
};

enum RequestProcessingPolicyValue
{
    USE_ACTIVE_OBJECT_MAP_ONLY,
    USE_DEFAULT_SERVANT,
    USE_SERVANT_MANAGER
};

local interface ThreadPolicy : CORBA::Policy
{
    readonly attribute ThreadPolicyValue value;
};

local interface LifespanPolicy : CORBA::Policy
{
    readonly attribute LifespanPolicyValue value;
};

local interface IdUniquenessPolicy : CORBA::Policy
{
    readonly attribute IdUniquenessPolicyValue value;
};

local interface IdAssignmentPolicy : CORBA::Policy
{
    readonly attribute IdAssignmentPolicyValue value;
};

local interface ImplicitActivationPolicy : CORBA::Policy
{
    readonly attribute ImplicitActivationPolicyValue value;
};

local interface ServantRetentionPolicy : CORBA::Policy
{
    readonly attribute ServantRetentionPolicyValue value;
};

local interface RequestProcessingPolicy : CORBA::Policy
{
    readonly attribute RequestProcessingPolicyValue value;
};

}; // End module PortableServer

#endif
