Class CdaQueryBackend
- java.lang.Object
-
- org.pentaho.reporting.engine.classic.extensions.datasources.cda.CdaQueryBackend
-
- All Implemented Interfaces:
Cloneable
- Direct Known Subclasses:
HttpQueryBackend
public abstract class CdaQueryBackend extends Object implements Cloneable
Abstract Class that will be extended by each implementation of CDA invocation LOCAL or HTTP- Author:
- dduque
-
-
Field Summary
Fields Modifier and Type Field Description static String
DATA_ACCESS_ID
static String
METHOD_DO_QUERY
static String
METHOD_LIST_PARAMETERS
static String
PARAM_DEFAULT_VALUE
static String
PARAM_NAME
static String
PARAM_PATTERN
static String
PARAM_TYPE
static String
TYPE_ARRAY_SUFFIX
static String
TYPE_DATE
static String
TYPE_INTEGER
static String
TYPE_NUMERIC
static String
TYPE_STRING
-
Constructor Summary
Constructors Constructor Description CdaQueryBackend()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
cancelRunningQuery()
Object
clone()
String
createURL(String method, Map<String,String> extraParameter)
protected String
encodeParameter(String value)
abstract org.pentaho.reporting.engine.classic.core.util.TypedTableModel
fetchData(org.pentaho.reporting.engine.classic.core.DataRow dataRow, String method, Map<String,String> extraParameter)
Fetch the data, has to be implemented in each sub classprotected org.pentaho.reporting.engine.classic.core.util.TypedTableModel
fetchParameter(org.pentaho.reporting.engine.classic.core.DataRow dataRow, CdaQueryEntry realQuery)
String
getBaseUrl()
protected org.pentaho.reporting.engine.classic.core.DataFactoryContext
getContext()
String
getFile()
String
getPassword()
String
getPath()
String
getSolution()
String
getUsername()
void
initialize(org.pentaho.reporting.engine.classic.core.DataFactoryContext context)
boolean
isSugarMode()
protected String
parameterToString(String name, String type, String pattern, Object raw)
TableModel
queryData(CdaQueryEntry realQuery, org.pentaho.reporting.engine.classic.core.DataRow parameters)
void
setBaseUrl(String baseUrl)
void
setFile(String file)
void
setPassword(String password)
void
setPath(String path)
void
setSolution(String solution)
void
setSugarMode(boolean sugarMode)
void
setUsername(String username)
-
-
-
Field Detail
-
METHOD_LIST_PARAMETERS
public static final String METHOD_LIST_PARAMETERS
- See Also:
- Constant Field Values
-
DATA_ACCESS_ID
public static final String DATA_ACCESS_ID
- See Also:
- Constant Field Values
-
METHOD_DO_QUERY
public static final String METHOD_DO_QUERY
- See Also:
- Constant Field Values
-
PARAM_NAME
public static final String PARAM_NAME
- See Also:
- Constant Field Values
-
PARAM_TYPE
public static final String PARAM_TYPE
- See Also:
- Constant Field Values
-
PARAM_DEFAULT_VALUE
public static final String PARAM_DEFAULT_VALUE
- See Also:
- Constant Field Values
-
PARAM_PATTERN
public static final String PARAM_PATTERN
- See Also:
- Constant Field Values
-
TYPE_DATE
public static final String TYPE_DATE
- See Also:
- Constant Field Values
-
TYPE_INTEGER
public static final String TYPE_INTEGER
- See Also:
- Constant Field Values
-
TYPE_NUMERIC
public static final String TYPE_NUMERIC
- See Also:
- Constant Field Values
-
TYPE_STRING
public static final String TYPE_STRING
- See Also:
- Constant Field Values
-
TYPE_ARRAY_SUFFIX
public static final String TYPE_ARRAY_SUFFIX
- See Also:
- Constant Field Values
-
-
Method Detail
-
initialize
public void initialize(org.pentaho.reporting.engine.classic.core.DataFactoryContext context)
-
getContext
protected org.pentaho.reporting.engine.classic.core.DataFactoryContext getContext()
-
parameterToString
protected String parameterToString(String name, String type, String pattern, Object raw) throws org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
- Throws:
org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
-
fetchParameter
protected org.pentaho.reporting.engine.classic.core.util.TypedTableModel fetchParameter(org.pentaho.reporting.engine.classic.core.DataRow dataRow, CdaQueryEntry realQuery) throws org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
- Throws:
org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
-
queryData
public TableModel queryData(CdaQueryEntry realQuery, org.pentaho.reporting.engine.classic.core.DataRow parameters) throws org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
- Throws:
org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
-
fetchData
public abstract org.pentaho.reporting.engine.classic.core.util.TypedTableModel fetchData(org.pentaho.reporting.engine.classic.core.DataRow dataRow, String method, Map<String,String> extraParameter) throws org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
Fetch the data, has to be implemented in each sub class- Parameters:
dataRow
-method
-extraParameter
-- Returns:
- Throws:
org.pentaho.reporting.engine.classic.core.ReportDataFactoryException
-
getUsername
public String getUsername()
-
setUsername
public void setUsername(String username)
-
getPassword
public String getPassword()
-
setPassword
public void setPassword(String password)
-
getSolution
public String getSolution()
-
setSolution
public void setSolution(String solution)
-
getPath
public String getPath()
-
setPath
public void setPath(String path)
-
getFile
public String getFile()
-
setFile
public void setFile(String file)
-
getBaseUrl
public String getBaseUrl()
-
setBaseUrl
public void setBaseUrl(String baseUrl)
-
isSugarMode
public boolean isSugarMode()
-
setSugarMode
public void setSugarMode(boolean sugarMode)
-
cancelRunningQuery
public void cancelRunningQuery()
-
-