-#ifndef __DALI_PROPERTY_VALUE_H__
-#define __DALI_PROPERTY_VALUE_H__
+#ifndef DALI_PROPERTY_VALUE_H
+#define DALI_PROPERTY_VALUE_H
/*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2019 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
// EXTERNAL INCLUDES
#include <iosfwd>
+#include <utility>
+#include <initializer_list>
// INTERNAL INCLUDES
#include <dali/public-api/object/property.h>
class Matrix;
struct Extents;
+typedef std::pair< Property::Key, Property::Value > KeyValuePair;
+
/**
* @brief A value-type representing a property value.
* @SINCE_1_0.0
Value( Property::Array& arrayValue );
/**
+ * @brief Creates an array property value.
+ *
+ * @SINCE_1_4.16
+ * @param[in] arrayValue An r-value array
+ */
+ Value( Property::Array&& arrayValue );
+
+ /**
* @brief Creates a map property value.
*
* @SINCE_1_0.0
- * @param[in] mapValue An array
+ * @param[in] mapValue A map
*/
Value( Property::Map& mapValue );
/**
+ * @brief Creates a map property value.
+ *
+ * @SINCE_1_4.16
+ * @param[in] mapValue An r-value map
+ */
+ Value( Property::Map&& mapValue );
+
+ /**
+ * @brief Create a map property value from an initializer_list.
+ *
+ * @SINCE_1_4.16
+ * @param [in] values An initializer_list of pairs of index and value.
+ */
+ Value( const std::initializer_list< KeyValuePair >& values );
+
+ /**
* @brief Creates an extents property value.
*
* @SINCE_1_2.62
Value( const Value& value );
/**
+ * @brief Move constructor.
+ *
+ * A move constructor enables the resources owned by an rvalue object to be moved into an lvalue without copying.
+ * @SINCE_1_4.16
+ * @param[in] value The property value to move from
+ */
+ Value( Value&& value );
+
+ /**
* @brief Assigns a property value.
*
* @SINCE_1_0.0
Value& operator=( const Value& value );
/**
+ * @brief Move assignment operator.
+ *
+ * @SINCE_1_4.16
+ * @param[in] value The property value to move from
+ * @return a reference to this
+ */
+ Value& operator=( Value&& value );
+
+ /**
* @brief Non-virtual destructor.
*
* This class is not a base class.
*/
} // namespace Dali
-#endif // __DALI_PROPERTY_VALUE_H__
+#endif // DALI_PROPERTY_VALUE_H