xref: /haiku/src/apps/haikudepot/packagemodel/PackageLocalizedText.h (revision 344ded80d400028c8f561b4b876257b94c12db4a)
1 /*
2  * Copyright 2024, Andrew Lindesay <apl@lindesay.co.nz>.
3  * All rights reserved. Distributed under the terms of the MIT License.
4  */
5 #ifndef PACKAGE_LOCALIZED_TEXT_H
6 #define PACKAGE_LOCALIZED_TEXT_H
7 
8 
9 #include <Referenceable.h>
10 #include <String.h>
11 
12 
13 class PackageLocalizedText : public BReferenceable
14 {
15 public:
16 								PackageLocalizedText();
17 								PackageLocalizedText(const PackageLocalizedText& other);
18 
19 			const BString&		Title() const;
20 			void				SetTitle(const BString& value);
21 
22 			const BString&		Summary() const;
23 			void				SetSummary(const BString& value);
24 
25 			const BString&		Description() const;
26 			void				SetDescription(const BString& value);
27 
28 			const bool			HasChangelog() const;
29 			void				SetHasChangelog(bool value);
30 
31 			void				SetChangelog(const BString& value);
32 			const BString&		Changelog() const;
33 
34 			bool				operator==(const PackageLocalizedText& other) const;
35 			bool				operator!=(const PackageLocalizedText& other) const;
36 
37 private:
38 			BString				fTitle;
39 			BString				fSummary;
40 			BString				fDescription;
41 			bool				fHasChangelog;
42 			BString				fChangelog;
43 				// ^ Note the changelog is not localized yet but will be at some point.
44 };
45 
46 
47 typedef BReference<PackageLocalizedText> PackageLocalizedTextRef;
48 
49 
50 #endif // PACKAGE_LOCALIZED_TEXT_H
51