|
||||
File indexing completed on 2025-01-18 10:03:53
0001 // Created on: 1994-12-21 0002 // Created by: Christian CAILLET 0003 // Copyright (c) 1994-1999 Matra Datavision 0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS 0005 // 0006 // This file is part of Open CASCADE Technology software library. 0007 // 0008 // This library is free software; you can redistribute it and/or modify it under 0009 // the terms of the GNU Lesser General Public License version 2.1 as published 0010 // by the Free Software Foundation, with special exception defined in the file 0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT 0012 // distribution for complete text of the license and disclaimer of any warranty. 0013 // 0014 // Alternatively, this file may be used under the terms of Open CASCADE 0015 // commercial license or contractual agreement. 0016 0017 #ifndef _IFSelect_DispPerFiles_HeaderFile 0018 #define _IFSelect_DispPerFiles_HeaderFile 0019 0020 #include <Standard.hxx> 0021 #include <Standard_Type.hxx> 0022 0023 #include <IFSelect_Dispatch.hxx> 0024 #include <Standard_Integer.hxx> 0025 class IFSelect_IntParam; 0026 class TCollection_AsciiString; 0027 class Interface_Graph; 0028 class IFGraph_SubPartsIterator; 0029 0030 0031 class IFSelect_DispPerFiles; 0032 DEFINE_STANDARD_HANDLE(IFSelect_DispPerFiles, IFSelect_Dispatch) 0033 0034 //! A DispPerFiles produces a determined count of Packets from the 0035 //! input Entities. It divides, as equally as possible, the input 0036 //! list into a count of files. This count is the parameter of the 0037 //! DispPerFiles. If the input list has less than this count, of 0038 //! course there will be one packet per input entity. 0039 //! This count is a Parameter of the DispPerFiles, given as an 0040 //! IntParam, thus allowing external control of its Value 0041 class IFSelect_DispPerFiles : public IFSelect_Dispatch 0042 { 0043 0044 public: 0045 0046 0047 //! Creates a DispPerFiles with no Count (default value 1 file) 0048 Standard_EXPORT IFSelect_DispPerFiles(); 0049 0050 //! Returns the Count Parameter used for splitting 0051 Standard_EXPORT Handle(IFSelect_IntParam) Count() const; 0052 0053 //! Sets a new Parameter for Count 0054 Standard_EXPORT void SetCount (const Handle(IFSelect_IntParam)& count); 0055 0056 //! Returns the effective value of the count parameter 0057 //! (if Count Parameter not Set or value not positive, returns 1) 0058 Standard_EXPORT Standard_Integer CountValue() const; 0059 0060 //! Returns as Label, "Maximum <count> Files" 0061 Standard_EXPORT TCollection_AsciiString Label() const Standard_OVERRIDE; 0062 0063 //! Returns True, maximum count is given as CountValue 0064 Standard_EXPORT virtual Standard_Boolean LimitedMax (const Standard_Integer nbent, Standard_Integer& max) const Standard_OVERRIDE; 0065 0066 //! Computes the list of produced Packets. It defines Packets in 0067 //! order to have <Count> Packets, except if the input count of 0068 //! Entities is lower. Entities are given by RootResult from the 0069 //! Final Selection. 0070 Standard_EXPORT void Packets (const Interface_Graph& G, IFGraph_SubPartsIterator& packs) const Standard_OVERRIDE; 0071 0072 0073 0074 0075 DEFINE_STANDARD_RTTIEXT(IFSelect_DispPerFiles,IFSelect_Dispatch) 0076 0077 protected: 0078 0079 0080 0081 0082 private: 0083 0084 0085 Handle(IFSelect_IntParam) thecount; 0086 0087 0088 }; 0089 0090 0091 0092 0093 0094 0095 0096 #endif // _IFSelect_DispPerFiles_HeaderFile
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |