From 48766f17111f750861e596c64c069f709a9fb896 Mon Sep 17 00:00:00 2001
From: Alessandro Abrami <alessandro.abrami@elettra.eu>
Date: Thu, 7 Oct 2021 10:35:15 +0200
Subject: [PATCH] 2021/10/07: deleted src/Afifo.cpp src/Afifo.h
 src/RequestHistory.cpp src/ThisCmd.cpp

---
 deps/libhist         |  2 +-
 src/AxisG2Selector.h |  5 ---
 src/ThisCmd.cpp      | 97 --------------------------------------------
 3 files changed, 1 insertion(+), 103 deletions(-)
 delete mode 100644 src/ThisCmd.cpp

diff --git a/deps/libhist b/deps/libhist
index 87b72d5..6769911 160000
--- a/deps/libhist
+++ b/deps/libhist
@@ -1 +1 @@
-Subproject commit 87b72d5f50ce2a93ad93546c7988a2db2bfc920f
+Subproject commit 67699117c83233775cbf0d58258ed8e430e1fbf9
diff --git a/src/AxisG2Selector.h b/src/AxisG2Selector.h
index 2407b5c..eaf7f54 100644
--- a/src/AxisG2Selector.h
+++ b/src/AxisG2Selector.h
@@ -466,11 +466,6 @@ public:
 	vector<string> getUserConfigData(const Tango::ConstDevString *w_val, int w_length);
 	bool Targets2Config(vector<Target>& trgs, vector<string>& targets);
 
-	string ThisCmd();
-        void RequestHistory(Tango::DevString *extstatusattr, int *riga, string msg);
-        void read_RequestHistory(int *riga, int *howmany);
-
-
 
 /*----- PROTECTED REGION END -----*/	//	AxisG2Selector::Additional Method prototypes
 };
diff --git a/src/ThisCmd.cpp b/src/ThisCmd.cpp
deleted file mode 100644
index 8a7a215..0000000
--- a/src/ThisCmd.cpp
+++ /dev/null
@@ -1,97 +0,0 @@
-#include "AxisG2Selector.h"
-
-
-/*
-Nota: solo in always_execute_hook() si puo' essere certi che bb[0] sia l'operazione corrente,
-gia' a livello di esecuzione del codice del comando (ad es. get_image() ...)
-questa assunzione non e' piu' certa.
-
-Allora disogna andare nel recente passato di bb alla ricerca dell'entry con command_inout
-
-In realta' vedo (su srv-ccd-padres-03) che nemmeno in always_execute_hook() e' garantita
-la consequenzialita' e quindi l'esattezza di bb() !!!!
-
-
-
-*/
-
-namespace AxisG2Selector_ns {
-
-
-string AxisG2Selector::ThisCmd(){
-
-	string CMD_TAG("command_inout");
-	string thiscmd("__XX_XX__XXX__");
-	std::size_t found(std::string::npos);
-        Tango::DevVarStringArray* bb = NULL;
-
-	struct timeval t0, t1;
-	float elaps;
-	stringstream ss;
-	ss.str("");
-
-	gettimeofday(&t0, NULL);
-	{
-    	  vector<string> vs;
-	  try {
-                bb = black_box(8);
-		vs << (*bb);
-                #ifdef _DBG_BB
-                        cout << "ThisCmd():: |" << endl;
-			for (vector<string>::iterator it = vs.begin(); it != vs.end(); ++it) cout << "\t__BB_IN__THISCMD__ [" << distance(vs.begin(), it) << "]: " << *it << endl;
-                #endif /* _DBG_BB */
-
-		for (vector<string>::iterator it = vs.begin(); (it != vs.end()) && (found==std::string::npos); ++it) {
-			found = (*it).find(CMD_TAG);
-			if ( found != std::string::npos ) {
-				thiscmd = *it;
-		 	} else {
-				ss.str("");
-				ss << "{" << bb->length() << "} ";
-				thiscmd += ss.str();
-			}
-		}
-	  } catch (Tango::DevFailed e) {
-                if (e.errors.length() > 0){
-                        thiscmd += e.errors[0].reason.in();
-                } else {
-			thiscmd += "Tango except";
-		}
-	  } catch (...) {
-		cout << "ThisCmd()::BB:: Except!" << endl;
-		thiscmd += "General except";
-	  }
-          if (bb != NULL ) delete bb;
-	}
-	//cout << "thiscmd=|" << thiscmd << "|" << endl;
-
-	string op(": Operation command_inout_");
-	found = thiscmd.find(op);
-	if (found!=std::string::npos) thiscmd.erase(found, op.size()+2);
-
-	op = ": Operation command_inout";
-	found = thiscmd.find(op);
-	if (found!=std::string::npos) thiscmd.erase(found, op.size()+1);
-
-	op = "from";
-	found = thiscmd.find(op);
-	if (found!=std::string::npos) thiscmd.erase(found, op.size()+1);
-
-	op = "requested from";
-	found = thiscmd.find(op);
-	if (found!=std::string::npos) thiscmd.erase(found, op.size()+1);
-
-	op = "client with";
-	found = thiscmd.find(op);
-	if (found!=std::string::npos) thiscmd.erase(found, op.size()+1);
-
-	gettimeofday(&t1, NULL);
-	elaps = ((float)(t1.tv_sec - t0.tv_sec))*1000 +((float)(t1.tv_usec - t0.tv_usec))/1000;
-	ss.str("");
-	ss << " [" << elaps << "ms]";
-	thiscmd += ss.str();
-
-	return thiscmd;
-}
-
-} //namespace
-- 
GitLab