mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0024002: Overall code and build procedure refactoring -- automatic
Automatic upgrade of OCCT code by command "occt_upgrade . -nocdl": - WOK-generated header files from inc and sources from drv are moved to src - CDL files removed - All packages are converted to nocdlpack
This commit is contained in:
123
src/DDF/DDF.cdl
123
src/DDF/DDF.cdl
@@ -1,123 +0,0 @@
|
||||
-- Created by: DAUTRY Philippe
|
||||
-- Copyright (c) 1997-1999 Matra Datavision
|
||||
-- Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
--
|
||||
-- This file is part of Open CASCADE Technology software library.
|
||||
--
|
||||
-- This library is free software; you can redistribute it and/or modify it under
|
||||
-- the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
-- by the Free Software Foundation, with special exception defined in the file
|
||||
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
-- distribution for complete text of the license and disclaimer of any warranty.
|
||||
--
|
||||
-- Alternatively, this file may be used under the terms of Open CASCADE
|
||||
-- commercial license or contractual agreement.
|
||||
|
||||
-- -------
|
||||
|
||||
---Version: 0.0
|
||||
--Version Date Purpose
|
||||
-- 0.0 Feb 10 1997 Creation
|
||||
|
||||
|
||||
|
||||
package DDF
|
||||
|
||||
---Purpose: Provides facilities to manipulate data framework
|
||||
-- in a Draw-Commands environment.
|
||||
|
||||
uses
|
||||
|
||||
Standard,
|
||||
Draw,
|
||||
TCollection,
|
||||
TDF
|
||||
|
||||
is
|
||||
|
||||
-- ----------------------------------------------------------------------
|
||||
-- Classes
|
||||
-- ----------------------------------------------------------------------
|
||||
|
||||
class Data;
|
||||
|
||||
class Browser;
|
||||
|
||||
class Transaction;
|
||||
|
||||
imported TransactionStack;
|
||||
|
||||
imported ListIteratorOfTransactionStack;
|
||||
|
||||
-- ----------------------------------------------------------------------
|
||||
-- Package methods
|
||||
-- ----------------------------------------------------------------------
|
||||
|
||||
|
||||
GetDF (Name : in out CString from Standard;
|
||||
DF : in out Data from TDF;
|
||||
Complain : in Boolean from Standard = Standard_True)
|
||||
returns Boolean;
|
||||
---Purpose: Search in draw directory the framewok identified
|
||||
-- by its name <Name>. returns True if found. In that
|
||||
-- case <DF> is setted.
|
||||
|
||||
|
||||
FindLabel (DF : in Data from TDF;
|
||||
Entry : in CString from Standard;
|
||||
Label : in out Label from TDF;
|
||||
Complain : in Boolean from Standard = Standard_True)
|
||||
returns Boolean;
|
||||
---Purpose: Search in <DF> the label identified by its entry
|
||||
-- <Entry>. returns <True> if found. In that case
|
||||
-- <Label> is setted.
|
||||
|
||||
AddLabel (DF : in Data from TDF;
|
||||
Entry : in CString from Standard;
|
||||
Label : in out Label from TDF)
|
||||
returns Boolean;
|
||||
---Purpose : Search in <DF> the label identified by its entry
|
||||
-- <Entry>. if label doesn't exist, create and add
|
||||
-- the Label in <DF>. In that case return True.
|
||||
|
||||
|
||||
Find (DF : in Data from TDF;
|
||||
Entry : in CString from Standard;
|
||||
ID : in GUID from Standard;
|
||||
A : in out Attribute from TDF;
|
||||
Complain : Boolean from Standard = Standard_True)
|
||||
returns Boolean;
|
||||
---Purpose: Search in <DF> the attribute identified by its
|
||||
-- <ID> and its <entry>. returns <True> if found. In
|
||||
-- that case A is setted.
|
||||
|
||||
|
||||
ReturnLabel(theCommands : in out Interpretor from Draw; L : Label from TDF)
|
||||
returns Interpretor from Draw;
|
||||
---C++: return &
|
||||
|
||||
-- ----------------------------------------------------------------------
|
||||
-- Commands
|
||||
-- ----------------------------------------------------------------------
|
||||
|
||||
AllCommands (theCommands : in out Interpretor from Draw);
|
||||
|
||||
|
||||
BasicCommands (theCommands : in out Interpretor from Draw);
|
||||
---Purpose : Basic commands.
|
||||
|
||||
DataCommands (theCommands : in out Interpretor from Draw);
|
||||
---Purpose : Data framework commands
|
||||
-- create, clear & copy.
|
||||
|
||||
TransactionCommands (theCommands : in out Interpretor from Draw);
|
||||
---Purpose : open commit abort a transaction
|
||||
-- undo facilities.
|
||||
|
||||
BrowserCommands (theCommands : in out Interpretor from Draw);
|
||||
---Purpose : Browser commands .
|
||||
|
||||
end DDF;
|
||||
|
||||
|
||||
|
@@ -14,25 +14,21 @@
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
// -------
|
||||
|
||||
// Version: 0.0
|
||||
//Version Date Purpose
|
||||
// 0.0 Feb 10 1997 Creation
|
||||
|
||||
|
||||
|
||||
#include <DDF.ixx>
|
||||
|
||||
#include <DDF.hxx>
|
||||
#include <DDF_Data.hxx>
|
||||
|
||||
#include <Draw.hxx>
|
||||
|
||||
#include <Standard_GUID.hxx>
|
||||
#include <TCollection_AsciiString.hxx>
|
||||
#include <TColStd_HArray1OfInteger.hxx>
|
||||
#include <TColStd_ListIteratorOfListOfInteger.hxx>
|
||||
#include <TColStd_ListOfInteger.hxx>
|
||||
#include <TCollection_AsciiString.hxx>
|
||||
|
||||
#include <TDF_Attribute.hxx>
|
||||
#include <TDF_ChildIterator.hxx>
|
||||
#include <TDF_Data.hxx>
|
||||
#include <TDF_Label.hxx>
|
||||
#include <TDF_Tool.hxx>
|
||||
|
||||
@@ -40,7 +36,6 @@
|
||||
//function : AddLabel
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
Standard_Boolean DDF::AddLabel
|
||||
|
||||
(
|
||||
|
108
src/DDF/DDF.hxx
Normal file
108
src/DDF/DDF.hxx
Normal file
@@ -0,0 +1,108 @@
|
||||
// Created by: DAUTRY Philippe
|
||||
// Copyright (c) 1997-1999 Matra Datavision
|
||||
// Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it under
|
||||
// the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
// by the Free Software Foundation, with special exception defined in the file
|
||||
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
// distribution for complete text of the license and disclaimer of any warranty.
|
||||
//
|
||||
// Alternatively, this file may be used under the terms of Open CASCADE
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
#ifndef _DDF_HeaderFile
|
||||
#define _DDF_HeaderFile
|
||||
|
||||
#include <Standard.hxx>
|
||||
#include <Standard_DefineAlloc.hxx>
|
||||
#include <Standard_Handle.hxx>
|
||||
|
||||
#include <Standard_Boolean.hxx>
|
||||
#include <Standard_CString.hxx>
|
||||
#include <Draw_Interpretor.hxx>
|
||||
class TDF_Data;
|
||||
class TDF_Label;
|
||||
class Standard_GUID;
|
||||
class TDF_Attribute;
|
||||
class DDF_Data;
|
||||
class DDF_Browser;
|
||||
class DDF_Transaction;
|
||||
|
||||
|
||||
//! Provides facilities to manipulate data framework
|
||||
//! in a Draw-Commands environment.
|
||||
class DDF
|
||||
{
|
||||
public:
|
||||
|
||||
DEFINE_STANDARD_ALLOC
|
||||
|
||||
|
||||
//! Search in draw directory the framewok identified
|
||||
//! by its name <Name>. returns True if found. In that
|
||||
//! case <DF> is setted.
|
||||
Standard_EXPORT static Standard_Boolean GetDF (Standard_CString& Name, Handle(TDF_Data)& DF, const Standard_Boolean Complain = Standard_True);
|
||||
|
||||
//! Search in <DF> the label identified by its entry
|
||||
//! <Entry>. returns <True> if found. In that case
|
||||
//! <Label> is setted.
|
||||
Standard_EXPORT static Standard_Boolean FindLabel (const Handle(TDF_Data)& DF, const Standard_CString Entry, TDF_Label& Label, const Standard_Boolean Complain = Standard_True);
|
||||
|
||||
//! Search in <DF> the label identified by its entry
|
||||
//! <Entry>. if label doesn't exist, create and add
|
||||
//! the Label in <DF>. In that case return True.
|
||||
Standard_EXPORT static Standard_Boolean AddLabel (const Handle(TDF_Data)& DF, const Standard_CString Entry, TDF_Label& Label);
|
||||
|
||||
//! Search in <DF> the attribute identified by its
|
||||
//! <ID> and its <entry>. returns <True> if found. In
|
||||
//! that case A is setted.
|
||||
Standard_EXPORT static Standard_Boolean Find (const Handle(TDF_Data)& DF, const Standard_CString Entry, const Standard_GUID& ID, Handle(TDF_Attribute)& A, const Standard_Boolean Complain = Standard_True);
|
||||
|
||||
Standard_EXPORT static Draw_Interpretor& ReturnLabel (Draw_Interpretor& theCommands, const TDF_Label& L);
|
||||
|
||||
Standard_EXPORT static void AllCommands (Draw_Interpretor& theCommands);
|
||||
|
||||
//! Basic commands.
|
||||
Standard_EXPORT static void BasicCommands (Draw_Interpretor& theCommands);
|
||||
|
||||
//! Data framework commands
|
||||
//! create, clear & copy.
|
||||
Standard_EXPORT static void DataCommands (Draw_Interpretor& theCommands);
|
||||
|
||||
//! open commit abort a transaction
|
||||
//! undo facilities.
|
||||
Standard_EXPORT static void TransactionCommands (Draw_Interpretor& theCommands);
|
||||
|
||||
//! Browser commands .
|
||||
Standard_EXPORT static void BrowserCommands (Draw_Interpretor& theCommands);
|
||||
|
||||
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
private:
|
||||
|
||||
|
||||
|
||||
|
||||
friend class DDF_Data;
|
||||
friend class DDF_Browser;
|
||||
friend class DDF_Transaction;
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endif // _DDF_HeaderFile
|
@@ -1,110 +0,0 @@
|
||||
-- Created by: DAUTRY Philippe
|
||||
-- Copyright (c) 1997-1999 Matra Datavision
|
||||
-- Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
--
|
||||
-- This file is part of Open CASCADE Technology software library.
|
||||
--
|
||||
-- This library is free software; you can redistribute it and/or modify it under
|
||||
-- the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
-- by the Free Software Foundation, with special exception defined in the file
|
||||
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
-- distribution for complete text of the license and disclaimer of any warranty.
|
||||
--
|
||||
-- Alternatively, this file may be used under the terms of Open CASCADE
|
||||
-- commercial license or contractual agreement.
|
||||
|
||||
-- ---------------
|
||||
|
||||
---Version: 0.0
|
||||
--Version Date Purpose
|
||||
-- 0.0 Oct 3 1997 Creation
|
||||
|
||||
|
||||
class Browser from DDF inherits Drawable3D from Draw
|
||||
|
||||
---Purpose: Browses a data framework from TDF.
|
||||
|
||||
uses
|
||||
|
||||
Data from TDF,
|
||||
Label from TDF,
|
||||
AttributeIndexedMap from TDF,
|
||||
Interpretor from Draw,
|
||||
Display from Draw,
|
||||
AsciiString from TCollection
|
||||
|
||||
-- raises
|
||||
|
||||
is
|
||||
|
||||
Create (aDF : Data from TDF)
|
||||
returns Browser from DDF;
|
||||
|
||||
|
||||
DrawOn (me; dis : in out Display);
|
||||
|
||||
|
||||
Copy (me)
|
||||
returns Drawable3D from Draw
|
||||
is redefined;
|
||||
|
||||
Dump (me; S : in out OStream)
|
||||
is redefined;
|
||||
|
||||
Whatis (me; I : in out Interpretor from Draw)
|
||||
is redefined;
|
||||
|
||||
-- Specific methods -------------------------------------------------------
|
||||
|
||||
Data (me : mutable; aDF : Data from TDF);
|
||||
|
||||
Data (me)
|
||||
returns Data from TDF;
|
||||
|
||||
OpenRoot(me)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns a string composed with the sub-label
|
||||
-- entries of <myDF>.
|
||||
|
||||
OpenLabel(me; aLab : Label from TDF)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns a string composed with the sub-label
|
||||
-- entries of <aLab>.
|
||||
|
||||
OpenAttributeList(me : mutable;
|
||||
aLab : Label from TDF)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns a string composed with the attribute index
|
||||
-- (found in <myAttMap>) of <aLab>.
|
||||
|
||||
OpenAttribute(me : mutable;
|
||||
anIndex : Integer from Standard = 0)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns a string composed with the list of
|
||||
-- referenced attribute index of the attribute
|
||||
-- <anIndex>. For exemple, it is usefull for
|
||||
-- TDataStd_Group. It uses a mecanism based on a
|
||||
-- DDF_AttributeBrowser.
|
||||
|
||||
Information(me)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns information about <me> to be displayed in
|
||||
-- information window.
|
||||
|
||||
Information(me; aLab : Label from TDF)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns information about <aLab> to be displayed
|
||||
-- in information window.
|
||||
|
||||
Information(me; anIndex : Integer from Standard = 0)
|
||||
returns AsciiString from TCollection;
|
||||
---Purpose: Returns information about attribute <anIndex> to
|
||||
-- be displayed in information window.
|
||||
|
||||
|
||||
fields
|
||||
|
||||
myDF : Data from TDF;
|
||||
myAttMap : AttributeIndexedMap from TDF;
|
||||
|
||||
end Browser;
|
@@ -14,32 +14,31 @@
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
// ---------------
|
||||
|
||||
// Version: 0.0
|
||||
//Version Date Purpose
|
||||
// 0.0 Oct 3 1997 Creation
|
||||
|
||||
|
||||
#include <DDF_Browser.ixx>
|
||||
|
||||
#include <DDF_AttributeBrowser.hxx>
|
||||
|
||||
#include <TDF_Tool.hxx>
|
||||
#include <TDF_ChildIterator.hxx>
|
||||
#include <TDF_AttributeIterator.hxx>
|
||||
#include <TDF_Attribute.hxx>
|
||||
#include <TDF.hxx>
|
||||
|
||||
#include <TDataStd_Name.hxx>
|
||||
|
||||
#include <DDF_Browser.hxx>
|
||||
#include <Draw_Display.hxx>
|
||||
#include <Draw_Drawable3D.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
#include <TCollection_AsciiString.hxx>
|
||||
#include <TCollection_ExtendedString.hxx>
|
||||
#include <TDataStd_Name.hxx>
|
||||
#include <TDF.hxx>
|
||||
#include <TDF_Attribute.hxx>
|
||||
#include <TDF_AttributeIterator.hxx>
|
||||
#include <TDF_ChildIterator.hxx>
|
||||
#include <TDF_Data.hxx>
|
||||
#include <TDF_Label.hxx>
|
||||
#include <TDF_Tool.hxx>
|
||||
|
||||
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
// Communication convention with tcl:
|
||||
// tcl waits for a string of characters, being an information list.
|
||||
// In this list, each item is separated from another by a separator: '\'.
|
||||
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
|
||||
#define TDF_BrowserSeparator1 '\\'
|
||||
#define TDF_BrowserSeparator2 ' '
|
||||
#define TDF_BrowserSeparator3 '#'
|
||||
|
114
src/DDF/DDF_Browser.hxx
Normal file
114
src/DDF/DDF_Browser.hxx
Normal file
@@ -0,0 +1,114 @@
|
||||
// Created by: DAUTRY Philippe
|
||||
// Copyright (c) 1997-1999 Matra Datavision
|
||||
// Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it under
|
||||
// the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
// by the Free Software Foundation, with special exception defined in the file
|
||||
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
// distribution for complete text of the license and disclaimer of any warranty.
|
||||
//
|
||||
// Alternatively, this file may be used under the terms of Open CASCADE
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
#ifndef _DDF_Browser_HeaderFile
|
||||
#define _DDF_Browser_HeaderFile
|
||||
|
||||
#include <Standard.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
|
||||
#include <TDF_AttributeIndexedMap.hxx>
|
||||
#include <Draw_Drawable3D.hxx>
|
||||
#include <Standard_OStream.hxx>
|
||||
#include <Draw_Interpretor.hxx>
|
||||
#include <Standard_Integer.hxx>
|
||||
class TDF_Data;
|
||||
class Draw_Display;
|
||||
class Draw_Drawable3D;
|
||||
class TCollection_AsciiString;
|
||||
class TDF_Label;
|
||||
|
||||
|
||||
class DDF_Browser;
|
||||
DEFINE_STANDARD_HANDLE(DDF_Browser, Draw_Drawable3D)
|
||||
|
||||
//! Browses a data framework from TDF.
|
||||
class DDF_Browser : public Draw_Drawable3D
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
|
||||
Standard_EXPORT DDF_Browser(const Handle(TDF_Data)& aDF);
|
||||
|
||||
Standard_EXPORT void DrawOn (Draw_Display& dis) const;
|
||||
|
||||
Standard_EXPORT virtual Handle(Draw_Drawable3D) Copy() const Standard_OVERRIDE;
|
||||
|
||||
Standard_EXPORT virtual void Dump (Standard_OStream& S) const Standard_OVERRIDE;
|
||||
|
||||
Standard_EXPORT virtual void Whatis (Draw_Interpretor& I) const Standard_OVERRIDE;
|
||||
|
||||
Standard_EXPORT void Data (const Handle(TDF_Data)& aDF);
|
||||
|
||||
Standard_EXPORT Handle(TDF_Data) Data() const;
|
||||
|
||||
//! Returns a string composed with the sub-label
|
||||
//! entries of <myDF>.
|
||||
Standard_EXPORT TCollection_AsciiString OpenRoot() const;
|
||||
|
||||
//! Returns a string composed with the sub-label
|
||||
//! entries of <aLab>.
|
||||
Standard_EXPORT TCollection_AsciiString OpenLabel (const TDF_Label& aLab) const;
|
||||
|
||||
//! Returns a string composed with the attribute index
|
||||
//! (found in <myAttMap>) of <aLab>.
|
||||
Standard_EXPORT TCollection_AsciiString OpenAttributeList (const TDF_Label& aLab);
|
||||
|
||||
//! Returns a string composed with the list of
|
||||
//! referenced attribute index of the attribute
|
||||
//! <anIndex>. For exemple, it is usefull for
|
||||
//! TDataStd_Group. It uses a mecanism based on a
|
||||
//! DDF_AttributeBrowser.
|
||||
Standard_EXPORT TCollection_AsciiString OpenAttribute (const Standard_Integer anIndex = 0);
|
||||
|
||||
//! Returns information about <me> to be displayed in
|
||||
//! information window.
|
||||
Standard_EXPORT TCollection_AsciiString Information() const;
|
||||
|
||||
//! Returns information about <aLab> to be displayed
|
||||
//! in information window.
|
||||
Standard_EXPORT TCollection_AsciiString Information (const TDF_Label& aLab) const;
|
||||
|
||||
//! Returns information about attribute <anIndex> to
|
||||
//! be displayed in information window.
|
||||
Standard_EXPORT TCollection_AsciiString Information (const Standard_Integer anIndex = 0) const;
|
||||
|
||||
|
||||
|
||||
|
||||
DEFINE_STANDARD_RTTI(DDF_Browser,Draw_Drawable3D)
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
|
||||
|
||||
private:
|
||||
|
||||
|
||||
Handle(TDF_Data) myDF;
|
||||
TDF_AttributeIndexedMap myAttMap;
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endif // _DDF_Browser_HeaderFile
|
@@ -1,69 +0,0 @@
|
||||
-- Created by: DAUTRY Philippe
|
||||
-- Copyright (c) 1997-1999 Matra Datavision
|
||||
-- Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
--
|
||||
-- This file is part of Open CASCADE Technology software library.
|
||||
--
|
||||
-- This library is free software; you can redistribute it and/or modify it under
|
||||
-- the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
-- by the Free Software Foundation, with special exception defined in the file
|
||||
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
-- distribution for complete text of the license and disclaimer of any warranty.
|
||||
--
|
||||
-- Alternatively, this file may be used under the terms of Open CASCADE
|
||||
-- commercial license or contractual agreement.
|
||||
|
||||
-- ------------
|
||||
|
||||
---Version: 0.0
|
||||
--Version Date Purpose
|
||||
-- 0.0 Feb 10 1997 Creation
|
||||
|
||||
|
||||
class Data from DDF inherits Drawable3D from Draw
|
||||
|
||||
---Purpose : Encapsulates a data framework from TDF in a drawable object
|
||||
|
||||
uses
|
||||
|
||||
Data from TDF,
|
||||
Interpretor from Draw,
|
||||
Display from Draw
|
||||
|
||||
is
|
||||
|
||||
|
||||
Create (aDF : Data from TDF)
|
||||
returns Data from DDF;
|
||||
|
||||
|
||||
DrawOn (me; dis : in out Display);
|
||||
|
||||
|
||||
Copy (me)
|
||||
returns Drawable3D from Draw
|
||||
is redefined;
|
||||
|
||||
|
||||
Dump (me; S : in out OStream)
|
||||
is redefined;
|
||||
|
||||
|
||||
DataFramework (me : mutable; aDF : Data from TDF);
|
||||
|
||||
|
||||
DataFramework (me)
|
||||
returns Data from TDF;
|
||||
|
||||
|
||||
Whatis (me; I : in out Interpretor from Draw)
|
||||
is redefined;
|
||||
|
||||
|
||||
fields
|
||||
|
||||
myDF : Data from TDF;
|
||||
|
||||
end Data;
|
||||
|
||||
|
@@ -14,34 +14,29 @@
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
// ------------
|
||||
|
||||
// Version: 0.0
|
||||
//Version Date Purpose
|
||||
// 0.0 Feb 10 1997 Creation
|
||||
|
||||
|
||||
|
||||
#include <DDF_Data.ixx>
|
||||
#include <DDF.hxx>
|
||||
|
||||
#include <DDF_Data.hxx>
|
||||
#include <Draw_Display.hxx>
|
||||
#include <Draw_Drawable3D.hxx>
|
||||
#include <Standard_GUID.hxx>
|
||||
|
||||
#include <Standard_Type.hxx>
|
||||
#include <TCollection_AsciiString.hxx>
|
||||
|
||||
#include <TDF_Attribute.hxx>
|
||||
#include <TDF_Label.hxx>
|
||||
#include <TDF_ChildIterator.hxx>
|
||||
#include <TDF_AttributeIterator.hxx>
|
||||
#include <TDF_ChildIterator.hxx>
|
||||
#include <TDF_Data.hxx>
|
||||
#include <TDF_IDFilter.hxx>
|
||||
#include <TDF_Label.hxx>
|
||||
#include <TDF_Tool.hxx>
|
||||
|
||||
|
||||
|
||||
//=======================================================================
|
||||
//function : DDF_Data
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
DDF_Data::DDF_Data(const Handle(TDF_Data)& aDF) : myDF (aDF) {}
|
||||
|
||||
|
||||
|
78
src/DDF/DDF_Data.hxx
Normal file
78
src/DDF/DDF_Data.hxx
Normal file
@@ -0,0 +1,78 @@
|
||||
// Created by: DAUTRY Philippe
|
||||
// Copyright (c) 1997-1999 Matra Datavision
|
||||
// Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it under
|
||||
// the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
// by the Free Software Foundation, with special exception defined in the file
|
||||
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
// distribution for complete text of the license and disclaimer of any warranty.
|
||||
//
|
||||
// Alternatively, this file may be used under the terms of Open CASCADE
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
#ifndef _DDF_Data_HeaderFile
|
||||
#define _DDF_Data_HeaderFile
|
||||
|
||||
#include <Standard.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
|
||||
#include <Draw_Drawable3D.hxx>
|
||||
#include <Standard_OStream.hxx>
|
||||
#include <Draw_Interpretor.hxx>
|
||||
class TDF_Data;
|
||||
class Draw_Display;
|
||||
class Draw_Drawable3D;
|
||||
|
||||
|
||||
class DDF_Data;
|
||||
DEFINE_STANDARD_HANDLE(DDF_Data, Draw_Drawable3D)
|
||||
|
||||
//! Encapsulates a data framework from TDF in a drawable object
|
||||
class DDF_Data : public Draw_Drawable3D
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
|
||||
Standard_EXPORT DDF_Data(const Handle(TDF_Data)& aDF);
|
||||
|
||||
Standard_EXPORT void DrawOn (Draw_Display& dis) const;
|
||||
|
||||
Standard_EXPORT virtual Handle(Draw_Drawable3D) Copy() const Standard_OVERRIDE;
|
||||
|
||||
Standard_EXPORT virtual void Dump (Standard_OStream& S) const Standard_OVERRIDE;
|
||||
|
||||
Standard_EXPORT void DataFramework (const Handle(TDF_Data)& aDF);
|
||||
|
||||
Standard_EXPORT Handle(TDF_Data) DataFramework() const;
|
||||
|
||||
Standard_EXPORT virtual void Whatis (Draw_Interpretor& I) const Standard_OVERRIDE;
|
||||
|
||||
|
||||
|
||||
|
||||
DEFINE_STANDARD_RTTI(DDF_Data,Draw_Drawable3D)
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
|
||||
|
||||
private:
|
||||
|
||||
|
||||
Handle(TDF_Data) myDF;
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endif // _DDF_Data_HeaderFile
|
@@ -1,86 +0,0 @@
|
||||
-- Created by: DAUTRY Philippe
|
||||
-- Copyright (c) 1997-1999 Matra Datavision
|
||||
-- Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
--
|
||||
-- This file is part of Open CASCADE Technology software library.
|
||||
--
|
||||
-- This library is free software; you can redistribute it and/or modify it under
|
||||
-- the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
-- by the Free Software Foundation, with special exception defined in the file
|
||||
-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
-- distribution for complete text of the license and disclaimer of any warranty.
|
||||
--
|
||||
-- Alternatively, this file may be used under the terms of Open CASCADE
|
||||
-- commercial license or contractual agreement.
|
||||
|
||||
-- -------------------
|
||||
|
||||
---Version: 0.0
|
||||
--Version Date Purpose
|
||||
-- 0.0 Nov 4 1997 Creation
|
||||
|
||||
class Transaction from DDF
|
||||
inherits TShared from MMgt
|
||||
|
||||
---Purpose: This class encapsulates TDF_Transaction.
|
||||
|
||||
uses
|
||||
|
||||
Data from TDF,
|
||||
Delta from TDF,
|
||||
Transaction from TDF
|
||||
|
||||
raises
|
||||
|
||||
DomainError, NullObject from Standard
|
||||
|
||||
is
|
||||
|
||||
Create
|
||||
returns Transaction from DDF;
|
||||
---Purpose: Creates an empty transaction context, unable to be
|
||||
-- opened.
|
||||
|
||||
Create(aDF : Data from TDF)
|
||||
returns Transaction from DDF;
|
||||
---Purpose: Creates a transaction context on <aDF>, ready to
|
||||
-- be opened.
|
||||
|
||||
Open(me : mutable)
|
||||
returns Integer from Standard;
|
||||
---Purpose: If not yet done, opens a new transaction on
|
||||
-- <myDF>. Returns the index of the just opened
|
||||
-- transaction.
|
||||
--
|
||||
-- It raises DomainError if the transaction is
|
||||
-- already open, and NullObject if there is no
|
||||
-- current Data framework.
|
||||
|
||||
Commit(me : mutable;
|
||||
withDelta : Boolean from Standard = Standard_False)
|
||||
returns Delta from TDF;
|
||||
---Purpose: Commits the transactions until AND including the
|
||||
-- current opened one.
|
||||
|
||||
Abort(me : mutable);
|
||||
---Purpose: Aborts the transactions until AND including the
|
||||
-- current opened one.
|
||||
--
|
||||
---C++: alias ~
|
||||
|
||||
Data(me) returns Data from TDF;
|
||||
---Purpose: Returns the Data from TDF.
|
||||
|
||||
Transaction(me) returns Integer from Standard;
|
||||
---Purpose: Returns the number of the transaction opened by <me>.
|
||||
|
||||
IsOpen(me)
|
||||
returns Boolean from Standard;
|
||||
---Purpose: Returns true if the transaction is open.
|
||||
|
||||
|
||||
fields
|
||||
|
||||
myTransaction : Transaction from TDF;
|
||||
|
||||
end Transaction;
|
@@ -14,21 +14,21 @@
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
// -------------------
|
||||
|
||||
// Version: 0.0
|
||||
//Version Date Purpose
|
||||
// 0.0 Nov 4 1997 Creation
|
||||
|
||||
|
||||
|
||||
#include <DDF_Transaction.ixx>
|
||||
|
||||
#include <DDF_Transaction.hxx>
|
||||
#include <Standard_DomainError.hxx>
|
||||
#include <Standard_NullObject.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
#include <TDF_Data.hxx>
|
||||
#include <TDF_Delta.hxx>
|
||||
|
||||
//=======================================================================
|
||||
//function : DDF_Transaction
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
|
||||
DDF_Transaction::DDF_Transaction()
|
||||
: myTransaction( TCollection_AsciiString() )
|
||||
{}
|
||||
|
103
src/DDF/DDF_Transaction.hxx
Normal file
103
src/DDF/DDF_Transaction.hxx
Normal file
@@ -0,0 +1,103 @@
|
||||
// Created by: DAUTRY Philippe
|
||||
// Copyright (c) 1997-1999 Matra Datavision
|
||||
// Copyright (c) 1999-2014 OPEN CASCADE SAS
|
||||
//
|
||||
// This file is part of Open CASCADE Technology software library.
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or modify it under
|
||||
// the terms of the GNU Lesser General Public License version 2.1 as published
|
||||
// by the Free Software Foundation, with special exception defined in the file
|
||||
// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
|
||||
// distribution for complete text of the license and disclaimer of any warranty.
|
||||
//
|
||||
// Alternatively, this file may be used under the terms of Open CASCADE
|
||||
// commercial license or contractual agreement.
|
||||
|
||||
#ifndef _DDF_Transaction_HeaderFile
|
||||
#define _DDF_Transaction_HeaderFile
|
||||
|
||||
#include <Standard.hxx>
|
||||
#include <Standard_Type.hxx>
|
||||
|
||||
#include <TDF_Transaction.hxx>
|
||||
#include <MMgt_TShared.hxx>
|
||||
#include <Standard_Integer.hxx>
|
||||
#include <Standard_Boolean.hxx>
|
||||
class Standard_DomainError;
|
||||
class Standard_NullObject;
|
||||
class TDF_Data;
|
||||
class TDF_Delta;
|
||||
|
||||
|
||||
class DDF_Transaction;
|
||||
DEFINE_STANDARD_HANDLE(DDF_Transaction, MMgt_TShared)
|
||||
|
||||
//! This class encapsulates TDF_Transaction.
|
||||
class DDF_Transaction : public MMgt_TShared
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
|
||||
//! Creates an empty transaction context, unable to be
|
||||
//! opened.
|
||||
Standard_EXPORT DDF_Transaction();
|
||||
|
||||
//! Creates a transaction context on <aDF>, ready to
|
||||
//! be opened.
|
||||
Standard_EXPORT DDF_Transaction(const Handle(TDF_Data)& aDF);
|
||||
|
||||
//! If not yet done, opens a new transaction on
|
||||
//! <myDF>. Returns the index of the just opened
|
||||
//! transaction.
|
||||
//!
|
||||
//! It raises DomainError if the transaction is
|
||||
//! already open, and NullObject if there is no
|
||||
//! current Data framework.
|
||||
Standard_EXPORT Standard_Integer Open();
|
||||
|
||||
//! Commits the transactions until AND including the
|
||||
//! current opened one.
|
||||
Standard_EXPORT Handle(TDF_Delta) Commit (const Standard_Boolean withDelta = Standard_False);
|
||||
|
||||
//! Aborts the transactions until AND including the
|
||||
//! current opened one.
|
||||
Standard_EXPORT void Abort();
|
||||
~DDF_Transaction()
|
||||
{
|
||||
Abort();
|
||||
}
|
||||
|
||||
//! Returns the Data from TDF.
|
||||
Standard_EXPORT Handle(TDF_Data) Data() const;
|
||||
|
||||
//! Returns the number of the transaction opened by <me>.
|
||||
Standard_EXPORT Standard_Integer Transaction() const;
|
||||
|
||||
//! Returns true if the transaction is open.
|
||||
Standard_EXPORT Standard_Boolean IsOpen() const;
|
||||
|
||||
|
||||
|
||||
DEFINE_STANDARD_RTTI(DDF_Transaction,MMgt_TShared)
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
|
||||
|
||||
private:
|
||||
|
||||
|
||||
TDF_Transaction myTransaction;
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endif // _DDF_Transaction_HeaderFile
|
@@ -1,11 +1,19 @@
|
||||
DDF_AttributeBrowser.hxx
|
||||
DDF.cxx
|
||||
DDF.hxx
|
||||
DDF_AttributeBrowser.cxx
|
||||
DDF_AttributeBrowser.hxx
|
||||
DDF_BasicCommands.cxx
|
||||
DDF_DataCommands.cxx
|
||||
DDF_TransactionCommands.cxx
|
||||
DDF_Browser.cxx
|
||||
DDF_Browser.hxx
|
||||
DDF_BrowserCommands.cxx
|
||||
DDF_Data.cxx
|
||||
DDF_Data.hxx
|
||||
DDF_DataCommands.cxx
|
||||
DDF_IOStream.cxx
|
||||
DDF_IOStream.hxx
|
||||
FILES
|
||||
DDF_TransactionStack.hxx
|
||||
DDF_ListIteratorOfTransactionStack.hxx
|
||||
DDF_Transaction.cxx
|
||||
DDF_Transaction.hxx
|
||||
DDF_TransactionCommands.cxx
|
||||
DDF_TransactionStack.hxx
|
||||
FILES
|
||||
|
Reference in New Issue
Block a user