summaryrefslogtreecommitdiff
path: root/src/components/smart_objects/include/smart_objects/array_schema_item.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/smart_objects/include/smart_objects/array_schema_item.h')
-rw-r--r--src/components/smart_objects/include/smart_objects/array_schema_item.h40
1 files changed, 16 insertions, 24 deletions
diff --git a/src/components/smart_objects/include/smart_objects/array_schema_item.h b/src/components/smart_objects/include/smart_objects/array_schema_item.h
index 937979f2fa..a81fdd637e 100644
--- a/src/components/smart_objects/include/smart_objects/array_schema_item.h
+++ b/src/components/smart_objects/include/smart_objects/array_schema_item.h
@@ -34,13 +34,14 @@
#include <stddef.h>
-#include "utils/shared_ptr.h"
#include "smart_objects/schema_item.h"
#include "smart_objects/always_true_schema_item.h"
#include "smart_objects/schema_item_parameter.h"
-namespace NsSmartDeviceLink {
-namespace NsSmartObjects {
+#include "utils/semantic_version.h"
+
+namespace ns_smart_device_link {
+namespace ns_smart_objects {
/**
* @brief Array schema item.
**/
@@ -55,7 +56,7 @@ class CArraySchemaItem : public ISchemaItem {
*
* @return Shared pointer to a new schema item.
**/
- static utils::SharedPtr<CArraySchemaItem> create(
+ static std::shared_ptr<CArraySchemaItem> create(
const ISchemaItemPtr ElementSchemaItem = CAlwaysTrueSchemaItem::create(),
const TSchemaItemParameter<size_t>& MinSize =
TSchemaItemParameter<size_t>(),
@@ -63,27 +64,16 @@ class CArraySchemaItem : public ISchemaItem {
TSchemaItemParameter<size_t>());
/**
- * @deprecated
- *
* @brief Validate smart object.
- *
- * @param Object Object to validate.
- *
- * @return NsSmartObjects::Errors::eType
- **/
- Errors::eType validate(const SmartObject& Object) OVERRIDE;
-
- /**
- * @brief Validate smart object.
- *
* @param Object Object to validate.
* @param report__ object for reporting errors during validation
- * message if an error occurs
- *
- * @return NsSmartObjects::Errors::eType
+ * @param MessageVersion to check mobile RPC version against RPC Spec History
+ * @return ns_smart_objects::errors::eType
**/
- Errors::eType validate(const SmartObject& Object,
- rpc::ValidationReport* report__) OVERRIDE;
+ errors::eType validate(const SmartObject& Object,
+ rpc::ValidationReport* report__,
+ const utils::SemanticVersion& MessageVersion =
+ utils::SemanticVersion()) OVERRIDE;
/**
* @brief Apply schema.
@@ -94,7 +84,9 @@ class CArraySchemaItem : public ISchemaItem {
* from smart object otherwise contains false.
**/
void applySchema(SmartObject& Object,
- const bool RemoveFakeParameters) OVERRIDE;
+ const bool RemoveFakeParameters,
+ const utils::SemanticVersion& MessageVersion =
+ utils::SemanticVersion()) OVERRIDE;
/**
* @brief Unapply schema.
@@ -138,7 +130,7 @@ class CArraySchemaItem : public ISchemaItem {
const TSchemaItemParameter<size_t> mMaxSize;
DISALLOW_COPY_AND_ASSIGN(CArraySchemaItem);
};
-} // namespace NsSmartObjects
-} // namespace NsSmartDeviceLink
+} // namespace ns_smart_objects
+} // namespace ns_smart_device_link
#endif // SRC_COMPONENTS_SMART_OBJECTS_INCLUDE_SMART_OBJECTS_ARRAY_SCHEMA_ITEM_H_