3
0

ScriptCanvasStringPropertyDataInterface.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #pragma once
  9. #include <GraphCanvas/Components/NodePropertyDisplay/StringDataInterface.h>
  10. #include "ScriptCanvasPropertyDataInterface.h"
  11. namespace ScriptCanvasEditor
  12. {
  13. class ScriptCanvasStringPropertyDataInterface
  14. : public ScriptCanvasPropertyDataInterface<GraphCanvas::StringDataInterface, ScriptCanvas::Data::StringType>
  15. {
  16. public:
  17. AZ_CLASS_ALLOCATOR(ScriptCanvasStringPropertyDataInterface, AZ::SystemAllocator);
  18. ScriptCanvasStringPropertyDataInterface(const AZ::EntityId& nodeId, ScriptCanvas::TypedNodePropertyInterface<ScriptCanvas::Data::StringType>* propertyNodeInterface)
  19. : ScriptCanvasPropertyDataInterface(nodeId, propertyNodeInterface)
  20. {
  21. }
  22. ~ScriptCanvasStringPropertyDataInterface() = default;
  23. // StringDataInterface
  24. AZStd::string GetString() const override
  25. {
  26. return GetValue();
  27. }
  28. void SetString(const AZStd::string& value) override
  29. {
  30. SetValue(value);
  31. }
  32. ////
  33. };
  34. }