/*
* Copyright (C) The Community OpenORB Project. All rights reserved.
*
* This software is published under the terms of The OpenORB Community Software
* License version 1.0, a copy of which has been included with this distribution
* in the LICENSE.txt file.
*/

#ifndef _TEST_FRAGMENTEDMESSAGE_IDL_
#define _TEST_FRAGMENTEDMESSAGE_IDL_

#pragma prefix "openorb.org"

module orb
{
    module test
    {
        module iiop
        {
            module fragmentedmessage
            {
                valuetype ValueString wstring;

                custom valuetype ObjectId
                {
                    public wstring objectid;
                };

                enum AttributeEnum
                {
                    StringAttr,
                    Dimension,
                    DoubleAttr,
                    BooleanAttr,
                    LongAttr,
                    DateAttr,
                    DateTime,
                    Enumerated,
                    SequenceAttr,
                    StringBuffer,
                    StyledText,
                    UserList
                };

                enum ItemStatus
                {
                    ADDED,
                    DELETED,
                    MODIFIED,
                    UNMODIFIED
                };

                struct AttributeConstraint
                {
                    ValueString                key;
                    any                        value;
                };
                typedef sequence<AttributeConstraint> AttributeConstraints;

                struct AttributeType
                {
                    ValueString                name;
                    AttributeEnum              type;
                    AttributeConstraints       constraints;
                    ObjectId                   id;
                    long                       tsCounter;
                };
                typedef sequence<AttributeType> AttributeTypes;

                struct AttributeDefinition
                {
                    ValueString                name;
                    AttributeType              type;
                    any                        moreInfo;
                    AttributeConstraints       uiDefinition;
                    ObjectId                   id;
                    ItemStatus                 status;
                    long                       tsCounter;
                };
                typedef sequence<AttributeDefinition> AttributeDefinitions;

                interface AttributeManager
                {
                    AttributeDefinitions getAttributeDefinitions();
                    long getNumberOfAttributeDefintions();
                };
            };
        };
    };
};

#endif
