summaryrefslogtreecommitdiff
path: root/inc/IFSelect_Signature.hxx
blob: 21772620462a4144924424edbf1947692bb23831 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
// This file is generated by WOK (CPPExt).
// Please do not edit this file; modify original file instead.
// The copyright and license terms as defined for the original file apply to 
// this header file considered to be the "object code" form of the original source.

#ifndef _IFSelect_Signature_HeaderFile
#define _IFSelect_Signature_HeaderFile

#ifndef _Standard_HeaderFile
#include <Standard.hxx>
#endif
#ifndef _Standard_DefineHandle_HeaderFile
#include <Standard_DefineHandle.hxx>
#endif
#ifndef _Handle_IFSelect_Signature_HeaderFile
#include <Handle_IFSelect_Signature.hxx>
#endif

#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
#ifndef _Handle_TColStd_HSequenceOfAsciiString_HeaderFile
#include <Handle_TColStd_HSequenceOfAsciiString.hxx>
#endif
#ifndef _TCollection_AsciiString_HeaderFile
#include <TCollection_AsciiString.hxx>
#endif
#ifndef _Interface_SignType_HeaderFile
#include <Interface_SignType.hxx>
#endif
#ifndef _Standard_CString_HeaderFile
#include <Standard_CString.hxx>
#endif
#ifndef _Standard_Boolean_HeaderFile
#include <Standard_Boolean.hxx>
#endif
#ifndef _Handle_Standard_Transient_HeaderFile
#include <Handle_Standard_Transient.hxx>
#endif
#ifndef _Handle_Interface_InterfaceModel_HeaderFile
#include <Handle_Interface_InterfaceModel.hxx>
#endif
class TColStd_HSequenceOfAsciiString;
class TCollection_AsciiString;
class Standard_Transient;
class Interface_InterfaceModel;


//! Signature provides the basic service used by the classes <br>
//!             SelectSignature and Counter (i.e. Name, Value), which is : <br>
//!           - for an entity in a model, give a characteristic string, its <br>
//!             signature <br>
//!           This string has not to be unique in the model, but gives a <br>
//!           value for such or such important feature. <br>
//!           Exemples : Dynamic Type; Category; etc <br>
class IFSelect_Signature : public Interface_SignType {

public:

  //! Sets the information data to tell "integer cases" with <br>
//!           possible min and max values <br>
//!           To be called when creating <br>
  Standard_EXPORT     void SetIntCase(const Standard_Boolean hasmin,const Standard_Integer valmin,const Standard_Boolean hasmax,const Standard_Integer valmax) ;
  //! Tells if this Signature gives integer values <br>
//!           and returns values from SetIntCase if True <br>
  Standard_EXPORT     Standard_Boolean IsIntCase(Standard_Boolean& hasmin,Standard_Integer& valmin,Standard_Boolean& hasmax,Standard_Integer& valmax) const;
  //! Adds a possible case <br>
//!           To be called when creating, IF the list of possible cases for <br>
//!           Value is known when starting <br>
//!           For instance, for CDL types, rather do not fill this, <br>
//!           but for a specific enumeration (such as a status), can be used <br>
  Standard_EXPORT     void AddCase(const Standard_CString acase) ;
  //! Returns the predefined list of possible cases, filled by AddCase <br>
//!           Null Handle if no predefined list (hence, to be counted) <br>
//!           Useful to filter on  really possible vase, for instance, or <br>
//!           for a help <br>
  Standard_EXPORT     Handle_TColStd_HSequenceOfAsciiString CaseList() const;
  //! Returns an identification of the Signature (a word), given at <br>
//!           initialization time <br>//! Returns the Signature for a Transient object. It is specific <br>
//!           of each sub-class of Signature. For a Null Handle, it should <br>
//!           provide "" <br>
//!           It can work with the model which contains the entity <br>
  Standard_EXPORT     Standard_CString Name() const;
  //! The label of a Signature uses its name as follow : <br>
//!           "Signature : <name>" <br>
  Standard_EXPORT     TCollection_AsciiString Label() const;
  //! Tells if the value for <ent> in <model> matches a text, with <br>
//!           a criterium <exact>. <br>
//!           The default definition calls MatchValue <br>
//!           Can be redefined <br>
  Standard_EXPORT   virtual  Standard_Boolean Matches(const Handle(Standard_Transient)& ent,const Handle(Interface_InterfaceModel)& model,const TCollection_AsciiString& text,const Standard_Boolean exact) const;
  //! Default procedure to tell if a value <val> matches a text <br>
//!           with a criterium <exact>. <exact> = True requires equality, <br>
//!           else only contained (no reg-exp) <br>
  Standard_EXPORT   static  Standard_Boolean MatchValue(const Standard_CString val,const TCollection_AsciiString& text,const Standard_Boolean exact) ;
  //! This procedure converts an Integer to a CString <br>
//!           It is a convenient way when the value of a signature has the <br>
//!           form of a simple integer value <br>
//!           The value is to be used immediately (one buffer only, no copy) <br>
  Standard_EXPORT   static  Standard_CString IntValue(const Standard_Integer val) ;




  DEFINE_STANDARD_RTTI(IFSelect_Signature)

protected:

  //! Initializes a Signature with its name <br>
  Standard_EXPORT   IFSelect_Signature(const Standard_CString name);

TCollection_AsciiString thename;


private: 


Standard_Integer thecasi[3];
Handle_TColStd_HSequenceOfAsciiString thecasl;


};





// other Inline functions and methods (like "C++: function call" methods)


#endif