
/*
 * This file was generated by the SOM Compiler.
 * FileName: omgestio.xh.
 * Generated using:
 *     SOM Precompiler somipc: 2.29.1.19
 *     SOM Emitter emitxh.dll: 2.108
 */

#ifndef SOM_Module_omgestio_CosLifeCycle_defined
#define SOM_Module_omgestio_CosLifeCycle_defined 1
#include <som.xh>

/*
 * Start of bindings for IDL types
 */

class SOMClass;
class SOMObject;
class CosObjectIdentity_IdentifiableObject;
class CosStream_Streamable;
class CosStream_StreamableFactory;

/*
 * End of bindings for IDL types.
 */
#endif /* SOM_Module_omgestio_CosLifeCycle_defined */

#ifndef SOM_CosLifeCycle_FactoryFinder_xh
#define SOM_CosLifeCycle_FactoryFinder_xh


#define CosLifeCycle_FactoryFinder_MajorVersion 0
#define CosLifeCycle_FactoryFinder_MinorVersion 0
class CosLifeCycle_FactoryFinder;

/* Parents */
#ifndef SOM_SOMObject_xh
#ifdef SOMLOCALINCLUDES
#include "somobj.xh"
#else
#include <somobj.xh>
#endif
#endif

/* Useful C++ SOM defs */
#include <somcls.xh>
#include <somcm.xh>

#ifndef CosLifeCycle_FactoryFinder_API
#define CosLifeCycle_FactoryFinder_API
/*
 * -- The Class API
 */
#ifndef SOM_IMPORTEXPORT_somestrm_omgestio
#ifdef SOM_DLL_somestrm
	/* export semantics */
	#if defined(SOM_DEFFILE_somestrm)\
	||(defined(SOM_DEFFILE_BY_DEFAULT)&&!defined(SOM_NODEFFILE_somestrm))\
	|| !defined(SOM_Module_omgestio_Source)
	#define SOM_IMPORTEXPORT_somestrm_omgestio
	#else
	#define SOM_IMPORTEXPORT_somestrm_omgestio SOMDLLEXPORT
	#endif
#else
	#define SOM_IMPORTEXPORT_somestrm_omgestio SOMDLLIMPORT
#endif
#endif

/*
 * Start of bindings for IDL types
 */


/*
 * End of bindings for IDL types.
 */

/*
 * A function to create the CosLifeCycle_FactoryFinder class object...
 */
SOMEXTERN SOM_IMPORTEXPORT_somestrm_omgestio SOMClass * SOMLINK CosLifeCycle_FactoryFinderNewClass(
		integer4 majorVersion,
		integer4 minorVersion);


/*
 * The API 2 ClassData Structures...
 */
SOMEXTERN struct CosLifeCycle_FactoryFinderClassDataStructure {
	SOMClass *classObject;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosLifeCycle_FactoryFinderClassData;
SOMEXTERN struct CosLifeCycle_FactoryFinderCClassDataStructure {
	som3ClassDetailsPtr    parentMtab;
	somDToken              instanceDataToken;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosLifeCycle_FactoryFinderCClassData;


/*
 * Class Object and Method Token Macros
 */
#define _SOMCLASS_CosLifeCycle_FactoryFinder (CosLifeCycle_FactoryFinderClassData.classObject)
#ifndef SOMGD_CosLifeCycle_FactoryFinder
    #if (defined(_CosLifeCycle_FactoryFinder) || defined(__CosLifeCycle_FactoryFinder))
        #undef _CosLifeCycle_FactoryFinder
        #undef __CosLifeCycle_FactoryFinder
        #define SOMGD_CosLifeCycle_FactoryFinder 1
    #else
        #define _CosLifeCycle_FactoryFinder _SOMCLASS_CosLifeCycle_FactoryFinder
    #endif /* _CosLifeCycle_FactoryFinder */
#endif /* SOMGD_CosLifeCycle_FactoryFinder */
#define CosLifeCycle_FactoryFinder_classObj _SOMCLASS_CosLifeCycle_FactoryFinder
#define _SOMMTOKEN_CosLifeCycle_FactoryFinder(method) ((somMToken)CosLifeCycle_FactoryFinderClassData.method)

/*
 * -- Typedefs for CosLifeCycle_FactoryFinder Method Procedures
 */
SOMEXTERN {

/*
 * -- Typedefs for Reintroduced Wrapper Methods
 */
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultInit(CosLifeCycle_FactoryFinder *somSelf, 
		som3InitCtrl* ctrl);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultInit *somTD_CosLifeCycle_FactoryFinder_somDefaultInit;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDestruct(CosLifeCycle_FactoryFinder *somSelf, 
		octet doFree, 
		som3DestructCtrl* ctrl);
typedef somTP_CosLifeCycle_FactoryFinder_somDestruct *somTD_CosLifeCycle_FactoryFinder_somDestruct;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultCopyInit(CosLifeCycle_FactoryFinder *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultCopyInit *somTD_CosLifeCycle_FactoryFinder_somDefaultCopyInit;
typedef CosLifeCycle_FactoryFinder*   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultAssign(CosLifeCycle_FactoryFinder *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultAssign *somTD_CosLifeCycle_FactoryFinder_somDefaultAssign;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultConstCopyInit(CosLifeCycle_FactoryFinder *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultConstCopyInit *somTD_CosLifeCycle_FactoryFinder_somDefaultConstCopyInit;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultVCopyInit(CosLifeCycle_FactoryFinder *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultVCopyInit *somTD_CosLifeCycle_FactoryFinder_somDefaultVCopyInit;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultConstVCopyInit(CosLifeCycle_FactoryFinder *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultConstVCopyInit *somTD_CosLifeCycle_FactoryFinder_somDefaultConstVCopyInit;
typedef CosLifeCycle_FactoryFinder*   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultConstAssign(CosLifeCycle_FactoryFinder *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultConstAssign *somTD_CosLifeCycle_FactoryFinder_somDefaultConstAssign;
typedef CosLifeCycle_FactoryFinder*   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultVAssign(CosLifeCycle_FactoryFinder *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultVAssign *somTD_CosLifeCycle_FactoryFinder_somDefaultVAssign;
typedef CosLifeCycle_FactoryFinder*   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDefaultConstVAssign(CosLifeCycle_FactoryFinder *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosLifeCycle_FactoryFinder_somDefaultConstVAssign *somTD_CosLifeCycle_FactoryFinder_somDefaultConstVAssign;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somInit(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somInit *somTD_CosLifeCycle_FactoryFinder_somInit;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somUninit(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somUninit *somTD_CosLifeCycle_FactoryFinder_somUninit;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somFree(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somFree *somTD_CosLifeCycle_FactoryFinder_somFree;
typedef SOMClass*   SOMLINK somTP_CosLifeCycle_FactoryFinder_somGetClass(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somGetClass *somTD_CosLifeCycle_FactoryFinder_somGetClass;
typedef string   SOMLINK somTP_CosLifeCycle_FactoryFinder_somGetClassName(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somGetClassName *somTD_CosLifeCycle_FactoryFinder_somGetClassName;
typedef long   SOMLINK somTP_CosLifeCycle_FactoryFinder_somGetSize(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somGetSize *somTD_CosLifeCycle_FactoryFinder_somGetSize;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somIsA(CosLifeCycle_FactoryFinder *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosLifeCycle_FactoryFinder_somIsA *somTD_CosLifeCycle_FactoryFinder_somIsA;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somIsInstanceOf(CosLifeCycle_FactoryFinder *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosLifeCycle_FactoryFinder_somIsInstanceOf *somTD_CosLifeCycle_FactoryFinder_somIsInstanceOf;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somRespondsTo(CosLifeCycle_FactoryFinder *somSelf, 
		somId mId);
typedef somTP_CosLifeCycle_FactoryFinder_somRespondsTo *somTD_CosLifeCycle_FactoryFinder_somRespondsTo;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDispatch(CosLifeCycle_FactoryFinder *somSelf, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosLifeCycle_FactoryFinder_somDispatch *somTD_CosLifeCycle_FactoryFinder_somDispatch;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somClassDispatch(CosLifeCycle_FactoryFinder *somSelf, 
		SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosLifeCycle_FactoryFinder_somClassDispatch *somTD_CosLifeCycle_FactoryFinder_somClassDispatch;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somCastObj(CosLifeCycle_FactoryFinder *somSelf, 
		SOMClass* castedCls);
typedef somTP_CosLifeCycle_FactoryFinder_somCastObj *somTD_CosLifeCycle_FactoryFinder_somCastObj;
typedef boolean   SOMLINK somTP_CosLifeCycle_FactoryFinder_somResetObj(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somResetObj *somTD_CosLifeCycle_FactoryFinder_somResetObj;
typedef CosLifeCycle_FactoryFinder*   SOMLINK somTP_CosLifeCycle_FactoryFinder_somPrintSelf(CosLifeCycle_FactoryFinder *somSelf);
typedef somTP_CosLifeCycle_FactoryFinder_somPrintSelf *somTD_CosLifeCycle_FactoryFinder_somPrintSelf;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDumpSelf(CosLifeCycle_FactoryFinder *somSelf, 
		long level);
typedef somTP_CosLifeCycle_FactoryFinder_somDumpSelf *somTD_CosLifeCycle_FactoryFinder_somDumpSelf;
typedef void   SOMLINK somTP_CosLifeCycle_FactoryFinder_somDumpSelfInt(CosLifeCycle_FactoryFinder *somSelf, 
		long level);
typedef somTP_CosLifeCycle_FactoryFinder_somDumpSelfInt *somTD_CosLifeCycle_FactoryFinder_somDumpSelfInt;
}

#endif /* CosLifeCycle_FactoryFinder_API */


/*
 * -- The C++ Wrapper Class for CosLifeCycle_FactoryFinder
 */
class CosLifeCycle_FactoryFinder : public SOMObject
{
public:

// CosLifeCycle_FactoryFinder::new creates the class object if necessary, and then uses
// somNewNoInit to allocate memory and create the object.
// Initialization is in ctors.
void *operator new(size_t)
{
   if (!_CosLifeCycle_FactoryFinder) CosLifeCycle_FactoryFinderNewClass(CosLifeCycle_FactoryFinder_MajorVersion,CosLifeCycle_FactoryFinder_MinorVersion);
   return (void*)
   (((somTD_SOMClass_somNewNoInit)(SOMClassClassData.somNewNoInit))
         ((SOMClass *)((void*)_CosLifeCycle_FactoryFinder)));
}

// CosLifeCycle_FactoryFinder::delete uses somFree.
void operator delete(void * obj)
{
   if (obj && *(void**)obj)
      ((SOMObject*)obj)->somFree();
}

CosLifeCycle_FactoryFinder& operator=(CosLifeCycle_FactoryFinder& fromObj)
{
   this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
   return *this;
}

CosLifeCycle_FactoryFinder()
{
   if (*(void**)this != (CosLifeCycle_FactoryFinderCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultInit(0);
}

CosLifeCycle_FactoryFinder(CosLifeCycle_FactoryFinder* fromObj)
{
   if (*(void**)this != (CosLifeCycle_FactoryFinderCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
}


/*
 * Reintroduce inherited methods
 */

/* initializer method: somDefaultInit */
void   somDefaultInit(som3InitCtrl* ctrl)
{
/*
 *  A default initializer for a SOM object. Passing a null ctrl
 *  indicates to the receiver that its class is the class of the
 *  object being initialized, whereby the initializer will determine
 *  an appropriate control structure.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultInit)(SOMObjectClassData.somDefaultInit))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl)
	);
}


/* method: somDestruct */
void   somDestruct(octet doFree, 
		som3DestructCtrl* ctrl)
{
/*
 *  The default destructor for a SOM object. A nonzero <doFree>
 *  indicates that the object storage should be freed by the
 *  object's class (via somDeallocate) after uninitialization.
 *  As with somDefaultInit, a null ctrl can be passed.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDestruct)(SOMObjectClassData.somDestruct))(((CosLifeCycle_FactoryFinder *)((void *)this)),doFree,ctrl)
	);
}


/* initializer method: somDefaultCopyInit */
void   somDefaultCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor. Use this to make copies of objects for
 *  calling methods with "by-value" argument semantics.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultCopyInit)(SOMObjectClassData.somDefaultCopyInit))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultAssign */
CosLifeCycle_FactoryFinder*  somDefaultAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator. Use this to "assign" the state of one
 *  object to another.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultAssign)(SOMObjectClassData.somDefaultAssign))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstCopyInit */
void   somDefaultConstCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultConstCopyInit)(SOMObjectClassData.somDefaultConstCopyInit))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultVCopyInit */
void   somDefaultVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultVCopyInit)(SOMObjectClassData.somDefaultVCopyInit))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstVCopyInit */
void   somDefaultConstVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultConstVCopyInit)(SOMObjectClassData.somDefaultConstVCopyInit))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstAssign */
CosLifeCycle_FactoryFinder*  somDefaultConstAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultConstAssign)(SOMObjectClassData.somDefaultConstAssign))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultVAssign */
CosLifeCycle_FactoryFinder*  somDefaultVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultVAssign)(SOMObjectClassData.somDefaultVAssign))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstVAssign */
CosLifeCycle_FactoryFinder*  somDefaultConstVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDefaultConstVAssign)(SOMObjectClassData.somDefaultConstVAssign))(((CosLifeCycle_FactoryFinder *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somInit */
void   somInit()
{
/*
 *  Obsolete but still supported. Override somDefaultInit instead of somInit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somInit)(SOMObjectClassData.somInit))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somUninit */
void   somUninit()
{
/*
 *  Obsolete but still supported. Override somDestruct instead of somUninit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somUninit)(SOMObjectClassData.somUninit))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somFree */
void   somFree()
{
/*
 *  The default implementation just calls somDestruct.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somFree)(SOMObjectClassData.somFree))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somGetClass */
SOMClass*   somGetClass()
{
/*
 *  Return the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somGetClass)(SOMObjectClassData.somGetClass))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somGetClassName */
string   somGetClassName()
{
/*
 *  Return the name of the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somGetClassName)(SOMObjectClassData.somGetClassName))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somGetSize */
long   somGetSize()
{
/*
 *  Return the size of the receiver.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somGetSize)(SOMObjectClassData.somGetSize))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somIsA */
boolean   somIsA(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver responds to methods
 *  introduced by <aClassObj>, and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somIsA)(SOMObjectClassData.somIsA))(((CosLifeCycle_FactoryFinder *)((void *)this)),aClassObj)
	);
}


/* method: somIsInstanceOf */
boolean   somIsInstanceOf(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver is an instance of
 *  <aClassObj> and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somIsInstanceOf)(SOMObjectClassData.somIsInstanceOf))(((CosLifeCycle_FactoryFinder *)((void *)this)),aClassObj)
	);
}


/* method: somRespondsTo */
boolean   somRespondsTo(somId mId)
{
/*
 *  Returns 1 (true) if the indicated method can be invoked
 *  on the receiver and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somRespondsTo)(SOMObjectClassData.somRespondsTo))(((CosLifeCycle_FactoryFinder *)((void *)this)),mId)
	);
}


/* va_list method: somDispatch */

/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
/* the va_list invocation form */
boolean   SOMObject_somDispatch(somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDispatch)(SOMObjectClassData.somDispatch))(((CosLifeCycle_FactoryFinder *)((void *)this)),retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somDispatch(somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDispatch)(SOMObjectClassData.somDispatch))(((CosLifeCycle_FactoryFinder *)((void *)this)),retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* va_list method: somClassDispatch */

/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
/* the va_list invocation form */
boolean   SOMObject_somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosLifeCycle_FactoryFinder *)((void *)this)),clsObj,retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosLifeCycle_FactoryFinder *)((void *)this)),clsObj,retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* method: somCastObj */
boolean   somCastObj(SOMClass* castedCls)
{
/*
 *  Changes the behavior of the target object to that implemented
 *  by castedCls. This is possible when all concrete data in castedCls
 *  is also concrete in the true class of the target object.
 *  Returns true (1) on success, and false (0) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somCastObj)(SOMObjectClassData.somCastObj))(((CosLifeCycle_FactoryFinder *)((void *)this)),castedCls)
	);
}


/* method: somResetObj */
boolean   somResetObj()
{
/*
 *  reset an object to its true class. Returns true always.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somResetObj)(SOMObjectClassData.somResetObj))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somPrintSelf */
CosLifeCycle_FactoryFinder*  somPrintSelf()
{
/*
 *  Uses <SOMOutCharRoutine> to write a brief string with identifying
 *  information about this object.  The default implementation just gives
 *  the object's class name and its address in memory.
 *  <self> is returned.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somPrintSelf)(SOMObjectClassData.somPrintSelf))(((CosLifeCycle_FactoryFinder *)((void *)this)))
	);
}


/* method: somDumpSelf */
void   somDumpSelf(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write a detailed description of this object
 *  and its current state.
 * 
 *  <level> indicates the nesting level for describing compound objects
 *  it must be greater than or equal to zero.  All lines in the
 *  description will be preceeded by <2*level> spaces.
 * 
 *  This routine only actually writes the data that concerns the object
 *  as a whole, such as class, and uses <somDumpSelfInt> to describe
 *  the object's current state.  This approach allows readable
 *  descriptions of compound objects to be constructed.
 * 
 *  Generally it is not necessary to override this method, if it is
 *  overriden it generally must be completely replaced.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDumpSelf)(SOMObjectClassData.somDumpSelf))(((CosLifeCycle_FactoryFinder *)((void *)this)),level)
	);
}


/* method: somDumpSelfInt */
void   somDumpSelfInt(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write in the current state of this object.
 *  Generally this method will need to be overridden.  When overriding
 *  it, begin by calling the parent class form of this method and then
 *  write in a description of your class's instance data. This will
 *  result in a description of all the object's instance data going
 *  from its root ancestor class to its specific class.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosLifeCycle_FactoryFinder_somDumpSelfInt)(SOMObjectClassData.somDumpSelfInt))(((CosLifeCycle_FactoryFinder *)((void *)this)),level)
	);
}



};   /* CosLifeCycle_FactoryFinder */



#endif       /* SOM_CosLifeCycle_FactoryFinder_xh */

#ifndef SOM_Module_omgestio_CosStream_defined
#define SOM_Module_omgestio_CosStream_defined 1
#include <som.xh>

/*
 * Start of bindings for IDL types
 */

#define ex_CosStream_ObjectCreationError "::CosStream::ObjectCreationError"
#define CosStream_ObjectCreationError NULL
#define ex_CosStream_StreamDataFormatError "::CosStream::StreamDataFormatError"
#define CosStream_StreamDataFormatError NULL
class CosStream_Streamable;
class CosStream_StreamableFactory;

#ifndef SOM_DONT_USE_SHORT_NAMES
#ifndef SOMTGD_ex_ObjectCreationError
    #ifdef ex_ObjectCreationError
        #undef ex_ObjectCreationError
        #define SOMTGD_ex_ObjectCreationError 1
    #else
        #define ex_ObjectCreationError ex_CosStream_ObjectCreationError
    #endif /* ex_ObjectCreationError */
#endif /* SOMTGD_ex_ObjectCreationError */
#ifndef SOMTGD_ObjectCreationError
    #ifdef ObjectCreationError
        #undef ObjectCreationError
        #define SOMTGD_ObjectCreationError 1
    #else
        #define ObjectCreationError CosStream_ObjectCreationError
    #endif /* ObjectCreationError */
#endif /* SOMTGD_ObjectCreationError */
#ifndef SOMTGD_ex_StreamDataFormatError
    #ifdef ex_StreamDataFormatError
        #undef ex_StreamDataFormatError
        #define SOMTGD_ex_StreamDataFormatError 1
    #else
        #define ex_StreamDataFormatError ex_CosStream_StreamDataFormatError
    #endif /* ex_StreamDataFormatError */
#endif /* SOMTGD_ex_StreamDataFormatError */
#ifndef SOMTGD_StreamDataFormatError
    #ifdef StreamDataFormatError
        #undef StreamDataFormatError
        #define SOMTGD_StreamDataFormatError 1
    #else
        #define StreamDataFormatError CosStream_StreamDataFormatError
    #endif /* StreamDataFormatError */
#endif /* SOMTGD_StreamDataFormatError */
#endif /* SOM_DONT_USE_SHORT_NAMES */

/*
 * End of bindings for IDL types.
 */
#endif /* SOM_Module_omgestio_CosStream_defined */

#ifndef SOM_CosStream_StreamIO_xh
#define SOM_CosStream_StreamIO_xh


/*
 *  The StreamIO interface defines an abstract class without any
 *  implementation.  It defines only the interfaces in the OMG
 *  Externalization Service for the StreamIO class.
 *  Public methods used by client objects to internalize and
 *  externalize their internal state.
 * 
 */

#define CosStream_StreamIO_MajorVersion 3
#define CosStream_StreamIO_MinorVersion 0
class CosStream_StreamIO;

/*
 *  The StreamIO interface defines an abstract class without any
 *  implementation.  It defines only the interfaces in the OMG
 *  Externalization Service for the StreamIO class.
 *  Public methods used by client objects to internalize and
 *  externalize their internal state.
 * 
 */

/* Parents */
#ifndef SOM_SOMObject_xh
#ifdef SOMLOCALINCLUDES
#include "somobj.xh"
#else
#include <somobj.xh>
#endif
#endif

/* Useful C++ SOM defs */
#include <somcls.xh>
#include <somcm.xh>

#ifndef CosStream_StreamIO_API
#define CosStream_StreamIO_API
/*
 * -- The Class API
 */

/*
 * Start of bindings for IDL types
 */


/*
 * End of bindings for IDL types.
 */

/*
 * A function to create the CosStream_StreamIO class object...
 */
SOMEXTERN SOM_IMPORTEXPORT_somestrm_omgestio SOMClass * SOMLINK CosStream_StreamIONewClass(
		integer4 majorVersion,
		integer4 minorVersion);


/*
 * The API 2 ClassData Structures...
 */
SOMEXTERN struct CosStream_StreamIOClassDataStructure {
	SOMClass *classObject;
	somMToken read_short;
	somMToken write_short;
	somMToken read_long;
	somMToken write_long;
	somMToken read_unsigned_short;
	somMToken write_unsigned_short;
	somMToken read_unsigned_long;
	somMToken write_unsigned_long;
	somMToken read_float;
	somMToken write_float;
	somMToken read_double;
	somMToken write_double;
	somMToken read_boolean;
	somMToken write_boolean;
	somMToken read_char;
	somMToken write_char;
	somMToken read_octet;
	somMToken write_octet;
	somMToken read_string;
	somMToken write_string;
	somMToken read_object;
	somMToken write_object;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosStream_StreamIOClassData;
SOMEXTERN struct CosStream_StreamIOCClassDataStructure {
	som3ClassDetailsPtr    parentMtab;
	somDToken              instanceDataToken;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosStream_StreamIOCClassData;


/*
 * Class Object and Method Token Macros
 */
#define _SOMCLASS_CosStream_StreamIO (CosStream_StreamIOClassData.classObject)
#ifndef SOMGD_CosStream_StreamIO
    #if (defined(_CosStream_StreamIO) || defined(__CosStream_StreamIO))
        #undef _CosStream_StreamIO
        #undef __CosStream_StreamIO
        #define SOMGD_CosStream_StreamIO 1
    #else
        #define _CosStream_StreamIO _SOMCLASS_CosStream_StreamIO
    #endif /* _CosStream_StreamIO */
#endif /* SOMGD_CosStream_StreamIO */
#define CosStream_StreamIO_classObj _SOMCLASS_CosStream_StreamIO
#define _SOMMTOKEN_CosStream_StreamIO(method) ((somMToken)CosStream_StreamIOClassData.method)

/*
 * -- Typedefs for CosStream_StreamIO Method Procedures
 */
SOMEXTERN {
typedef void   SOMLINK somTP_CosStream_StreamIO_write_string(CosStream_StreamIO *somSelf, Environment *ev, 
		string item);
typedef somTP_CosStream_StreamIO_write_string *somTD_CosStream_StreamIO_write_string;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_char(CosStream_StreamIO *somSelf, Environment *ev, 
		char item);
typedef somTP_CosStream_StreamIO_write_char *somTD_CosStream_StreamIO_write_char;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_octet(CosStream_StreamIO *somSelf, Environment *ev, 
		octet item);
typedef somTP_CosStream_StreamIO_write_octet *somTD_CosStream_StreamIO_write_octet;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_unsigned_long(CosStream_StreamIO *somSelf, Environment *ev, 
		unsigned long item);
typedef somTP_CosStream_StreamIO_write_unsigned_long *somTD_CosStream_StreamIO_write_unsigned_long;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_unsigned_short(CosStream_StreamIO *somSelf, Environment *ev, 
		unsigned short item);
typedef somTP_CosStream_StreamIO_write_unsigned_short *somTD_CosStream_StreamIO_write_unsigned_short;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_long(CosStream_StreamIO *somSelf, Environment *ev, 
		long item);
typedef somTP_CosStream_StreamIO_write_long *somTD_CosStream_StreamIO_write_long;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_short(CosStream_StreamIO *somSelf, Environment *ev, 
		short item);
typedef somTP_CosStream_StreamIO_write_short *somTD_CosStream_StreamIO_write_short;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_float(CosStream_StreamIO *somSelf, Environment *ev, 
		float item);
typedef somTP_CosStream_StreamIO_write_float *somTD_CosStream_StreamIO_write_float;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_double(CosStream_StreamIO *somSelf, Environment *ev, 
		double item);
typedef somTP_CosStream_StreamIO_write_double *somTD_CosStream_StreamIO_write_double;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_boolean(CosStream_StreamIO *somSelf, Environment *ev, 
		boolean item);
typedef somTP_CosStream_StreamIO_write_boolean *somTD_CosStream_StreamIO_write_boolean;
typedef void   SOMLINK somTP_CosStream_StreamIO_write_object(CosStream_StreamIO *somSelf, Environment *ev, 
		CosStream_Streamable* item);
typedef somTP_CosStream_StreamIO_write_object *somTD_CosStream_StreamIO_write_object;
typedef string   SOMLINK somTP_CosStream_StreamIO_read_string(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_string *somTD_CosStream_StreamIO_read_string;
typedef char   SOMLINK somTP_CosStream_StreamIO_read_char(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_char *somTD_CosStream_StreamIO_read_char;
typedef octet   SOMLINK somTP_CosStream_StreamIO_read_octet(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_octet *somTD_CosStream_StreamIO_read_octet;
typedef unsigned long   SOMLINK somTP_CosStream_StreamIO_read_unsigned_long(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_unsigned_long *somTD_CosStream_StreamIO_read_unsigned_long;
typedef unsigned short   SOMLINK somTP_CosStream_StreamIO_read_unsigned_short(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_unsigned_short *somTD_CosStream_StreamIO_read_unsigned_short;
typedef long   SOMLINK somTP_CosStream_StreamIO_read_long(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_long *somTD_CosStream_StreamIO_read_long;
typedef short   SOMLINK somTP_CosStream_StreamIO_read_short(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_short *somTD_CosStream_StreamIO_read_short;
typedef float   SOMLINK somTP_CosStream_StreamIO_read_float(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_float *somTD_CosStream_StreamIO_read_float;
typedef double   SOMLINK somTP_CosStream_StreamIO_read_double(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_double *somTD_CosStream_StreamIO_read_double;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_read_boolean(CosStream_StreamIO *somSelf, Environment *ev);
typedef somTP_CosStream_StreamIO_read_boolean *somTD_CosStream_StreamIO_read_boolean;

/*
 * -- Typedefs for Reintroduced Wrapper Methods
 */
typedef void   SOMLINK somTP_CosStream_StreamIO_somDefaultInit(CosStream_StreamIO *somSelf, 
		som3InitCtrl* ctrl);
typedef somTP_CosStream_StreamIO_somDefaultInit *somTD_CosStream_StreamIO_somDefaultInit;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDestruct(CosStream_StreamIO *somSelf, 
		octet doFree, 
		som3DestructCtrl* ctrl);
typedef somTP_CosStream_StreamIO_somDestruct *somTD_CosStream_StreamIO_somDestruct;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDefaultCopyInit(CosStream_StreamIO *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultCopyInit *somTD_CosStream_StreamIO_somDefaultCopyInit;
typedef CosStream_StreamIO*   SOMLINK somTP_CosStream_StreamIO_somDefaultAssign(CosStream_StreamIO *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultAssign *somTD_CosStream_StreamIO_somDefaultAssign;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDefaultConstCopyInit(CosStream_StreamIO *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultConstCopyInit *somTD_CosStream_StreamIO_somDefaultConstCopyInit;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDefaultVCopyInit(CosStream_StreamIO *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultVCopyInit *somTD_CosStream_StreamIO_somDefaultVCopyInit;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDefaultConstVCopyInit(CosStream_StreamIO *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultConstVCopyInit *somTD_CosStream_StreamIO_somDefaultConstVCopyInit;
typedef CosStream_StreamIO*   SOMLINK somTP_CosStream_StreamIO_somDefaultConstAssign(CosStream_StreamIO *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultConstAssign *somTD_CosStream_StreamIO_somDefaultConstAssign;
typedef CosStream_StreamIO*   SOMLINK somTP_CosStream_StreamIO_somDefaultVAssign(CosStream_StreamIO *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultVAssign *somTD_CosStream_StreamIO_somDefaultVAssign;
typedef CosStream_StreamIO*   SOMLINK somTP_CosStream_StreamIO_somDefaultConstVAssign(CosStream_StreamIO *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamIO_somDefaultConstVAssign *somTD_CosStream_StreamIO_somDefaultConstVAssign;
typedef void   SOMLINK somTP_CosStream_StreamIO_somInit(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somInit *somTD_CosStream_StreamIO_somInit;
typedef void   SOMLINK somTP_CosStream_StreamIO_somUninit(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somUninit *somTD_CosStream_StreamIO_somUninit;
typedef void   SOMLINK somTP_CosStream_StreamIO_somFree(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somFree *somTD_CosStream_StreamIO_somFree;
typedef SOMClass*   SOMLINK somTP_CosStream_StreamIO_somGetClass(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somGetClass *somTD_CosStream_StreamIO_somGetClass;
typedef string   SOMLINK somTP_CosStream_StreamIO_somGetClassName(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somGetClassName *somTD_CosStream_StreamIO_somGetClassName;
typedef long   SOMLINK somTP_CosStream_StreamIO_somGetSize(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somGetSize *somTD_CosStream_StreamIO_somGetSize;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somIsA(CosStream_StreamIO *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosStream_StreamIO_somIsA *somTD_CosStream_StreamIO_somIsA;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somIsInstanceOf(CosStream_StreamIO *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosStream_StreamIO_somIsInstanceOf *somTD_CosStream_StreamIO_somIsInstanceOf;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somRespondsTo(CosStream_StreamIO *somSelf, 
		somId mId);
typedef somTP_CosStream_StreamIO_somRespondsTo *somTD_CosStream_StreamIO_somRespondsTo;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somDispatch(CosStream_StreamIO *somSelf, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosStream_StreamIO_somDispatch *somTD_CosStream_StreamIO_somDispatch;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somClassDispatch(CosStream_StreamIO *somSelf, 
		SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosStream_StreamIO_somClassDispatch *somTD_CosStream_StreamIO_somClassDispatch;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somCastObj(CosStream_StreamIO *somSelf, 
		SOMClass* castedCls);
typedef somTP_CosStream_StreamIO_somCastObj *somTD_CosStream_StreamIO_somCastObj;
typedef boolean   SOMLINK somTP_CosStream_StreamIO_somResetObj(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somResetObj *somTD_CosStream_StreamIO_somResetObj;
typedef CosStream_StreamIO*   SOMLINK somTP_CosStream_StreamIO_somPrintSelf(CosStream_StreamIO *somSelf);
typedef somTP_CosStream_StreamIO_somPrintSelf *somTD_CosStream_StreamIO_somPrintSelf;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDumpSelf(CosStream_StreamIO *somSelf, 
		long level);
typedef somTP_CosStream_StreamIO_somDumpSelf *somTD_CosStream_StreamIO_somDumpSelf;
typedef void   SOMLINK somTP_CosStream_StreamIO_somDumpSelfInt(CosStream_StreamIO *somSelf, 
		long level);
typedef somTP_CosStream_StreamIO_somDumpSelfInt *somTD_CosStream_StreamIO_somDumpSelfInt;
}

#endif /* CosStream_StreamIO_API */


/*
 * -- The C++ Wrapper Class for CosStream_StreamIO
 */
class CosStream_StreamIO : public SOMObject
{
/*
 *  The StreamIO interface defines an abstract class without any
 *  implementation.  It defines only the interfaces in the OMG
 *  Externalization Service for the StreamIO class.
 *  Public methods used by client objects to internalize and
 *  externalize their internal state.
 * 
 */
public:

// CosStream_StreamIO::new creates the class object if necessary, and then uses
// somNewNoInit to allocate memory and create the object.
// Initialization is in ctors.
void *operator new(size_t)
{
   if (!_CosStream_StreamIO) CosStream_StreamIONewClass(CosStream_StreamIO_MajorVersion,CosStream_StreamIO_MinorVersion);
   return (void*)
   (((somTD_SOMClass_somNewNoInit)(SOMClassClassData.somNewNoInit))
         ((SOMClass *)((void*)_CosStream_StreamIO)));
}

// CosStream_StreamIO::delete uses somFree.
void operator delete(void * obj)
{
   if (obj && *(void**)obj)
      ((SOMObject*)obj)->somFree();
}

CosStream_StreamIO& operator=(CosStream_StreamIO& fromObj)
{
   this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
   return *this;
}

CosStream_StreamIO()
{
   if (*(void**)this != (CosStream_StreamIOCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultInit(0);
}

CosStream_StreamIO(CosStream_StreamIO* fromObj)
{
   if (*(void**)this != (CosStream_StreamIOCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
}


/* method: write_string */
void   write_string(Environment *ev, 
		string item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_string)(CosStream_StreamIOClassData.write_string))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_char */
void   write_char(Environment *ev, 
		char item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_char)(CosStream_StreamIOClassData.write_char))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_octet */
void   write_octet(Environment *ev, 
		octet item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_octet)(CosStream_StreamIOClassData.write_octet))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_unsigned_long */
void   write_unsigned_long(Environment *ev, 
		unsigned long item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_unsigned_long)(CosStream_StreamIOClassData.write_unsigned_long))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_unsigned_short */
void   write_unsigned_short(Environment *ev, 
		unsigned short item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_unsigned_short)(CosStream_StreamIOClassData.write_unsigned_short))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_long */
void   write_long(Environment *ev, 
		long item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_long)(CosStream_StreamIOClassData.write_long))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_short */
void   write_short(Environment *ev, 
		short item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_short)(CosStream_StreamIOClassData.write_short))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_float */
void   write_float(Environment *ev, 
		float item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_float)(CosStream_StreamIOClassData.write_float))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_double */
void   write_double(Environment *ev, 
		double item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_double)(CosStream_StreamIOClassData.write_double))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_boolean */
void   write_boolean(Environment *ev, 
		boolean item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_boolean)(CosStream_StreamIOClassData.write_boolean))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: write_object */
void   write_object(Environment *ev, 
		CosStream_Streamable* item)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_write_object)(CosStream_StreamIOClassData.write_object))(((CosStream_StreamIO *)((void *)this)), ev,item)
	);
}


/* method: read_string */
string   read_string(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_string)(CosStream_StreamIOClassData.read_string))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_char */
char   read_char(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_char)(CosStream_StreamIOClassData.read_char))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_octet */
octet   read_octet(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_octet)(CosStream_StreamIOClassData.read_octet))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_unsigned_long */
unsigned long   read_unsigned_long(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_unsigned_long)(CosStream_StreamIOClassData.read_unsigned_long))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_unsigned_short */
unsigned short   read_unsigned_short(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_unsigned_short)(CosStream_StreamIOClassData.read_unsigned_short))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_long */
long   read_long(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_long)(CosStream_StreamIOClassData.read_long))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_short */
short   read_short(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_short)(CosStream_StreamIOClassData.read_short))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_float */
float   read_float(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_float)(CosStream_StreamIOClassData.read_float))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_double */
double   read_double(Environment *ev)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_double)(CosStream_StreamIOClassData.read_double))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/* method: read_boolean */
boolean   read_boolean(Environment *ev)
{
/*
 *  D23362
 *     Streamable read_object(in CosLifeCycle::FactoryFinder ff,
 *                            in Streamable obj) raises(StreamDataFormatError);
 * 
 *   The OMG spec also has write_graph() and read_graph() but we omitted
 *   them because compound externalization is not implemented.
 * 
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamIO),
	 ((somTD_CosStream_StreamIO_read_boolean)(CosStream_StreamIOClassData.read_boolean))(((CosStream_StreamIO *)((void *)this)), ev)
	);
}


/*
 * Reintroduce inherited methods
 */

/* initializer method: somDefaultInit */
void   somDefaultInit(som3InitCtrl* ctrl)
{
/*
 *  A default initializer for a SOM object. Passing a null ctrl
 *  indicates to the receiver that its class is the class of the
 *  object being initialized, whereby the initializer will determine
 *  an appropriate control structure.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultInit)(SOMObjectClassData.somDefaultInit))(((CosStream_StreamIO *)((void *)this)),ctrl)
	);
}


/* method: somDestruct */
void   somDestruct(octet doFree, 
		som3DestructCtrl* ctrl)
{
/*
 *  The default destructor for a SOM object. A nonzero <doFree>
 *  indicates that the object storage should be freed by the
 *  object's class (via somDeallocate) after uninitialization.
 *  As with somDefaultInit, a null ctrl can be passed.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDestruct)(SOMObjectClassData.somDestruct))(((CosStream_StreamIO *)((void *)this)),doFree,ctrl)
	);
}


/* initializer method: somDefaultCopyInit */
void   somDefaultCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor. Use this to make copies of objects for
 *  calling methods with "by-value" argument semantics.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultCopyInit)(SOMObjectClassData.somDefaultCopyInit))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultAssign */
CosStream_StreamIO*  somDefaultAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator. Use this to "assign" the state of one
 *  object to another.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultAssign)(SOMObjectClassData.somDefaultAssign))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstCopyInit */
void   somDefaultConstCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultConstCopyInit)(SOMObjectClassData.somDefaultConstCopyInit))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultVCopyInit */
void   somDefaultVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultVCopyInit)(SOMObjectClassData.somDefaultVCopyInit))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstVCopyInit */
void   somDefaultConstVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultConstVCopyInit)(SOMObjectClassData.somDefaultConstVCopyInit))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstAssign */
CosStream_StreamIO*  somDefaultConstAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultConstAssign)(SOMObjectClassData.somDefaultConstAssign))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultVAssign */
CosStream_StreamIO*  somDefaultVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultVAssign)(SOMObjectClassData.somDefaultVAssign))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstVAssign */
CosStream_StreamIO*  somDefaultConstVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDefaultConstVAssign)(SOMObjectClassData.somDefaultConstVAssign))(((CosStream_StreamIO *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somInit */
void   somInit()
{
/*
 *  Obsolete but still supported. Override somDefaultInit instead of somInit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somInit)(SOMObjectClassData.somInit))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somUninit */
void   somUninit()
{
/*
 *  Obsolete but still supported. Override somDestruct instead of somUninit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somUninit)(SOMObjectClassData.somUninit))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somFree */
void   somFree()
{
/*
 *  The default implementation just calls somDestruct.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somFree)(SOMObjectClassData.somFree))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somGetClass */
SOMClass*   somGetClass()
{
/*
 *  Return the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somGetClass)(SOMObjectClassData.somGetClass))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somGetClassName */
string   somGetClassName()
{
/*
 *  Return the name of the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somGetClassName)(SOMObjectClassData.somGetClassName))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somGetSize */
long   somGetSize()
{
/*
 *  Return the size of the receiver.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somGetSize)(SOMObjectClassData.somGetSize))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somIsA */
boolean   somIsA(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver responds to methods
 *  introduced by <aClassObj>, and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somIsA)(SOMObjectClassData.somIsA))(((CosStream_StreamIO *)((void *)this)),aClassObj)
	);
}


/* method: somIsInstanceOf */
boolean   somIsInstanceOf(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver is an instance of
 *  <aClassObj> and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somIsInstanceOf)(SOMObjectClassData.somIsInstanceOf))(((CosStream_StreamIO *)((void *)this)),aClassObj)
	);
}


/* method: somRespondsTo */
boolean   somRespondsTo(somId mId)
{
/*
 *  Returns 1 (true) if the indicated method can be invoked
 *  on the receiver and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somRespondsTo)(SOMObjectClassData.somRespondsTo))(((CosStream_StreamIO *)((void *)this)),mId)
	);
}


/* va_list method: somDispatch */

/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
/* the va_list invocation form */
boolean   SOMObject_somDispatch(somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDispatch)(SOMObjectClassData.somDispatch))(((CosStream_StreamIO *)((void *)this)),retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somDispatch(somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDispatch)(SOMObjectClassData.somDispatch))(((CosStream_StreamIO *)((void *)this)),retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* va_list method: somClassDispatch */

/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
/* the va_list invocation form */
boolean   SOMObject_somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosStream_StreamIO *)((void *)this)),clsObj,retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosStream_StreamIO *)((void *)this)),clsObj,retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* method: somCastObj */
boolean   somCastObj(SOMClass* castedCls)
{
/*
 *  Changes the behavior of the target object to that implemented
 *  by castedCls. This is possible when all concrete data in castedCls
 *  is also concrete in the true class of the target object.
 *  Returns true (1) on success, and false (0) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somCastObj)(SOMObjectClassData.somCastObj))(((CosStream_StreamIO *)((void *)this)),castedCls)
	);
}


/* method: somResetObj */
boolean   somResetObj()
{
/*
 *  reset an object to its true class. Returns true always.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somResetObj)(SOMObjectClassData.somResetObj))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somPrintSelf */
CosStream_StreamIO*  somPrintSelf()
{
/*
 *  Uses <SOMOutCharRoutine> to write a brief string with identifying
 *  information about this object.  The default implementation just gives
 *  the object's class name and its address in memory.
 *  <self> is returned.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somPrintSelf)(SOMObjectClassData.somPrintSelf))(((CosStream_StreamIO *)((void *)this)))
	);
}


/* method: somDumpSelf */
void   somDumpSelf(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write a detailed description of this object
 *  and its current state.
 * 
 *  <level> indicates the nesting level for describing compound objects
 *  it must be greater than or equal to zero.  All lines in the
 *  description will be preceeded by <2*level> spaces.
 * 
 *  This routine only actually writes the data that concerns the object
 *  as a whole, such as class, and uses <somDumpSelfInt> to describe
 *  the object's current state.  This approach allows readable
 *  descriptions of compound objects to be constructed.
 * 
 *  Generally it is not necessary to override this method, if it is
 *  overriden it generally must be completely replaced.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDumpSelf)(SOMObjectClassData.somDumpSelf))(((CosStream_StreamIO *)((void *)this)),level)
	);
}


/* method: somDumpSelfInt */
void   somDumpSelfInt(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write in the current state of this object.
 *  Generally this method will need to be overridden.  When overriding
 *  it, begin by calling the parent class form of this method and then
 *  write in a description of your class's instance data. This will
 *  result in a description of all the object's instance data going
 *  from its root ancestor class to its specific class.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamIO_somDumpSelfInt)(SOMObjectClassData.somDumpSelfInt))(((CosStream_StreamIO *)((void *)this)),level)
	);
}



};   /* CosStream_StreamIO */



#endif       /* SOM_CosStream_StreamIO_xh */

#ifndef SOM_CosStream_Streamable_xh
#define SOM_CosStream_Streamable_xh


/*

 */

#define CosStream_Streamable_MajorVersion 3
#define CosStream_Streamable_MinorVersion 0
class CosStream_Streamable;

/*

 */

/* Parents */
#ifndef SOM_CosObjectIdentity_IdentifiableObject_xh
#ifdef SOMLOCALINCLUDES
#include "omgidobj.xh"
#else
#include <omgidobj.xh>
#endif
#endif

/* Useful C++ SOM defs */
#include <somcls.xh>
#include <somcm.xh>

#ifndef CosStream_Streamable_API
#define CosStream_Streamable_API
/*
 * -- The Class API
 */

/*
 * Start of bindings for IDL types
 */


/*
 * End of bindings for IDL types.
 */

/*
 * A function to create the CosStream_Streamable class object...
 */
SOMEXTERN SOM_IMPORTEXPORT_somestrm_omgestio SOMClass * SOMLINK CosStream_StreamableNewClass(
		integer4 majorVersion,
		integer4 minorVersion);


/*
 * The API 2 ClassData Structures...
 */
SOMEXTERN struct CosStream_StreamableClassDataStructure {
	SOMClass *classObject;
	somMToken externalize_to_stream;
	somMToken internalize_from_stream;
	somMToken _get_external_form_id;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosStream_StreamableClassData;
SOMEXTERN struct CosStream_StreamableCClassDataStructure {
	som3ClassDetailsPtr    parentMtab;
	somDToken              instanceDataToken;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosStream_StreamableCClassData;


/*
 * Class Object and Method Token Macros
 */
#define _SOMCLASS_CosStream_Streamable (CosStream_StreamableClassData.classObject)
#ifndef SOMGD_CosStream_Streamable
    #if (defined(_CosStream_Streamable) || defined(__CosStream_Streamable))
        #undef _CosStream_Streamable
        #undef __CosStream_Streamable
        #define SOMGD_CosStream_Streamable 1
    #else
        #define _CosStream_Streamable _SOMCLASS_CosStream_Streamable
    #endif /* _CosStream_Streamable */
#endif /* SOMGD_CosStream_Streamable */
#define CosStream_Streamable_classObj _SOMCLASS_CosStream_Streamable
#define _SOMMTOKEN_CosStream_Streamable(method) ((somMToken)CosStream_StreamableClassData.method)

/*
 * -- Typedefs for CosStream_Streamable Method Procedures
 */
SOMEXTERN {
typedef void   SOMLINK somTP_CosStream_Streamable_externalize_to_stream(CosStream_Streamable *somSelf, Environment *ev, 
		CosStream_StreamIO* stream);
typedef somTP_CosStream_Streamable_externalize_to_stream *somTD_CosStream_Streamable_externalize_to_stream;
typedef void   SOMLINK somTP_CosStream_Streamable_internalize_from_stream(CosStream_Streamable *somSelf, Environment *ev, 
		CosStream_StreamIO* stream, 
		CosLifeCycle_FactoryFinder* ff);
typedef somTP_CosStream_Streamable_internalize_from_stream *somTD_CosStream_Streamable_internalize_from_stream;

/*
 * -- Typedefs for Reintroduced Wrapper Methods
 */
typedef CosObjectIdentity_ObjectIdentifier   SOMLINK somTP_CosStream_Streamable__get_constant_random_id(CosStream_Streamable *somSelf, Environment *ev);
typedef somTP_CosStream_Streamable__get_constant_random_id *somTD_CosStream_Streamable__get_constant_random_id;
typedef boolean   SOMLINK somTP_CosStream_Streamable_is_identical(CosStream_Streamable *somSelf, Environment *ev, 
		CosObjectIdentity_IdentifiableObject* other_object);
typedef somTP_CosStream_Streamable_is_identical *somTD_CosStream_Streamable_is_identical;
typedef void   SOMLINK somTP_CosStream_Streamable_somDefaultInit(CosStream_Streamable *somSelf, 
		som3InitCtrl* ctrl);
typedef somTP_CosStream_Streamable_somDefaultInit *somTD_CosStream_Streamable_somDefaultInit;
typedef void   SOMLINK somTP_CosStream_Streamable_somDestruct(CosStream_Streamable *somSelf, 
		octet doFree, 
		som3DestructCtrl* ctrl);
typedef somTP_CosStream_Streamable_somDestruct *somTD_CosStream_Streamable_somDestruct;
typedef void   SOMLINK somTP_CosStream_Streamable_somDefaultCopyInit(CosStream_Streamable *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultCopyInit *somTD_CosStream_Streamable_somDefaultCopyInit;
typedef CosStream_Streamable*   SOMLINK somTP_CosStream_Streamable_somDefaultAssign(CosStream_Streamable *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultAssign *somTD_CosStream_Streamable_somDefaultAssign;
typedef void   SOMLINK somTP_CosStream_Streamable_somDefaultConstCopyInit(CosStream_Streamable *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultConstCopyInit *somTD_CosStream_Streamable_somDefaultConstCopyInit;
typedef void   SOMLINK somTP_CosStream_Streamable_somDefaultVCopyInit(CosStream_Streamable *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultVCopyInit *somTD_CosStream_Streamable_somDefaultVCopyInit;
typedef void   SOMLINK somTP_CosStream_Streamable_somDefaultConstVCopyInit(CosStream_Streamable *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultConstVCopyInit *somTD_CosStream_Streamable_somDefaultConstVCopyInit;
typedef CosStream_Streamable*   SOMLINK somTP_CosStream_Streamable_somDefaultConstAssign(CosStream_Streamable *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultConstAssign *somTD_CosStream_Streamable_somDefaultConstAssign;
typedef CosStream_Streamable*   SOMLINK somTP_CosStream_Streamable_somDefaultVAssign(CosStream_Streamable *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultVAssign *somTD_CosStream_Streamable_somDefaultVAssign;
typedef CosStream_Streamable*   SOMLINK somTP_CosStream_Streamable_somDefaultConstVAssign(CosStream_Streamable *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_Streamable_somDefaultConstVAssign *somTD_CosStream_Streamable_somDefaultConstVAssign;
typedef void   SOMLINK somTP_CosStream_Streamable_somInit(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somInit *somTD_CosStream_Streamable_somInit;
typedef void   SOMLINK somTP_CosStream_Streamable_somUninit(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somUninit *somTD_CosStream_Streamable_somUninit;
typedef void   SOMLINK somTP_CosStream_Streamable_somFree(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somFree *somTD_CosStream_Streamable_somFree;
typedef SOMClass*   SOMLINK somTP_CosStream_Streamable_somGetClass(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somGetClass *somTD_CosStream_Streamable_somGetClass;
typedef string   SOMLINK somTP_CosStream_Streamable_somGetClassName(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somGetClassName *somTD_CosStream_Streamable_somGetClassName;
typedef long   SOMLINK somTP_CosStream_Streamable_somGetSize(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somGetSize *somTD_CosStream_Streamable_somGetSize;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somIsA(CosStream_Streamable *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosStream_Streamable_somIsA *somTD_CosStream_Streamable_somIsA;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somIsInstanceOf(CosStream_Streamable *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosStream_Streamable_somIsInstanceOf *somTD_CosStream_Streamable_somIsInstanceOf;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somRespondsTo(CosStream_Streamable *somSelf, 
		somId mId);
typedef somTP_CosStream_Streamable_somRespondsTo *somTD_CosStream_Streamable_somRespondsTo;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somDispatch(CosStream_Streamable *somSelf, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosStream_Streamable_somDispatch *somTD_CosStream_Streamable_somDispatch;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somClassDispatch(CosStream_Streamable *somSelf, 
		SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosStream_Streamable_somClassDispatch *somTD_CosStream_Streamable_somClassDispatch;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somCastObj(CosStream_Streamable *somSelf, 
		SOMClass* castedCls);
typedef somTP_CosStream_Streamable_somCastObj *somTD_CosStream_Streamable_somCastObj;
typedef boolean   SOMLINK somTP_CosStream_Streamable_somResetObj(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somResetObj *somTD_CosStream_Streamable_somResetObj;
typedef CosStream_Streamable*   SOMLINK somTP_CosStream_Streamable_somPrintSelf(CosStream_Streamable *somSelf);
typedef somTP_CosStream_Streamable_somPrintSelf *somTD_CosStream_Streamable_somPrintSelf;
typedef void   SOMLINK somTP_CosStream_Streamable_somDumpSelf(CosStream_Streamable *somSelf, 
		long level);
typedef somTP_CosStream_Streamable_somDumpSelf *somTD_CosStream_Streamable_somDumpSelf;
typedef void   SOMLINK somTP_CosStream_Streamable_somDumpSelfInt(CosStream_Streamable *somSelf, 
		long level);
typedef somTP_CosStream_Streamable_somDumpSelfInt *somTD_CosStream_Streamable_somDumpSelfInt;
}

#endif /* CosStream_Streamable_API */


/*
 * -- The C++ Wrapper Class for CosStream_Streamable
 */
class CosStream_Streamable : public CosObjectIdentity_IdentifiableObject
{
/*

 */
public:

// CosStream_Streamable::new creates the class object if necessary, and then uses
// somNewNoInit to allocate memory and create the object.
// Initialization is in ctors.
void *operator new(size_t)
{
   if (!_CosStream_Streamable) CosStream_StreamableNewClass(CosStream_Streamable_MajorVersion,CosStream_Streamable_MinorVersion);
   return (void*)
   (((somTD_SOMClass_somNewNoInit)(SOMClassClassData.somNewNoInit))
         ((SOMClass *)((void*)_CosStream_Streamable)));
}

// CosStream_Streamable::delete uses somFree.
void operator delete(void * obj)
{
   if (obj && *(void**)obj)
      ((SOMObject*)obj)->somFree();
}

CosStream_Streamable& operator=(CosStream_Streamable& fromObj)
{
   this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
   return *this;
}

CosStream_Streamable()
{
   if (*(void**)this != (CosStream_StreamableCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultInit(0);
}

CosStream_Streamable(CosStream_Streamable* fromObj)
{
   if (*(void**)this != (CosStream_StreamableCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
}


/* method: externalize_to_stream */
void   externalize_to_stream(Environment *ev, 
		CosStream_StreamIO* stream)
{
/*
 *  This method must be overridden.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_Streamable),
	 ((somTD_CosStream_Streamable_externalize_to_stream)(CosStream_StreamableClassData.externalize_to_stream))(((CosStream_Streamable *)((void *)this)), ev,stream)
	);
}


/* method: internalize_from_stream */
void   internalize_from_stream(Environment *ev, 
		CosStream_StreamIO* stream, 
		CosLifeCycle_FactoryFinder* ff)
{
/*
 *  This method must be overridden.
 *  D23362
 *     readonly attribute CosLifeCycle::Key external_form_id;
 *  The write_object method puts this attribute into the stream so that
 *  read_object can create a new object.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_Streamable),
	 ((somTD_CosStream_Streamable_internalize_from_stream)(CosStream_StreamableClassData.internalize_from_stream))(((CosStream_Streamable *)((void *)this)), ev,stream,ff)
	);
}


/*
 * Reintroduce inherited methods
 */

/* method: _get_constant_random_id */
CosObjectIdentity_ObjectIdentifier   _get_constant_random_id(Environment *ev)
{
/*
 * Method from the IDL attribute statement:
 * "readonly attribute CosObjectIdentity_ObjectIdentifier constant_random_id"
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosObjectIdentity_IdentifiableObject),
	 ((somTD_CosStream_Streamable__get_constant_random_id)(CosObjectIdentity_IdentifiableObjectClassData._get_constant_random_id))(((CosStream_Streamable *)((void *)this)), ev)
	);
}


/* method: is_identical */
boolean   is_identical(Environment *ev, 
		CosObjectIdentity_IdentifiableObject* other_object)
{
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosObjectIdentity_IdentifiableObject),
	 ((somTD_CosStream_Streamable_is_identical)(CosObjectIdentity_IdentifiableObjectClassData.is_identical))(((CosStream_Streamable *)((void *)this)), ev,other_object)
	);
}


/* initializer method: somDefaultInit */
void   somDefaultInit(som3InitCtrl* ctrl)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultInit)(SOMObjectClassData.somDefaultInit))(((CosStream_Streamable *)((void *)this)),ctrl)
	);
}


/* method: somDestruct */
void   somDestruct(octet doFree, 
		som3DestructCtrl* ctrl)
{
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDestruct)(SOMObjectClassData.somDestruct))(((CosStream_Streamable *)((void *)this)),doFree,ctrl)
	);
}


/* initializer method: somDefaultCopyInit */
void   somDefaultCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor. Use this to make copies of objects for
 *  calling methods with "by-value" argument semantics.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultCopyInit)(SOMObjectClassData.somDefaultCopyInit))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultAssign */
CosStream_Streamable*  somDefaultAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator. Use this to "assign" the state of one
 *  object to another.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultAssign)(SOMObjectClassData.somDefaultAssign))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstCopyInit */
void   somDefaultConstCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultConstCopyInit)(SOMObjectClassData.somDefaultConstCopyInit))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultVCopyInit */
void   somDefaultVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultVCopyInit)(SOMObjectClassData.somDefaultVCopyInit))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstVCopyInit */
void   somDefaultConstVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultConstVCopyInit)(SOMObjectClassData.somDefaultConstVCopyInit))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstAssign */
CosStream_Streamable*  somDefaultConstAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultConstAssign)(SOMObjectClassData.somDefaultConstAssign))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultVAssign */
CosStream_Streamable*  somDefaultVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultVAssign)(SOMObjectClassData.somDefaultVAssign))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstVAssign */
CosStream_Streamable*  somDefaultConstVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDefaultConstVAssign)(SOMObjectClassData.somDefaultConstVAssign))(((CosStream_Streamable *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somInit */
void   somInit()
{
/*
 *  Obsolete but still supported. Override somDefaultInit instead of somInit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somInit)(SOMObjectClassData.somInit))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somUninit */
void   somUninit()
{
/*
 *  Obsolete but still supported. Override somDestruct instead of somUninit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somUninit)(SOMObjectClassData.somUninit))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somFree */
void   somFree()
{
/*
 *  The default implementation just calls somDestruct.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somFree)(SOMObjectClassData.somFree))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somGetClass */
SOMClass*   somGetClass()
{
/*
 *  Return the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somGetClass)(SOMObjectClassData.somGetClass))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somGetClassName */
string   somGetClassName()
{
/*
 *  Return the name of the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somGetClassName)(SOMObjectClassData.somGetClassName))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somGetSize */
long   somGetSize()
{
/*
 *  Return the size of the receiver.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somGetSize)(SOMObjectClassData.somGetSize))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somIsA */
boolean   somIsA(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver responds to methods
 *  introduced by <aClassObj>, and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somIsA)(SOMObjectClassData.somIsA))(((CosStream_Streamable *)((void *)this)),aClassObj)
	);
}


/* method: somIsInstanceOf */
boolean   somIsInstanceOf(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver is an instance of
 *  <aClassObj> and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somIsInstanceOf)(SOMObjectClassData.somIsInstanceOf))(((CosStream_Streamable *)((void *)this)),aClassObj)
	);
}


/* method: somRespondsTo */
boolean   somRespondsTo(somId mId)
{
/*
 *  Returns 1 (true) if the indicated method can be invoked
 *  on the receiver and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somRespondsTo)(SOMObjectClassData.somRespondsTo))(((CosStream_Streamable *)((void *)this)),mId)
	);
}


/* va_list method: somDispatch */

/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
/* the va_list invocation form */
boolean   SOMObject_somDispatch(somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDispatch)(SOMObjectClassData.somDispatch))(((CosStream_Streamable *)((void *)this)),retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somDispatch(somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDispatch)(SOMObjectClassData.somDispatch))(((CosStream_Streamable *)((void *)this)),retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* va_list method: somClassDispatch */

/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
/* the va_list invocation form */
boolean   SOMObject_somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosStream_Streamable *)((void *)this)),clsObj,retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosStream_Streamable *)((void *)this)),clsObj,retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* method: somCastObj */
boolean   somCastObj(SOMClass* castedCls)
{
/*
 *  Changes the behavior of the target object to that implemented
 *  by castedCls. This is possible when all concrete data in castedCls
 *  is also concrete in the true class of the target object.
 *  Returns true (1) on success, and false (0) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somCastObj)(SOMObjectClassData.somCastObj))(((CosStream_Streamable *)((void *)this)),castedCls)
	);
}


/* method: somResetObj */
boolean   somResetObj()
{
/*
 *  reset an object to its true class. Returns true always.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somResetObj)(SOMObjectClassData.somResetObj))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somPrintSelf */
CosStream_Streamable*  somPrintSelf()
{
/*
 *  Uses <SOMOutCharRoutine> to write a brief string with identifying
 *  information about this object.  The default implementation just gives
 *  the object's class name and its address in memory.
 *  <self> is returned.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somPrintSelf)(SOMObjectClassData.somPrintSelf))(((CosStream_Streamable *)((void *)this)))
	);
}


/* method: somDumpSelf */
void   somDumpSelf(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write a detailed description of this object
 *  and its current state.
 * 
 *  <level> indicates the nesting level for describing compound objects
 *  it must be greater than or equal to zero.  All lines in the
 *  description will be preceeded by <2*level> spaces.
 * 
 *  This routine only actually writes the data that concerns the object
 *  as a whole, such as class, and uses <somDumpSelfInt> to describe
 *  the object's current state.  This approach allows readable
 *  descriptions of compound objects to be constructed.
 * 
 *  Generally it is not necessary to override this method, if it is
 *  overriden it generally must be completely replaced.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDumpSelf)(SOMObjectClassData.somDumpSelf))(((CosStream_Streamable *)((void *)this)),level)
	);
}


/* method: somDumpSelfInt */
void   somDumpSelfInt(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write in the current state of this object.
 *  Generally this method will need to be overridden.  When overriding
 *  it, begin by calling the parent class form of this method and then
 *  write in a description of your class's instance data. This will
 *  result in a description of all the object's instance data going
 *  from its root ancestor class to its specific class.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_Streamable_somDumpSelfInt)(SOMObjectClassData.somDumpSelfInt))(((CosStream_Streamable *)((void *)this)),level)
	);
}



};   /* CosStream_Streamable */



#endif       /* SOM_CosStream_Streamable_xh */

#ifndef SOM_CosStream_StreamableFactory_xh
#define SOM_CosStream_StreamableFactory_xh


#define CosStream_StreamableFactory_MajorVersion 3
#define CosStream_StreamableFactory_MinorVersion 0
class CosStream_StreamableFactory;

/* Parents */
#ifndef SOM_SOMObject_xh
#ifdef SOMLOCALINCLUDES
#include "somobj.xh"
#else
#include <somobj.xh>
#endif
#endif

/* Useful C++ SOM defs */
#include <somcls.xh>
#include <somcm.xh>

#ifndef CosStream_StreamableFactory_API
#define CosStream_StreamableFactory_API
/*
 * -- The Class API
 */

/*
 * Start of bindings for IDL types
 */


/*
 * End of bindings for IDL types.
 */

/*
 * A function to create the CosStream_StreamableFactory class object...
 */
SOMEXTERN SOM_IMPORTEXPORT_somestrm_omgestio SOMClass * SOMLINK CosStream_StreamableFactoryNewClass(
		integer4 majorVersion,
		integer4 minorVersion);


/*
 * The API 2 ClassData Structures...
 */
SOMEXTERN struct CosStream_StreamableFactoryClassDataStructure {
	SOMClass *classObject;
	somMToken create_uninitialized;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosStream_StreamableFactoryClassData;
SOMEXTERN struct CosStream_StreamableFactoryCClassDataStructure {
	som3ClassDetailsPtr    parentMtab;
	somDToken              instanceDataToken;
} SOMDLINK SOM_IMPORTEXPORT_somestrm_omgestio CosStream_StreamableFactoryCClassData;


/*
 * Class Object and Method Token Macros
 */
#define _SOMCLASS_CosStream_StreamableFactory (CosStream_StreamableFactoryClassData.classObject)
#ifndef SOMGD_CosStream_StreamableFactory
    #if (defined(_CosStream_StreamableFactory) || defined(__CosStream_StreamableFactory))
        #undef _CosStream_StreamableFactory
        #undef __CosStream_StreamableFactory
        #define SOMGD_CosStream_StreamableFactory 1
    #else
        #define _CosStream_StreamableFactory _SOMCLASS_CosStream_StreamableFactory
    #endif /* _CosStream_StreamableFactory */
#endif /* SOMGD_CosStream_StreamableFactory */
#define CosStream_StreamableFactory_classObj _SOMCLASS_CosStream_StreamableFactory
#define _SOMMTOKEN_CosStream_StreamableFactory(method) ((somMToken)CosStream_StreamableFactoryClassData.method)

/*
 * -- Typedefs for CosStream_StreamableFactory Method Procedures
 */
SOMEXTERN {
typedef CosStream_Streamable*   SOMLINK somTP_CosStream_StreamableFactory_create_uninitialized(CosStream_StreamableFactory *somSelf, Environment *ev);
typedef somTP_CosStream_StreamableFactory_create_uninitialized *somTD_CosStream_StreamableFactory_create_uninitialized;

/*
 * -- Typedefs for Reintroduced Wrapper Methods
 */
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDefaultInit(CosStream_StreamableFactory *somSelf, 
		som3InitCtrl* ctrl);
typedef somTP_CosStream_StreamableFactory_somDefaultInit *somTD_CosStream_StreamableFactory_somDefaultInit;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDestruct(CosStream_StreamableFactory *somSelf, 
		octet doFree, 
		som3DestructCtrl* ctrl);
typedef somTP_CosStream_StreamableFactory_somDestruct *somTD_CosStream_StreamableFactory_somDestruct;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDefaultCopyInit(CosStream_StreamableFactory *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultCopyInit *somTD_CosStream_StreamableFactory_somDefaultCopyInit;
typedef CosStream_StreamableFactory*   SOMLINK somTP_CosStream_StreamableFactory_somDefaultAssign(CosStream_StreamableFactory *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultAssign *somTD_CosStream_StreamableFactory_somDefaultAssign;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDefaultConstCopyInit(CosStream_StreamableFactory *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultConstCopyInit *somTD_CosStream_StreamableFactory_somDefaultConstCopyInit;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDefaultVCopyInit(CosStream_StreamableFactory *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultVCopyInit *somTD_CosStream_StreamableFactory_somDefaultVCopyInit;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDefaultConstVCopyInit(CosStream_StreamableFactory *somSelf, 
		som3InitCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultConstVCopyInit *somTD_CosStream_StreamableFactory_somDefaultConstVCopyInit;
typedef CosStream_StreamableFactory*   SOMLINK somTP_CosStream_StreamableFactory_somDefaultConstAssign(CosStream_StreamableFactory *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultConstAssign *somTD_CosStream_StreamableFactory_somDefaultConstAssign;
typedef CosStream_StreamableFactory*   SOMLINK somTP_CosStream_StreamableFactory_somDefaultVAssign(CosStream_StreamableFactory *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultVAssign *somTD_CosStream_StreamableFactory_somDefaultVAssign;
typedef CosStream_StreamableFactory*   SOMLINK somTP_CosStream_StreamableFactory_somDefaultConstVAssign(CosStream_StreamableFactory *somSelf, 
		som3AssignCtrl* ctrl, 
		SOMObject* fromObj);
typedef somTP_CosStream_StreamableFactory_somDefaultConstVAssign *somTD_CosStream_StreamableFactory_somDefaultConstVAssign;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somInit(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somInit *somTD_CosStream_StreamableFactory_somInit;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somUninit(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somUninit *somTD_CosStream_StreamableFactory_somUninit;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somFree(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somFree *somTD_CosStream_StreamableFactory_somFree;
typedef SOMClass*   SOMLINK somTP_CosStream_StreamableFactory_somGetClass(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somGetClass *somTD_CosStream_StreamableFactory_somGetClass;
typedef string   SOMLINK somTP_CosStream_StreamableFactory_somGetClassName(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somGetClassName *somTD_CosStream_StreamableFactory_somGetClassName;
typedef long   SOMLINK somTP_CosStream_StreamableFactory_somGetSize(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somGetSize *somTD_CosStream_StreamableFactory_somGetSize;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somIsA(CosStream_StreamableFactory *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosStream_StreamableFactory_somIsA *somTD_CosStream_StreamableFactory_somIsA;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somIsInstanceOf(CosStream_StreamableFactory *somSelf, 
		SOMClass* aClassObj);
typedef somTP_CosStream_StreamableFactory_somIsInstanceOf *somTD_CosStream_StreamableFactory_somIsInstanceOf;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somRespondsTo(CosStream_StreamableFactory *somSelf, 
		somId mId);
typedef somTP_CosStream_StreamableFactory_somRespondsTo *somTD_CosStream_StreamableFactory_somRespondsTo;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somDispatch(CosStream_StreamableFactory *somSelf, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosStream_StreamableFactory_somDispatch *somTD_CosStream_StreamableFactory_somDispatch;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somClassDispatch(CosStream_StreamableFactory *somSelf, 
		SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap);
typedef somTP_CosStream_StreamableFactory_somClassDispatch *somTD_CosStream_StreamableFactory_somClassDispatch;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somCastObj(CosStream_StreamableFactory *somSelf, 
		SOMClass* castedCls);
typedef somTP_CosStream_StreamableFactory_somCastObj *somTD_CosStream_StreamableFactory_somCastObj;
typedef boolean   SOMLINK somTP_CosStream_StreamableFactory_somResetObj(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somResetObj *somTD_CosStream_StreamableFactory_somResetObj;
typedef CosStream_StreamableFactory*   SOMLINK somTP_CosStream_StreamableFactory_somPrintSelf(CosStream_StreamableFactory *somSelf);
typedef somTP_CosStream_StreamableFactory_somPrintSelf *somTD_CosStream_StreamableFactory_somPrintSelf;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDumpSelf(CosStream_StreamableFactory *somSelf, 
		long level);
typedef somTP_CosStream_StreamableFactory_somDumpSelf *somTD_CosStream_StreamableFactory_somDumpSelf;
typedef void   SOMLINK somTP_CosStream_StreamableFactory_somDumpSelfInt(CosStream_StreamableFactory *somSelf, 
		long level);
typedef somTP_CosStream_StreamableFactory_somDumpSelfInt *somTD_CosStream_StreamableFactory_somDumpSelfInt;
}

#endif /* CosStream_StreamableFactory_API */


/*
 * -- The C++ Wrapper Class for CosStream_StreamableFactory
 */
class CosStream_StreamableFactory : public SOMObject
{
public:

// CosStream_StreamableFactory::new creates the class object if necessary, and then uses
// somNewNoInit to allocate memory and create the object.
// Initialization is in ctors.
void *operator new(size_t)
{
   if (!_CosStream_StreamableFactory) CosStream_StreamableFactoryNewClass(CosStream_StreamableFactory_MajorVersion,CosStream_StreamableFactory_MinorVersion);
   return (void*)
   (((somTD_SOMClass_somNewNoInit)(SOMClassClassData.somNewNoInit))
         ((SOMClass *)((void*)_CosStream_StreamableFactory)));
}

// CosStream_StreamableFactory::delete uses somFree.
void operator delete(void * obj)
{
   if (obj && *(void**)obj)
      ((SOMObject*)obj)->somFree();
}

CosStream_StreamableFactory& operator=(CosStream_StreamableFactory& fromObj)
{
   this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
   return *this;
}

CosStream_StreamableFactory()
{
   if (*(void**)this != (CosStream_StreamableFactoryCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultInit(0);
}

CosStream_StreamableFactory(CosStream_StreamableFactory* fromObj)
{
   if (*(void**)this != (CosStream_StreamableFactoryCClassData.parentMtab)->mtab)
      return;
   ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
}


/* method: create_uninitialized */
CosStream_Streamable*   create_uninitialized(Environment *ev)
{
/*
 *   The OMG spec has method name "create_unitialized", which we assume
 *   is a typographical error.
 * 
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_CosStream_StreamableFactory),
	 ((somTD_CosStream_StreamableFactory_create_uninitialized)(CosStream_StreamableFactoryClassData.create_uninitialized))(((CosStream_StreamableFactory *)((void *)this)), ev)
	);
}


/*
 * Reintroduce inherited methods
 */

/* initializer method: somDefaultInit */
void   somDefaultInit(som3InitCtrl* ctrl)
{
/*
 *  A default initializer for a SOM object. Passing a null ctrl
 *  indicates to the receiver that its class is the class of the
 *  object being initialized, whereby the initializer will determine
 *  an appropriate control structure.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultInit)(SOMObjectClassData.somDefaultInit))(((CosStream_StreamableFactory *)((void *)this)),ctrl)
	);
}


/* method: somDestruct */
void   somDestruct(octet doFree, 
		som3DestructCtrl* ctrl)
{
/*
 *  The default destructor for a SOM object. A nonzero <doFree>
 *  indicates that the object storage should be freed by the
 *  object's class (via somDeallocate) after uninitialization.
 *  As with somDefaultInit, a null ctrl can be passed.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDestruct)(SOMObjectClassData.somDestruct))(((CosStream_StreamableFactory *)((void *)this)),doFree,ctrl)
	);
}


/* initializer method: somDefaultCopyInit */
void   somDefaultCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor. Use this to make copies of objects for
 *  calling methods with "by-value" argument semantics.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultCopyInit)(SOMObjectClassData.somDefaultCopyInit))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultAssign */
CosStream_StreamableFactory*  somDefaultAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator. Use this to "assign" the state of one
 *  object to another.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultAssign)(SOMObjectClassData.somDefaultAssign))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstCopyInit */
void   somDefaultConstCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultConstCopyInit)(SOMObjectClassData.somDefaultConstCopyInit))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultVCopyInit */
void   somDefaultVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultVCopyInit)(SOMObjectClassData.somDefaultVCopyInit))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* initializer method: somDefaultConstVCopyInit */
void   somDefaultConstVCopyInit(som3InitCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default copy constructor that uses a const volatile fromObj.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultConstVCopyInit)(SOMObjectClassData.somDefaultConstVCopyInit))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstAssign */
CosStream_StreamableFactory*  somDefaultConstAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultConstAssign)(SOMObjectClassData.somDefaultConstAssign))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultVAssign */
CosStream_StreamableFactory*  somDefaultVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultVAssign)(SOMObjectClassData.somDefaultVAssign))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somDefaultConstVAssign */
CosStream_StreamableFactory*  somDefaultConstVAssign(som3AssignCtrl* ctrl, 
		SOMObject* fromObj)
{
/*
 *  A default assignment operator that uses a const volatile fromObj.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDefaultConstVAssign)(SOMObjectClassData.somDefaultConstVAssign))(((CosStream_StreamableFactory *)((void *)this)),ctrl,fromObj)
	);
}


/* method: somInit */
void   somInit()
{
/*
 *  Obsolete but still supported. Override somDefaultInit instead of somInit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somInit)(SOMObjectClassData.somInit))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somUninit */
void   somUninit()
{
/*
 *  Obsolete but still supported. Override somDestruct instead of somUninit.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somUninit)(SOMObjectClassData.somUninit))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somFree */
void   somFree()
{
/*
 *  The default implementation just calls somDestruct.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somFree)(SOMObjectClassData.somFree))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somGetClass */
SOMClass*   somGetClass()
{
/*
 *  Return the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somGetClass)(SOMObjectClassData.somGetClass))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somGetClassName */
string   somGetClassName()
{
/*
 *  Return the name of the receiver's class.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somGetClassName)(SOMObjectClassData.somGetClassName))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somGetSize */
long   somGetSize()
{
/*
 *  Return the size of the receiver.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somGetSize)(SOMObjectClassData.somGetSize))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somIsA */
boolean   somIsA(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver responds to methods
 *  introduced by <aClassObj>, and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somIsA)(SOMObjectClassData.somIsA))(((CosStream_StreamableFactory *)((void *)this)),aClassObj)
	);
}


/* method: somIsInstanceOf */
boolean   somIsInstanceOf(SOMClass* aClassObj)
{
/*
 *  Returns 1 (true) if the receiver is an instance of
 *  <aClassObj> and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somIsInstanceOf)(SOMObjectClassData.somIsInstanceOf))(((CosStream_StreamableFactory *)((void *)this)),aClassObj)
	);
}


/* method: somRespondsTo */
boolean   somRespondsTo(somId mId)
{
/*
 *  Returns 1 (true) if the indicated method can be invoked
 *  on the receiver and 0 (false) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somRespondsTo)(SOMObjectClassData.somRespondsTo))(((CosStream_StreamableFactory *)((void *)this)),mId)
	);
}


/* va_list method: somDispatch */

/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
/* the va_list invocation form */
boolean   SOMObject_somDispatch(somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDispatch)(SOMObjectClassData.somDispatch))(((CosStream_StreamableFactory *)((void *)this)),retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somDispatch(somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  This method provides a generic, class-specific dispatch mechanism.
 *  It accepts as input <retValue> a pointer to the memory area to be
 *  loaded with the result of dispatching the method indicated by
 *  <methodId> using the arguments in <ap>. <ap> contains the object
 *  on which the method is to be invoked as the first argument.
 * 
 *  Default redispatch stubs invoke this method.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDispatch)(SOMObjectClassData.somDispatch))(((CosStream_StreamableFactory *)((void *)this)),retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* va_list method: somClassDispatch */

/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
/* the va_list invocation form */
boolean   SOMObject_somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		va_list ap)
{   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosStream_StreamableFactory *)((void *)this)),clsObj,retValue,methodId,ap)
	);
}

/* the varargs invocation form */
boolean   somClassDispatch(SOMClass* clsObj, 
		somToken* retValue, 
		somId methodId, 
		...)
{
/*
 *  Like somDispatch, but method resolution for static methods is done
 *  according to the clsObj instance method table.
 */
   va_list ap;
   va_start(ap, methodId);
   boolean __somResult = 
      	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somClassDispatch)(SOMObjectClassData.somClassDispatch))(((CosStream_StreamableFactory *)((void *)this)),clsObj,retValue,methodId,ap)
	);
   va_end(ap);
   return __somResult;
}


/* method: somCastObj */
boolean   somCastObj(SOMClass* castedCls)
{
/*
 *  Changes the behavior of the target object to that implemented
 *  by castedCls. This is possible when all concrete data in castedCls
 *  is also concrete in the true class of the target object.
 *  Returns true (1) on success, and false (0) otherwise.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somCastObj)(SOMObjectClassData.somCastObj))(((CosStream_StreamableFactory *)((void *)this)),castedCls)
	);
}


/* method: somResetObj */
boolean   somResetObj()
{
/*
 *  reset an object to its true class. Returns true always.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somResetObj)(SOMObjectClassData.somResetObj))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somPrintSelf */
CosStream_StreamableFactory*  somPrintSelf()
{
/*
 *  Uses <SOMOutCharRoutine> to write a brief string with identifying
 *  information about this object.  The default implementation just gives
 *  the object's class name and its address in memory.
 *  <self> is returned.
 */
   return 	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somPrintSelf)(SOMObjectClassData.somPrintSelf))(((CosStream_StreamableFactory *)((void *)this)))
	);
}


/* method: somDumpSelf */
void   somDumpSelf(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write a detailed description of this object
 *  and its current state.
 * 
 *  <level> indicates the nesting level for describing compound objects
 *  it must be greater than or equal to zero.  All lines in the
 *  description will be preceeded by <2*level> spaces.
 * 
 *  This routine only actually writes the data that concerns the object
 *  as a whole, such as class, and uses <somDumpSelfInt> to describe
 *  the object's current state.  This approach allows readable
 *  descriptions of compound objects to be constructed.
 * 
 *  Generally it is not necessary to override this method, if it is
 *  overriden it generally must be completely replaced.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDumpSelf)(SOMObjectClassData.somDumpSelf))(((CosStream_StreamableFactory *)((void *)this)),level)
	);
}


/* method: somDumpSelfInt */
void   somDumpSelfInt(long level)
{
/*
 *  Uses <SOMOutCharRoutine> to write in the current state of this object.
 *  Generally this method will need to be overridden.  When overriding
 *  it, begin by calling the parent class form of this method and then
 *  write in a description of your class's instance data. This will
 *  result in a description of all the object's instance data going
 *  from its root ancestor class to its specific class.
 */
   	(
	 SOM_TestCls(this,_SOMCLASS_SOMObject),
	 ((somTD_CosStream_StreamableFactory_somDumpSelfInt)(SOMObjectClassData.somDumpSelfInt))(((CosStream_StreamableFactory *)((void *)this)),level)
	);
}



};   /* CosStream_StreamableFactory */



#endif       /* SOM_CosStream_StreamableFactory_xh */
