home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
som30tk.zip
/
som30os2.zip
/
include
/
implrep.idl
< prev
next >
Wrap
Text File
|
1996-12-24
|
12KB
|
298 lines
/*
* @(#) 2.36 src/somd/implrep.idl, somd, som3.0 9/26/96 14:01:57 [12/24/96 07:39:25]
*/
//
// COMPONENT_NAME: somd
//
// ORIGINS: 27
//
//
// 25H7912 (C) COPYRIGHT International Business Machines Corp. 1992,1995,1996
// All Rights Reserved
// Licensed Materials - Property of IBM
// US Government Users Restricted Rights - Use, duplication or
// disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
//
#ifndef SOM_implrep_idl
#define SOM_implrep_idl
#include <somdtype.idl>
#include <impldef.idl>
interface ImplRepository : SOMObject
{
// CLASS SPECIFICATION FOR IMPLEMENTATION REPOSITORY
// The ImplRepository class contains methods which add/update/list/delete
// information from both the Implementation repository and the Name service.
typedef struct PV {
string name;
string value;
} PropertyValue;
typedef sequence<PropertyValue> PVList;
// This is a list of optional properties which are to be
// associated with a class name when registering with the Name Server.
ImplementationDef find_impldef(in ImplId implid);
// This method searches the Implementation Repository and returns
// an ImplementationDef object with the specified implid.
// OWNERSHIP of the return parameter is transferred to the caller.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_ClassNotFound
ImplementationDef find_impldef_by_alias(in string alias_name);
// This method searches the Implementation Repository and returns
// an ImplementationDef object with the specified name (alias).
// OWNERSHIP of the return parameter is transferred to the caller.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_ClassNotFound
ORBStatus find_all_aliases(out sequence<string> impl_aliases);
// This method searches the Implementation Repository and returns
// a sequence of impl_alias associated with all the impldef objects
// stored in the repository.
// The structure representing the sequence is created by the caller.
// OWNERSHIP of the _buffer field and every string in the buffer is
// transferred to the caller.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
ORBStatus find_all_impldefs(out sequence<ImplementationDef> outimpldefs);
// This method searches the Implementation Repository and returns
// all the ImplementationDef objects in it.
// The structure representing the sequence is created by the caller.
// OWNERSHIP of the _buffer field and every ImplementationDef object in
// the buffer is transferred to the caller.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_ClassNotFound
ORBStatus add_impldef(in ImplementationDef impldef);
// This method inserts an ImplementationDef object into the Implementation
// Repository. Also, a default class value is associated with this impl_id
// with the Name server if it is available.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_UnknownError
// 3. SOMDERROR_BadParm
// 4. SOMDERROR_NoDBInit
// 5. SOMDERROR_NoDBAvailable
// 6. SOMDERROR_AccessDenied
// 7. SOMDERROR_DuplicateEntry
// 8. SOMDERROR_CannotCreateUUID
// 9. SOMDERROR_NullImplAlias
// 10. SOMDERROR_NamingNotActive
ORBStatus update_impldef(in ImplementationDef impldef);
// This method replaces an ImplementationDef object in the Implementation
// Repository with the supplied object. The "impl_id" attribute of the
// supplied object is used to find the object to replace in the Impl.
// Repository. Also, the default value associated with this impl_id
// is updated in the Name server if it is available.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_DuplicateEntry
// 7. SOMDERROR_NullImplAlias
// 8. SOMDERROR_NamingNotActive
ORBStatus delete_impldef(in ImplId implid);
// This method deletes the ImplementationDef object with the specified
// implid from the Implementation Repository. Also, the default entry
// associated with this impl_id is deleted from the Name server if it
// is available.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_EntryNotFound
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_NullImplId
// 7. SOMDERROR_NamingNotActive
sequence<ImplementationDef> find_impldef_by_class(in string classname);
// This method with the help of the information in the Implementation
// repository and the Name service returns the sequence of
// ImplementationDef objects of servers that implement the desired class.
// OWNERSHIP for the _buffer field of the return sequence and
// for each element in the sequence is transferred to the caller.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_NamingNotActive
// 7. SOMDERROR_ClassNotFound
void add_class_to_impldef(in ImplId implid, in string classname);
// This method associates the "classname" with the ImplementationDef
// whose id is "implid". This is meant to indicate that the server
// (specified by the ImplementationDef) implements the named class.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_NamingNotActive
void remove_class_from_impldef(in ImplId implid, in string classname);
// This method removes the classname from the list of classnames
// associated with the ImplementationDef whose id is "implid".
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_NamingNotActive
void remove_class_from_all(in string classname);
// This method removes the classname from all the ImplementationDefs.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_NamingNotActive
sequence<string> find_classes_by_impldef(in ImplId implid);
// This method queries the Name service and returns the set of
// class names supported by a server with specified "implid".
// OWNERSHIP for the _buffer field in the return sequence
// and for each element in the sequence is transferred to the caller.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_ClassNotFound
// 7. SOMDERROR_NamingNotActive
ORBStatus add_class_to_all(in string classname);
// This method will associate the classname with all ImplementationDef
// objects in the repository.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_ClassNotFound
// 7. SOMDERROR_NamingNotActive
ORBStatus add_class_with_properties(in ImplId implid, in string classname,
in PVList pvl);
// This method associates the classname with the ImplementationDef
// whose id is "implid". This is meant to indicate that the server
// (specified by the ImplementationDef) implements the named class.
// In addition, the optional PVList sequenece will associate the
// specified properties and values with a class.
// The following minor codes are returned in the Environment structure:
// 1. SOMDERROR_NoMemory
// 2. SOMDERROR_BadParm
// 3. SOMDERROR_NoDBInit
// 4. SOMDERROR_NoDBAvailable
// 5. SOMDERROR_AccessDenied
// 6. SOMDERROR_ClassNotFound
// 7. SOMDERROR_NamingNotActive
#ifdef __SOMIDL__
implementation
{
releaseorder: find_impldef, find_impldef_by_alias,
find_impldef2, find_impldef_by_alias2,
find_impldef_by_class, add_impldef,
update_impldef, delete_impldef,
add_class_to_impldef,
remove_class_from_impldef, remove_class_from_all,
find_classes_by_impldef,
implr_get_impl, implr_search_impl,
implr_search_class, implr_update_impl,
find_all_impldefs,
find_all_aliases,
add_class_to_all,
add_class_with_properties;
//# Class Modifiers
callstyle = idl;
dllname = "somd.dll";
majorversion = 2;
minorversion = 2;
functionprefix = "ImplRep_";
//# Method Modifiers
override: somDefaultInit, somDestruct;
//# Passthrus
passthru C_h_after = ""
"#include <impldef.h>"
""
"#ifndef SOM_IMPORTEXPORT_somd"
"#if defined(_WIN32) && !defined(SOM_DLL_somd)"
"#define SOM_IMPORTEXPORT_somd SOMDLLIMPORT"
"#else"
"#define SOM_IMPORTEXPORT_somd"
"#endif"
"#endif"
"#ifdef SOM_STRICT_IDL"
"SOMEXTERN SOM_IMPORTEXPORT_somd ImplRepository SOMDLINK SOMD_ImplRepObject;"
"#else"
"SOMEXTERN SOM_IMPORTEXPORT_somd ImplRepository * SOMDLINK SOMD_ImplRepObject;"
"#endif /* SOM_STRICT_IDL */"
"";
passthru C_xh_after = ""
"class ImplRepository;"
"#include <impldef.xh>"
""
"#ifndef SOM_IMPORTEXPORT_somd"
"#if defined(_WIN32) && !defined(SOM_DLL_somd)"
"#define SOM_IMPORTEXPORT_somd SOMDLLIMPORT"
"#else"
"#define SOM_IMPORTEXPORT_somd"
"#endif"
"#endif"
"SOMEXTERN SOM_IMPORTEXPORT_somd ImplRepository * SOMDLINK SOMD_ImplRepObject;"
"";
};
#endif /* __SOMIDL__ */
};
#endif /* SOM_implrep_idl */