
/*
 * This file was generated by the SOM Compiler.
 * FileName: repostry.h.
 * Generated using:
 *     SOM Precompiler somipc: 2.29.1.19
 *     SOM Emitter emith.dll: 2.31.1.64
 */

#ifndef SOM_Repository_h
#define SOM_Repository_h


/*
 * The SOM_STRICT_IDL macro means that we can ignore stars
 * in our declarations of objects.
 */
#define SOM_STRICT_IDL 1


/*
 * Passthru lines: File: "C.h", "before"
 */

    #include <stdio.h>
    #include <somtcnst.h>
    #include <somir.h>
    #include <containd.h>


#include <som.h>
#ifndef SOM_IMPORTEXPORT_somir_repostry
#ifdef SOM_DLL_somir
	/* export semantics */
	#if defined(SOM_DEFFILE_somir)\
	||(defined(SOM_DEFFILE_BY_DEFAULT)&&!defined(SOM_NODEFFILE_somir))\
	|| !defined(SOM_Module_repostry_Source)
	#define SOM_IMPORTEXPORT_somir_repostry
	#else
	#define SOM_IMPORTEXPORT_somir_repostry SOMDLLEXPORT
	#endif
#else
	#define SOM_IMPORTEXPORT_somir_repostry SOMDLLIMPORT
#endif
#endif

/*
 * -- This emitter treats Method Tokens as Thunks by default.
 * -- Use the sc modifier "nothunks" to change this default
 */
#undef somresolve_
#define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))

/*
 * Define the class name as an object type
 */
#ifndef Repository
#define Repository SOMObject
#endif
/*
 *  The Repository interface provides global access to the SOM
 *  CORBA-compliant Interface Repository (IR).  To obtain an object
 *  reference to an instance of Repository, use the RepositoryNew
 *  function.
 * 
 *  See CORBA 1.1, 7.5.2, p.133
 */

/*
 * Include Parent Bindings
 */
#ifndef SOM_Container_h
#ifdef SOMLOCALINCLUDES
#include "containr.h"
#else
#include <containr.h>
#endif
#endif

/*
 * Start of bindings for IDL types
 */

#ifndef SOMClass
    #define SOMClass SOMObject
#endif /* SOMClass */
#ifndef Contained
    #define Contained SOMObject
#endif /* Contained */
typedef
struct Repository_RepositoryDescription {
Identifier name;
string  id;
string  defined_in;
} Repository_RepositoryDescription;
/*
 *  The inherited describe_contents method returns an instance
 *  of this (RepositoryDescription) structure in the value
 *  member of the Description structure defined in the Container
 *  interface.
 */

typedef unsigned long Repository_irOpenErrorCodes;
#define Repository_NOACCESS 1UL
#define Repository_BADMAGICNUMBER 2UL
#define Repository_MISSINGVERSIONINFO 3UL
#define Repository_IOERROR 4UL
#define Repository_VERSIONMISMATCH 5UL
#define Repository_NOWRITEACCESS 6UL
#define Repository_INDEXINCONSISTENT 7UL
#define Repository_INDEXNOTPRESENT 8UL
/*
 *  @dcr13033
 */

#define ex_Repository_irOpenError "::Repository::irOpenError"
typedef
struct Repository_irOpenError {
Repository_irOpenErrorCodes errorCode;
string  fileName;
} Repository_irOpenError;
/*
 *  The irOpenError and associated irOpenErrorCodes are a
 *  SOM-unique extension to the Interface Repository.  These
 *  errors may be raised by the somNew when instantiating the
 *  Repository object and can be found in the SOM global
 *  Environment if the returned Repository object is NULL (meaning
 *  no Repository object could be created). When the Repository
 *  object is not NULL, use the queryException method to place any
 *  exception info into a user-supplied Environment
 *  (see queryException below).
 */


#ifndef SOM_DONT_USE_SHORT_NAMES
#ifndef SOMTGD_RepositoryDescription
    #ifdef RepositoryDescription
        #undef RepositoryDescription
        #define SOMTGD_RepositoryDescription 1
    #else
        #define RepositoryDescription Repository_RepositoryDescription
    #endif /* RepositoryDescription */
#endif /* SOMTGD_RepositoryDescription */
#ifndef SOMTGD_irOpenErrorCodes
    #ifdef irOpenErrorCodes
        #undef irOpenErrorCodes
        #define SOMTGD_irOpenErrorCodes 1
    #else
        #define irOpenErrorCodes Repository_irOpenErrorCodes
    #endif /* irOpenErrorCodes */
#endif /* SOMTGD_irOpenErrorCodes */
#ifndef SOMTGD_ex_irOpenError
    #ifdef ex_irOpenError
        #undef ex_irOpenError
        #define SOMTGD_ex_irOpenError 1
    #else
        #define ex_irOpenError ex_Repository_irOpenError
    #endif /* ex_irOpenError */
#endif /* SOMTGD_ex_irOpenError */
#ifndef SOMTGD_irOpenError
    #ifdef irOpenError
        #undef irOpenError
        #define SOMTGD_irOpenError 1
    #else
        #define irOpenError Repository_irOpenError
    #endif /* irOpenError */
#endif /* SOMTGD_irOpenError */
#endif /* SOM_DONT_USE_SHORT_NAMES */

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

#define Repository_MajorVersion 2
#define Repository_MinorVersion 3

/*
 * Declare the class creation procedure
 */
SOMEXTERN SOM_IMPORTEXPORT_somir_repostry SOMClass  SOMLINK RepositoryNewClass(integer4 somtmajorVersion,
		integer4 somtminorVersion);

/*
 * Declare the ABI 2 ClassData structure
 */
SOMEXTERN struct RepositoryClassDataStructure {
	SOMClass classObject;
	somMToken lookup_id;
	somMToken lookup_modifier;
	somMToken release_cache;
	somMToken reserved1;
	somMToken reserved2;
	somMToken reserved3;
	somMToken queryException;
} SOM_IMPORTEXPORT_somir_repostry SOMDLINK RepositoryClassData;

/*
 * Declare the ABI 2 CClassData structure
 */
SOMEXTERN struct RepositoryCClassDataStructure {
	somMethodTabs parentMtab;
	somDToken instanceDataToken;
} SOM_IMPORTEXPORT_somir_repostry SOMDLINK RepositoryCClassData;

/*
 * Class Object and Method Token Macros
 */
#define _SOMCLASS_Repository (RepositoryClassData.classObject)
#ifndef SOMGD_Repository
    #if (defined(_Repository) || defined(__Repository))
        #undef _Repository
        #undef __Repository
        #define SOMGD_Repository 1
    #else
        #define _Repository _SOMCLASS_Repository
    #endif /* _Repository */
#endif /* SOMGD_Repository */
#define Repository_classObj _SOMCLASS_Repository
#define _SOMMTOKEN_Repository(method) ((somMToken)RepositoryClassData.method)

/*
 * New and Renew macros for Repository
 */
#define RepositoryNew() \
   ( _Repository ? \
	_somNew(_Repository) \
	: ( RepositoryNewClass(\
		Repository_MajorVersion, \
		Repository_MinorVersion),\
	   _somNew(_Repository)))
#define RepositoryRenew(buf) \
   ( _Repository ? \
	_somRenew(_Repository, buf) \
	: ( RepositoryNewClass(\
		Repository_MajorVersion, \
		Repository_MinorVersion),\
	   _somRenew(_Repository, buf)))

/*
 * New Method: lookup_id
 */
typedef Contained   SOMLINK somTP_Repository_lookup_id(Repository somSelf, Environment *ev, 
		string search_id);
typedef somTP_Repository_lookup_id *somTD_Repository_lookup_id;
/*
 *  Returns the object with a RepositoryId given by search_id.
 */
#define somMD_Repository_lookup_id "::Repository::lookup_id"
#define Repository_lookup_id(somSelf,ev,search_id) \
    (SOM_Resolve(somSelf, Repository, lookup_id) \
	(somSelf,ev,search_id))
#ifndef SOMGD_lookup_id
    #if (defined(_lookup_id) || defined(__lookup_id))
        #undef _lookup_id
        #undef __lookup_id
        #define SOMGD_lookup_id 1
    #else
        #define _lookup_id Repository_lookup_id
    #endif /* _lookup_id */
#endif /* SOMGD_lookup_id */

/*
 * New Method: lookup_modifier
 */
typedef string   SOMLINK somTP_Repository_lookup_modifier(Repository somSelf, Environment *ev, 
		string name, 
		string modifier);
typedef somTP_Repository_lookup_modifier *somTD_Repository_lookup_modifier;
/*
 *  [SOM-unique extension]
 * 
 *  Returns the value string associated with the given SOM modifier
 *  for the object whose id is specified.  If the object does not
 *  exist or does not possess the modifier, NULL (or zero) is returned.
 *  If the modifier exists but does not have a value, a zero-length
 *  value string is returned.
 * 
 *  You must free the returned string when finished with it (using
 *  SOMFree).
 */
#define somMD_Repository_lookup_modifier "::Repository::lookup_modifier"
#define Repository_lookup_modifier(somSelf,ev,name,modifier) \
    (SOM_Resolve(somSelf, Repository, lookup_modifier) \
	(somSelf,ev,name,modifier))
#ifndef SOMGD_lookup_modifier
    #if (defined(_lookup_modifier) || defined(__lookup_modifier))
        #undef _lookup_modifier
        #undef __lookup_modifier
        #define SOMGD_lookup_modifier 1
    #else
        #define _lookup_modifier Repository_lookup_modifier
    #endif /* _lookup_modifier */
#endif /* SOMGD_lookup_modifier */

/*
 * New Method: release_cache
 */
typedef void   SOMLINK somTP_Repository_release_cache(Repository somSelf, Environment *ev);
typedef somTP_Repository_release_cache *somTD_Repository_release_cache;
/*
 *  [SOM-unique extension]
 * 
 *  This method releases all currently unreferenced Interface Repository
 *  objects from the internal object cache.	This may release some storage
 *  at the cost of slowing down (slightly) the next few lookup operations.
 *  The internal cache will replenish itself (over time) with each
 *  subsequent lookup operation.
 */
#define somMD_Repository_release_cache "::Repository::release_cache"
#define Repository_release_cache(somSelf,ev) \
    (SOM_Resolve(somSelf, Repository, release_cache) \
	(somSelf,ev))
#ifndef SOMGD_release_cache
    #if (defined(_release_cache) || defined(__release_cache))
        #undef _release_cache
        #undef __release_cache
        #define SOMGD_release_cache 1
    #else
        #define _release_cache Repository_release_cache
    #endif /* _release_cache */
#endif /* SOMGD_release_cache */

/*
 * New Method: queryException
 */
typedef boolean   SOMLINK somTP_Repository_queryException(Repository somSelf, Environment *ev);
typedef somTP_Repository_queryException *somTD_Repository_queryException;
/*
 *  [SOM-unique extension]
 * 
 *  This method returns TRUE if an exception condition was
 *  raised during the creation of the Repository object, otherwise
 *  it returns FALSE.  When the result is TRUE, the actual
 *  exception info may be found in the Environment passed in to
 *  the queryException operation.
 */
#define somMD_Repository_queryException "::Repository::queryException"
#define Repository_queryException(somSelf,ev) \
    (SOM_Resolve(somSelf, Repository, queryException) \
	(somSelf,ev))
#ifndef SOMGD_queryException
    #if (defined(_queryException) || defined(__queryException))
        #undef _queryException
        #undef __queryException
        #define SOMGD_queryException 1
    #else
        #define _queryException Repository_queryException
    #endif /* _queryException */
#endif /* SOMGD_queryException */

/*
 * Full Names for Inherited Methods
 */
/* overridden methods */
#define Repository_describe_contents Container_describe_contents
#define Repository_somDumpSelf SOMObject_somDumpSelf
#define Repository_somDumpSelfInt SOMObject_somDumpSelfInt
#define Repository_somDefaultCopyInit SOMObject_somDefaultCopyInit
#define Repository_somFree SOMObject_somFree

#ifndef SOM_DONT_USE_INHERITED_MACROS
#define Repository_contents Container_contents
#define Repository_lookup_name Container_lookup_name
#define Repository_somDefaultInit SOMObject_somDefaultInit
#define Repository_somDestruct SOMObject_somDestruct
#define Repository_somDefaultAssign SOMObject_somDefaultAssign
#define Repository_somDefaultConstCopyInit SOMObject_somDefaultConstCopyInit
#define Repository_somDefaultVCopyInit SOMObject_somDefaultVCopyInit
#define Repository_somDefaultConstVCopyInit SOMObject_somDefaultConstVCopyInit
#define Repository_somDefaultConstAssign SOMObject_somDefaultConstAssign
#define Repository_somDefaultVAssign SOMObject_somDefaultVAssign
#define Repository_somDefaultConstVAssign SOMObject_somDefaultConstVAssign
#define Repository_somInit SOMObject_somInit
#define Repository_somUninit SOMObject_somUninit
#define Repository_somGetClass SOMObject_somGetClass
#define Repository_somGetClassName SOMObject_somGetClassName
#define Repository_somGetSize SOMObject_somGetSize
#define Repository_somIsA SOMObject_somIsA
#define Repository_somIsInstanceOf SOMObject_somIsInstanceOf
#define Repository_somRespondsTo SOMObject_somRespondsTo
#define Repository_somDispatch SOMObject_somDispatch
#define Repository_somClassDispatch SOMObject_somClassDispatch
#define Repository_somCastObj SOMObject_somCastObj
#define Repository_somResetObj SOMObject_somResetObj
#define Repository_somPrintSelf SOMObject_somPrintSelf
#endif /* SOM_DONT_USE_INHERITED_MACROS */

#endif       /* SOM_Repository_h */
