Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:05:21

0001 // Created by: DAUTRY Philippe
0002 // Copyright (c) 1997-1999 Matra Datavision
0003 // Copyright (c) 1999-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 #ifndef _TDocStd_XLinkIterator_HeaderFile
0017 #define _TDocStd_XLinkIterator_HeaderFile
0018 
0019 #include <Standard.hxx>
0020 #include <Standard_DefineAlloc.hxx>
0021 #include <Standard_Handle.hxx>
0022 
0023 #include <TDocStd_XLinkPtr.hxx>
0024 #include <Standard_Boolean.hxx>
0025 class TDocStd_Document;
0026 
0027 
0028 //! Iterates on Reference attributes.
0029 //! This is an iterator giving all the external references
0030 //! of a Document.
0031 class TDocStd_XLinkIterator 
0032 {
0033 public:
0034 
0035   DEFINE_STANDARD_ALLOC
0036 
0037   
0038   //! Returns an empty iterator;
0039   Standard_EXPORT TDocStd_XLinkIterator();
0040   
0041   //! Creates an iterator on Reference of <D>.
0042   Standard_EXPORT TDocStd_XLinkIterator(const Handle(TDocStd_Document)& D);
0043   
0044   //! Restarts an iteration with <D>.
0045   Standard_EXPORT void Initialize (const Handle(TDocStd_Document)& D);
0046   
0047   //! Returns True if there is a current Item in the
0048   //! iteration.
0049     Standard_Boolean More() const;
0050   
0051   //! Move to the next item; raises if there is no more item.
0052   Standard_EXPORT void Next();
0053   
0054   //! Returns the current item; a null handle if there is none.
0055     TDocStd_XLinkPtr Value() const;
0056 
0057 
0058 
0059 
0060 protected:
0061 
0062 
0063 
0064 
0065 
0066 private:
0067 
0068   
0069   Standard_EXPORT void Init (const Handle(TDocStd_Document)& D);
0070 
0071 
0072   TDocStd_XLinkPtr myValue;
0073 
0074 
0075 };
0076 
0077 
0078 #include <TDocStd_XLinkIterator.lxx>
0079 
0080 
0081 
0082 
0083 
0084 #endif // _TDocStd_XLinkIterator_HeaderFile