if(encodingFormatVersion.equalsIgnoreCase(QbeEngineStaticVariables.CURRENT_QUERY_VERSION)) {
abalysisStateJSON = rowDataJSON;
} else {
logger.warn("Row data encoding version [" + encodingFormatVersion + "] does not match with the current version used by the engine [" + QbeEngineStaticVariables.CURRENT_QUERY_VERSION + "] ");
logger.debug("Converting from encoding version [" + encodingFormatVersion + "] to encoding version [" + QbeEngineStaticVariables.CURRENT_QUERY_VERSION + "]....");
IQbeEngineAnalysisStateLoader analysisStateLoader;
analysisStateLoader = QbeEngineAnalysisStateLoaderFactory.getInstance().getLoader(encodingFormatVersion);
if(analysisStateLoader == null) {
throw new SpagoBIEngineException("Unable to load data stored in format [" + encodingFormatVersion + "] ");
}
abalysisStateJSON = (JSONObject)analysisStateLoader.load(str);
logger.debug("Encoding conversion has been executed succesfully");
}
JSONObject catalogueJSON = abalysisStateJSON.getJSONObject("catalogue");
JSONObject workSheetDefinitionJSON = abalysisStateJSON.optJSONObject(QbeEngineStaticVariables.WORKSHEET_DEFINITION_LOWER);