1 // Created on: 1999-06-11
2 // Created by: Vladislav ROMASHKO
3 // Copyright (c) 1999-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
18 #include <Standard_Type.hxx>
19 #include <TDF_Label.hxx>
20 #include <TDF_ListIteratorOfLabelList.hxx>
21 #include <TFunction_Driver.hxx>
22 #include <TFunction_Logbook.hxx>
24 IMPLEMENT_STANDARD_RTTIEXT(TFunction_Driver,Standard_Transient)
26 //=======================================================================
27 //function : TFunction_Driver
28 //purpose : Constructor
29 //=======================================================================
30 TFunction_Driver::TFunction_Driver()
36 //=======================================================================
38 //purpose : Initialization
39 //=======================================================================
41 void TFunction_Driver::Init(const TDF_Label& L)
47 //=======================================================================
49 //purpose : Validates labels of a function
50 //=======================================================================
52 void TFunction_Driver::Validate(Handle(TFunction_Logbook)& log) const
57 TDF_ListIteratorOfLabelList itr(res);
58 for (; itr.More(); itr.Next())
60 log->SetValid(itr.Value(), Standard_True);
65 //=======================================================================
66 //function : MustExecute
67 //purpose : Analyzes the labels in the logbook
68 //=======================================================================
70 Standard_Boolean TFunction_Driver::MustExecute(const Handle(TFunction_Logbook)& log) const
72 // Check modification of arguments.
76 TDF_ListIteratorOfLabelList itr(args);
77 for (; itr.More(); itr.Next())
79 if (log->IsModified(itr.Value()))
82 return Standard_False;
86 //=======================================================================
87 //function : Arguments
88 //purpose : The method fills-in the list by labels,
89 // where the arguments of the function are located.
90 //=======================================================================
92 void TFunction_Driver::Arguments(TDF_LabelList& ) const
98 //=======================================================================
100 //purpose : The method fills-in the list by labels,
101 // where the results of the function are located.
102 //=======================================================================
104 void TFunction_Driver::Results(TDF_LabelList& ) const