mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0029220: Application Framework - replace CDM_MessageDriver interface by Message_Messenger.
This commit is contained in:
@@ -18,14 +18,14 @@
|
||||
#include <BinMDF_ADriverTable.hxx>
|
||||
#include <BinMDF_ReferenceDriver.hxx>
|
||||
#include <BinMDF_TagSourceDriver.hxx>
|
||||
#include <CDM_MessageDriver.hxx>
|
||||
#include <Message_Messenger.hxx>
|
||||
|
||||
//=======================================================================
|
||||
//function : AddDrivers
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void BinMDF::AddDrivers (const Handle(BinMDF_ADriverTable)& aDriverTable,
|
||||
const Handle(CDM_MessageDriver)& aMsgDrv)
|
||||
const Handle(Message_Messenger)& aMsgDrv)
|
||||
{
|
||||
aDriverTable->AddDriver (new BinMDF_ReferenceDriver (aMsgDrv) );
|
||||
aDriverTable->AddDriver (new BinMDF_TagSourceDriver (aMsgDrv) );
|
||||
|
@@ -21,7 +21,7 @@
|
||||
#include <Standard_Handle.hxx>
|
||||
|
||||
class BinMDF_ADriverTable;
|
||||
class CDM_MessageDriver;
|
||||
class Message_Messenger;
|
||||
class BinMDF_ADriver;
|
||||
class BinMDF_ReferenceDriver;
|
||||
class BinMDF_TagSourceDriver;
|
||||
@@ -52,7 +52,7 @@ public:
|
||||
|
||||
|
||||
//! Adds the attribute storage drivers to <aDriverTable>.
|
||||
Standard_EXPORT static void AddDrivers (const Handle(BinMDF_ADriverTable)& aDriverTable, const Handle(CDM_MessageDriver)& aMsgDrv);
|
||||
Standard_EXPORT static void AddDrivers (const Handle(BinMDF_ADriverTable)& aDriverTable, const Handle(Message_Messenger)& aMsgDrv);
|
||||
|
||||
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
|
||||
#include <BinMDF_ADriver.hxx>
|
||||
#include <BinObjMgt_Persistent.hxx>
|
||||
#include <CDM_MessageDriver.hxx>
|
||||
#include <Message_Messenger.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
#include <TCollection_AsciiString.hxx>
|
||||
#include <TCollection_ExtendedString.hxx>
|
||||
@@ -28,20 +28,10 @@ IMPLEMENT_STANDARD_RTTIEXT(BinMDF_ADriver,Standard_Transient)
|
||||
//function : BinMDF_ADriver
|
||||
//purpose : Constructor
|
||||
//=======================================================================
|
||||
BinMDF_ADriver::BinMDF_ADriver (const Handle(CDM_MessageDriver)& theMsgDriver,
|
||||
BinMDF_ADriver::BinMDF_ADriver (const Handle(Message_Messenger)& theMsgDriver,
|
||||
const Standard_CString theName)
|
||||
: myMessageDriver (theMsgDriver)
|
||||
{
|
||||
if (theName)
|
||||
myTypeName = theName;
|
||||
}
|
||||
//=======================================================================
|
||||
//function : WriteMessage
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
void BinMDF_ADriver::WriteMessage
|
||||
(const TCollection_ExtendedString& aMessage) const
|
||||
{
|
||||
myMessageDriver -> Write (aMessage.ToExtString());
|
||||
}
|
||||
}
|
@@ -26,7 +26,7 @@
|
||||
#include <Standard_Boolean.hxx>
|
||||
#include <BinObjMgt_RRelocationTable.hxx>
|
||||
#include <BinObjMgt_SRelocationTable.hxx>
|
||||
class CDM_MessageDriver;
|
||||
class Message_Messenger;
|
||||
class TDF_Attribute;
|
||||
class TCollection_AsciiString;
|
||||
class BinObjMgt_Persistent;
|
||||
@@ -62,11 +62,6 @@ public:
|
||||
//! into <aTarget>, using the relocation table
|
||||
//! <aRelocTable> to keep the sharings.
|
||||
Standard_EXPORT virtual void Paste (const Handle(TDF_Attribute)& aSource, BinObjMgt_Persistent& aTarget, BinObjMgt_SRelocationTable& aRelocTable) const = 0;
|
||||
|
||||
//! Send message to Application (usually when error occurres)
|
||||
Standard_EXPORT void WriteMessage (const TCollection_ExtendedString& theMessage) const;
|
||||
|
||||
|
||||
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(BinMDF_ADriver,Standard_Transient)
|
||||
@@ -74,15 +69,11 @@ public:
|
||||
protected:
|
||||
|
||||
|
||||
Standard_EXPORT BinMDF_ADriver(const Handle(CDM_MessageDriver)& theMsgDriver, const Standard_CString theName = NULL);
|
||||
Standard_EXPORT BinMDF_ADriver(const Handle(Message_Messenger)& theMsgDriver, const Standard_CString theName = NULL);
|
||||
|
||||
TCollection_AsciiString myTypeName;
|
||||
|
||||
|
||||
private:
|
||||
|
||||
|
||||
Handle(CDM_MessageDriver) myMessageDriver;
|
||||
Handle(Message_Messenger) myMessageDriver;
|
||||
|
||||
|
||||
};
|
||||
|
@@ -16,7 +16,7 @@
|
||||
|
||||
#include <BinMDF_ReferenceDriver.hxx>
|
||||
#include <BinObjMgt_Persistent.hxx>
|
||||
#include <CDM_MessageDriver.hxx>
|
||||
#include <Message_Messenger.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
#include <TDF_Attribute.hxx>
|
||||
#include <TDF_Reference.hxx>
|
||||
@@ -28,7 +28,7 @@ IMPLEMENT_STANDARD_RTTIEXT(BinMDF_ReferenceDriver,BinMDF_ADriver)
|
||||
//purpose : Constructor
|
||||
//=======================================================================
|
||||
BinMDF_ReferenceDriver::BinMDF_ReferenceDriver
|
||||
(const Handle(CDM_MessageDriver)& theMsgDriver)
|
||||
(const Handle(Message_Messenger)& theMsgDriver)
|
||||
: BinMDF_ADriver (theMsgDriver, STANDARD_TYPE(TDF_Reference)->Name())
|
||||
{
|
||||
}
|
||||
|
@@ -23,7 +23,7 @@
|
||||
#include <Standard_Boolean.hxx>
|
||||
#include <BinObjMgt_RRelocationTable.hxx>
|
||||
#include <BinObjMgt_SRelocationTable.hxx>
|
||||
class CDM_MessageDriver;
|
||||
class Message_Messenger;
|
||||
class TDF_Attribute;
|
||||
class BinObjMgt_Persistent;
|
||||
|
||||
@@ -38,7 +38,7 @@ class BinMDF_ReferenceDriver : public BinMDF_ADriver
|
||||
public:
|
||||
|
||||
|
||||
Standard_EXPORT BinMDF_ReferenceDriver(const Handle(CDM_MessageDriver)& theMessageDriver);
|
||||
Standard_EXPORT BinMDF_ReferenceDriver(const Handle(Message_Messenger)& theMessageDriver);
|
||||
|
||||
Standard_EXPORT virtual Handle(TDF_Attribute) NewEmpty() const Standard_OVERRIDE;
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
|
||||
#include <BinMDF_TagSourceDriver.hxx>
|
||||
#include <BinObjMgt_Persistent.hxx>
|
||||
#include <CDM_MessageDriver.hxx>
|
||||
#include <Message_Messenger.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
#include <TDF_Attribute.hxx>
|
||||
#include <TDF_TagSource.hxx>
|
||||
@@ -28,7 +28,7 @@ IMPLEMENT_STANDARD_RTTIEXT(BinMDF_TagSourceDriver,BinMDF_ADriver)
|
||||
//purpose : Constructor
|
||||
//=======================================================================
|
||||
BinMDF_TagSourceDriver::BinMDF_TagSourceDriver
|
||||
(const Handle(CDM_MessageDriver)& theMsgDriver)
|
||||
(const Handle(Message_Messenger)& theMsgDriver)
|
||||
: BinMDF_ADriver (theMsgDriver, NULL)
|
||||
{}
|
||||
|
||||
|
@@ -23,7 +23,7 @@
|
||||
#include <Standard_Boolean.hxx>
|
||||
#include <BinObjMgt_RRelocationTable.hxx>
|
||||
#include <BinObjMgt_SRelocationTable.hxx>
|
||||
class CDM_MessageDriver;
|
||||
class Message_Messenger;
|
||||
class TDF_Attribute;
|
||||
class BinObjMgt_Persistent;
|
||||
|
||||
@@ -38,7 +38,7 @@ class BinMDF_TagSourceDriver : public BinMDF_ADriver
|
||||
public:
|
||||
|
||||
|
||||
Standard_EXPORT BinMDF_TagSourceDriver(const Handle(CDM_MessageDriver)& theMessageDriver);
|
||||
Standard_EXPORT BinMDF_TagSourceDriver(const Handle(Message_Messenger)& theMessageDriver);
|
||||
|
||||
Standard_EXPORT Handle(TDF_Attribute) NewEmpty() const Standard_OVERRIDE;
|
||||
|
||||
|
Reference in New Issue
Block a user