Merge branch 'fixes' into main/rendor-staging
[ryzomcore.git] / ryzom / tools / leveldesign / georges_convert / form.h
blobceae35c0544f7a390069320e0d9b26b597877444
1 // Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
2 // Copyright (C) 2010 Winch Gate Property Limited
3 //
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU Affero General Public License as
6 // published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU Affero General Public License for more details.
14 // You should have received a copy of the GNU Affero General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
17 #ifndef NLGEORGES_FORM_H
18 #define NLGEORGES_FORM_H
20 #include "nel/misc/stream.h"
21 #include "form_head.h"
22 #include "form_body_elt_struct.h"
24 namespace NLOLDGEORGES
27 class CFormBodyElt;
29 // CForm class represents a sheet.
30 // It has a Head and a Body.
31 // It has operators that allows to add or subtract from history.
32 class CForm
34 public:
35 CFormHead head;
36 CFormBodyEltStruct body;
37 bool bmodified;
39 CForm();
40 CForm( const CForm& _f );
41 virtual ~CForm();
43 void serial( NLMISC::IStream& s );
45 CStringEx GetDate() const;
46 CStringEx GetVersion() const;
47 CStringEx GetUser() const;
48 CStringEx GetComment() const;
49 void SetDate( const CStringEx _sxdate );
50 void SetVersion( const CStringEx _sxversion );
51 void SetUser( const CStringEx _sxuser );
52 void SetComment( const CStringEx _sxcomment );
55 CStringEx GetParent( unsigned int _index ) const;
56 CStringEx GetActivity( unsigned int _index ) const;
57 CFormBodyElt* GetElt( const CStringEx _sxname ) const;
58 CFormBodyEltStruct* GetBody() const;
59 bool GetModified() const;
60 void SetModified( const bool _b );
62 CForm& operator =( const CForm& _f );
63 CForm& operator +=( const CForm& _f );
64 CForm& operator -=( const CForm& _f );
65 bool operator ==( const CForm& _f ) const;
68 } // NLGEORGES
70 #endif // NLGEORGES_FORM_H