| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
- //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
- #pragma once
- #include "BsPrerequisites.h"
- #include "BsResource.h"
- namespace BansheeEngine
- {
- /** @addtogroup Resources-Engine
- * @{
- */
- /** A resource containing plain text data. */
- class BS_EXPORT PlainText : public Resource
- {
- public:
- /** Returns the text contained in the resource. */
- const WString& getString() const { return mString; }
- /** Modifies the text contained in the resource. */
- void setString(const WString& data) { mString = data; }
- /** Creates a new text file resource with the specified string. */
- static HPlainText create(const WString& data);
- /** @name Internal
- * @{
- */
- /**
- * Creates an include file resource with the specified include string.
- *
- * @note Internal method. Use create() for normal use.
- */
- static SPtr<PlainText> _createPtr(const WString& data);
- /** @} */
- private:
- PlainText(const WString& data);
- WString mString;
- /************************************************************************/
- /* SERIALIZATION */
- /************************************************************************/
- public:
- friend class PlainTextRTTI;
- static RTTITypeBase* getRTTIStatic();
- virtual RTTITypeBase* getRTTI() const override;
- };
- /** @} */
- }
|