7fd59977 |
1 | // File: NCollection_DefineHArray1.hxx |
2 | // Created: Mon Apr 29 11:36:31 2002 |
3 | // Author: Alexander KARTOMIN (akm) |
4 | // <a-kartomin@opencascade.com> |
5 | // Automatically created from NCollection_HArray1.hxx by GAWK |
6 | // Copyright: Open Cascade 2002 |
7 | |
8 | #ifndef NCollection_DefineHArray1_HeaderFile |
9 | #define NCollection_DefineHArray1_HeaderFile |
10 | |
11 | #include <Standard_DefineHandle.hxx> |
12 | #include <NCollection_DefineArray1.hxx> |
13 | #include <MMgt_TShared.hxx> |
14 | |
15 | // Declaration of Array1 class managed by Handle |
16 | |
17 | #define DEFINE_HARRAY1(HClassName, _Array1Type_) \ |
18 | \ |
19 | class HClassName : public _Array1Type_, \ |
20 | public MMgt_TShared { \ |
21 | public: \ |
22 | inline HClassName (const Standard_Integer theLower, \ |
23 | const Standard_Integer theUpper); \ |
24 | inline HClassName (const _Array1Type_&); \ |
25 | inline const _Array1Type_& Array1 () const; \ |
26 | inline _Array1Type_& ChangeArray1 (); \ |
27 | DEFINE_STANDARD_RTTI (HClassName) \ |
28 | }; \ |
29 | \ |
30 | DEFINE_STANDARD_HANDLE (HClassName, MMgt_TShared) \ |
31 | \ |
32 | inline HClassName::HClassName (const Standard_Integer theLower, \ |
33 | const Standard_Integer theUpper) : \ |
34 | _Array1Type_ (theLower,theUpper), \ |
35 | MMgt_TShared() {} \ |
36 | \ |
37 | inline HClassName::HClassName (const _Array1Type_& theOther) : \ |
38 | _Array1Type_(theOther), \ |
39 | MMgt_TShared() {} \ |
40 | \ |
41 | inline const _Array1Type_& HClassName::Array1 () const \ |
42 | { return * (const _Array1Type_ *) this; } \ |
43 | \ |
44 | inline _Array1Type_& HClassName::ChangeArray1 () \ |
45 | { return * (_Array1Type_ *) this; } \ |
46 | |
47 | #define IMPLEMENT_HARRAY1(HClassName) \ |
48 | IMPLEMENT_STANDARD_HANDLE (HClassName, MMgt_TShared) \ |
49 | IMPLEMENT_STANDARD_RTTIEXT (HClassName, MMgt_TShared) |
50 | |
51 | #endif |