version 1.4, 2005/02/25 21:44:19
|
version 1.16, 2006/09/20 20:47:44
|
|
|
//%2005//////////////////////////////////////////////////////////////////////// |
//%2006//////////////////////////////////////////////////////////////////////// |
// | // |
// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development | // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development |
// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems. | // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems. |
|
|
// IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group. | // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group. |
// Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.; | // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.; |
// EMC Corporation; VERITAS Software Corporation; The Open Group. | // EMC Corporation; VERITAS Software Corporation; The Open Group. |
|
// Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.; |
|
// EMC Corporation; Symantec Corporation; The Open Group. |
// | // |
// Permission is hereby granted, free of charge, to any person obtaining a copy | // Permission is hereby granted, free of charge, to any person obtaining a copy |
// of this software and associated documentation files (the "Software"), to | // of this software and associated documentation files (the "Software"), to |
|
|
// | // |
//============================================================================== | //============================================================================== |
// | // |
// Author: Chip Vincent (cvincent@us.ibm.com) |
|
// |
|
// Modified By: Yi Zhou, Hewlett-Packard Company(yi_zhou@hp.com) |
|
// Mike Day, IBM (mdday@us.ibm.com) |
|
// Adrian Schuur, schuur@de.ibm.com |
|
// |
|
//%///////////////////////////////////////////////////////////////////////////// | //%///////////////////////////////////////////////////////////////////////////// |
| |
#ifndef Pegasus_JMPIProvider_h | #ifndef Pegasus_JMPIProvider_h |
#define Pegasus_JMPIProvider_h | #define Pegasus_JMPIProvider_h |
| |
#include "JMPIImpl.h" |
|
#include <Pegasus/Common/Config.h> | #include <Pegasus/Common/Config.h> |
#include <Pegasus/Common/IPC.h> |
|
#include <Pegasus/Provider/CIMOMHandle.h> | #include <Pegasus/Provider/CIMOMHandle.h> |
#include <Pegasus/Provider/CIMInstanceProvider.h> | #include <Pegasus/Provider/CIMInstanceProvider.h> |
#include <Pegasus/Provider/CIMAssociationProvider.h> | #include <Pegasus/Provider/CIMAssociationProvider.h> |
#include <Pegasus/Provider/CIMMethodProvider.h> | #include <Pegasus/Provider/CIMMethodProvider.h> |
|
#include <Pegasus/Common/AtomicInt.h> |
//#include <Pegasus/ProviderManager2/CMPI/CMPIResolverModule.h> |
|
| |
#include <Pegasus/Server/Linkage.h> | #include <Pegasus/Server/Linkage.h> |
|
#include <Pegasus/ProviderManager2/JMPI/Linkage.h> |
|
#include <Pegasus/ProviderManager2/JMPI/JMPIImpl.h> |
| |
PEGASUS_NAMESPACE_BEGIN | PEGASUS_NAMESPACE_BEGIN |
| |
class JMPIProviderModule; | class JMPIProviderModule; |
class CMPIResolverModule; |
|
| |
struct ProviderVector { | struct ProviderVector { |
jclass jProviderClass; | jclass jProviderClass; |
|
|
// provider module. It is wrapped in a facade to stabalize the interface | // provider module. It is wrapped in a facade to stabalize the interface |
// and is directly tied to a module. | // and is directly tied to a module. |
| |
class PEGASUS_SERVER_LINKAGE JMPIProvider : |
class PEGASUS_JMPIPM_LINKAGE JMPIProvider : |
public virtual CIMProvider | public virtual CIMProvider |
{ | { |
public: | public: |
|
|
| |
Status getStatus(void) const; | Status getStatus(void) const; |
String getName(void) const; | String getName(void) const; |
void setResolver(CMPIResolverModule *rm) { _rm=rm; } |
|
| |
JMPIProviderModule *getModule(void) const; | JMPIProviderModule *getModule(void) const; |
| |
// << Mon Oct 14 15:42:24 2002 mdd >> for use with DQueue template |
|
// to allow conversion from using Array<> |
|
Boolean operator == (const void *key) const; |
|
Boolean operator == (const JMPIProvider & prov) const; |
|
|
|
// virtual void get_idle_timer(struct timeval *); |
|
// virtual void update_idle_timer(void); |
|
// virtual Boolean pending_operation(void); |
|
// virtual Boolean unload_ok(void); | // virtual Boolean unload_ok(void); |
| |
// force provider manager to keep in memory | // force provider manager to keep in memory |
|
|
private: | private: |
friend class JMPILocalProviderManager; | friend class JMPILocalProviderManager; |
friend class JMPIProviderManager; | friend class JMPIProviderManager; |
friend class ProviderManagerService; |
class OpProviderHolder; |
// friend class OpProviderHolder; |
friend class OpProviderHolder; |
|
mutable Mutex _cimomMutex; |
|
/* NOTE: This is a C++ provider only handle which is currently |
|
** used for calls to ->getClass (). getClass returns |
|
** immediately with data and is therefore safe to lock. |
|
*/ |
CIMOMHandle *_cimom_handle; | CIMOMHandle *_cimom_handle; |
|
/* NOTE: This is the java provider's handle and is left |
|
** untouched. |
|
*/ |
|
CIMOMHandle *_java_cimom_handle; |
void *jProviderClass,*jProvider; | void *jProviderClass,*jProvider; |
String _name; | String _name; |
AtomicInt _no_unload; | AtomicInt _no_unload; |
CMPIResolverModule *_rm; |
|
Uint32 _quantum; | Uint32 _quantum; |
AtomicInt _current_operations; | AtomicInt _current_operations; |
|
mutable Mutex _statusMutex; |
| |
/** | /** |
Count of current subscriptions for this provider. Access to this | Count of current subscriptions for this provider. Access to this |