Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-08 09:17:50

0001 // Created on: 2004-11-23
0002 // Created by: Pavel TELKOV
0003 // Copyright (c) 2004-2014 OPEN CASCADE SAS
0004 //
0005 // This file is part of Open CASCADE Technology software library.
0006 //
0007 // This library is free software; you can redistribute it and/or modify it under
0008 // the terms of the GNU Lesser General Public License version 2.1 as published
0009 // by the Free Software Foundation, with special exception defined in the file
0010 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0011 // distribution for complete text of the license and disclaimer of any warranty.
0012 //
0013 // Alternatively, this file may be used under the terms of Open CASCADE
0014 // commercial license or contractual agreement.
0015 
0016 // The original implementation Copyright: (C) RINA S.p.A
0017 
0018 #ifndef TObj_OcafObjectIterator_HeaderFile
0019 #define TObj_OcafObjectIterator_HeaderFile
0020 
0021 #include <TObj_LabelIterator.hxx>
0022 
0023 /**
0024  * This class provides an iterator by objects in a partition.
0025  * (implements TObj_ObjectIterator interface)
0026  */
0027 
0028 class TObj_OcafObjectIterator : public TObj_LabelIterator
0029 {
0030 public:
0031   //! Creates the iterator on TObj objects on the sub-labels of theLabel.
0032   //! @param theLabel start label for searching
0033   //! @param theType type of the found objects, or all types if Null
0034   //! @param theRecursive search children recursively, not only on sub-labels of theLabel
0035   //! @param theAllSubChildren do not stop at the first level of children, but search for
0036   //! sub-children too
0037   Standard_EXPORT TObj_OcafObjectIterator(
0038     const TDF_Label&             theLabel,
0039     const Handle(Standard_Type)& theType           = NULL,
0040     const Standard_Boolean       theRecursive      = Standard_False,
0041     const Standard_Boolean       theAllSubChildren = Standard_False);
0042 
0043 protected:
0044   //! Shift iterator to the next object
0045   virtual Standard_EXPORT void MakeStep() Standard_OVERRIDE;
0046 
0047 protected:
0048   Handle(Standard_Type) myType; //!< type of objects to iterate on
0049   // clang-format off
0050   Standard_Boolean myAllSubChildren; //!< to iterate all sub-children, do not stop on the first level
0051   // clang-format on
0052 
0053 public:
0054   //! CASCADE RTTI
0055   DEFINE_STANDARD_RTTIEXT(TObj_OcafObjectIterator, TObj_LabelIterator)
0056 };
0057 
0058 //! Define handle class for TObj_OcafObjectIterator
0059 DEFINE_STANDARD_HANDLE(TObj_OcafObjectIterator, TObj_LabelIterator)
0060 
0061 #endif
0062 
0063 #ifdef _MSC_VER
0064 #pragma once
0065 #endif