From 4fcc738461fad3d3b8f5009619df585ef1d4622e Mon Sep 17 00:00:00 2001
From: Jan Travnicek <Jan.Travnicek@fit.cvut.cz>
Date: Mon, 17 Jun 2019 08:51:06 +0200
Subject: [PATCH] remove not needed code

---
 .../src/abstraction/ValueProvider.hpp            | 16 ----------------
 alib2cli/src/environment/Environment.h           |  2 +-
 2 files changed, 1 insertion(+), 17 deletions(-)

diff --git a/alib2abstraction/src/abstraction/ValueProvider.hpp b/alib2abstraction/src/abstraction/ValueProvider.hpp
index 443a409ae4..82fc09159a 100644
--- a/alib2abstraction/src/abstraction/ValueProvider.hpp
+++ b/alib2abstraction/src/abstraction/ValueProvider.hpp
@@ -57,10 +57,6 @@ protected:
 	virtual Type & getData ( ) const = 0;
 
 public:
-	Type & getValueReference ( ) const {
-		return getData ( );
-	}
-
 	Type & getValue ( bool ) const {
 		return getData ( );
 	}
@@ -75,10 +71,6 @@ protected:
 	virtual const Type & getConstData ( ) const = 0;
 
 public:
-	const Type & getConstValueReference ( ) const {
-		return getConstData ( );
-	}
-
 	const Type & getValue ( bool ) const {
 		return getConstData ( );
 	}
@@ -93,10 +85,6 @@ protected:
 	virtual Type & getData ( ) const = 0;
 
 public:
-	Type && getRValueReference ( ) const {
-		return std::move ( getData ( ) );
-	}
-
 	Type && getValue ( bool move ) const {
 		if ( move )
 			return std::move ( getData ( ) );
@@ -114,10 +102,6 @@ protected:
 	virtual const Type & getConstData ( ) const = 0;
 
 public:
-	const Type && getConstRValueReference ( ) const {
-		return std::move ( getConstData ( ) );
-	}
-
 	const Type && getValue ( bool move ) const {
 		if ( move )
 			return std::move ( getConstData ( ) );
diff --git a/alib2cli/src/environment/Environment.h b/alib2cli/src/environment/Environment.h
index 8a89257a04..5279e44e07 100644
--- a/alib2cli/src/environment/Environment.h
+++ b/alib2cli/src/environment/Environment.h
@@ -81,7 +81,7 @@ public:
 		std::shared_ptr < abstraction::ValueProvider < const T & > > ptr = abstraction::translateParam < const T & > ( getVariableInt ( name ) );
 		if ( ! ptr )
 			throw exception::CommonException ( "Invalid variable type. Requested: " + ext::to_string < T > ( ) + ", actual : " + getVariableInt ( name )->getReturnType ( ) );
-		return ptr->getConstValueReference ( );
+		return ptr->getValue ( false );
 	}
 
 	std::set < std::string > getVariableNames ( ) const {
-- 
GitLab