X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGEOM%2FGEOM_Function.hxx;h=5c4b530c6781e7522b271ba66230b5442f5d626d;hb=ec168c32f86cab8199030ec4e8e2b1cbd5e42670;hp=c6d273bfc88277c94074fa57cbdac92f9dcf4d82;hpb=b51357b79dff28f1970125b19b018d392dfb0e75;p=modules%2Fgeom.git diff --git a/src/GEOM/GEOM_Function.hxx b/src/GEOM/GEOM_Function.hxx index c6d273bfc..5c4b530c6 100644 --- a/src/GEOM/GEOM_Function.hxx +++ b/src/GEOM/GEOM_Function.hxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -6,7 +6,7 @@ // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; either -// version 2.1 of the License. +// version 2.1 of the License, or (at your option) any later version. // // This library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -26,15 +26,18 @@ #include #include #include +#include +#include +#include +#include #include #include #include #include #include -class Handle_TColStd_HArray1OfReal; -class Handle_TColStd_HArray1OfInteger; -class Handle_TColStd_HSequenceOfTransient; +#include + class GEOM_Function; DEFINE_STANDARD_HANDLE (GEOM_Function, Standard_Transient); @@ -55,7 +58,7 @@ public: Standard_EXPORT GEOM_Function(const TDF_Label& theEntry, const Standard_GUID& theGUID, int theType); - Standard_EXPORT ~GEOM_Function() {} + Standard_EXPORT ~GEOM_Function(); Standard_EXPORT TDF_Label GetOwnerEntry(); @@ -108,6 +111,18 @@ public: //Returns an integer array argument at position thePosition Standard_EXPORT Handle(TColStd_HArray1OfInteger) GetIntegerArray(int thePosition); + //Sets a byte array argument at position thePosition + Standard_EXPORT void SetByteArray(int thePosition, const Handle(TColStd_HArray1OfByte)& theArray); + + //Returns a byte array argument at position thePosition + Standard_EXPORT Handle(TColStd_HArray1OfByte) GetByteArray(int thePosition); + + //Sets a boolean array argument at position thePosition + Standard_EXPORT void SetBooleanArray(int thePosition, const Handle(TColStd_HArray1OfByte)& theArray); + + //Returns a boolean array argument at position thePosition + Standard_EXPORT Handle(TColStd_HArray1OfByte) GetBooleanArray(int thePosition); + //Sets a reference to other function argument at position thePosition Standard_EXPORT void SetReference(int thePosition, Handle(GEOM_Function) theReference); @@ -139,6 +154,17 @@ public: //Returns a list of references to other function arguments at position thePosition Standard_EXPORT Handle(TColStd_HSequenceOfTransient) GetReferenceList (int thePosition); + // Save a pointer to a data holder intended to pass data Driver -> Operation. + // This method should be called by Operation to set the data holder. + // An instance of GEOM_Function that sets the data holder will remove the + // corresponding OCAF attribute at it's destruction + Standard_EXPORT void SetCallBackData( void* data ); + + // Returns a pointer to a data holder intended to pass data Driver -> Operation. + // This method should be called by Driver to get the data holder to fill it in. + // Returns NULL if the Operation have not set the data holder. + Standard_EXPORT void* GetCallBackData(); + //Sets a TopoDS_Shape argument at position thePosition //void SetShape(int thePosition, const TopoDS_Shape& theShape); @@ -171,12 +197,13 @@ public: //Returns top label of this function's naming tree Standard_EXPORT TDF_Label GetNamingEntry (const Standard_Boolean create = Standard_True); - DEFINE_STANDARD_RTTI (GEOM_Function); + OCCT_DEFINE_STANDARD_RTTIEXT(GEOM_Function,Standard_Transient) private: TDF_Label _label; bool _isDone; + bool _isCallBackData; }; #endif