|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.api.ads.dfp.axis.utils.v201208.Pql
public final class Pql
A utility class for handling PQL objects.
| Method Summary | |
|---|---|
static Value |
createValue(Object value)
Creates a Value from the value i.e. |
static String[] |
getColumnLabels(ResultSet resultSet)
Gets the column labels for the result set. |
static String[] |
getRowStringValues(Row row)
Gets the values in a row of the result set in the form of a string array. |
static Object[] |
getRowValues(Row row)
Gets the values in a row of the result set in the form of an object array. |
static String |
resultSetToString(ResultSet resultSet)
Gets the result set as a table representation in the form of: |
static List<String[]> |
resultSetToStringArrayList(ResultSet resultSet)
Gets the result set as list of string arrays, which can be transformed to a CSV using CSVWriter. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static Value createValue(Object value)
Value from the value i.e. a TextValue for a
value of type String, BooleanValue for type
Boolean, NumberValue for type Double,
Long, or Integer, and DateTimeValue for type
DateTime. If the value is a Value, the value is returned.
If the value is null, an empty TextValue is returned.
value - the value to convert
IllegalArgumentException - if value cannot be convertedpublic static List<String[]> resultSetToStringArrayList(ResultSet resultSet)
CSVWriter.
resultSet - the result set to convert to a CSV compatible format
public static String resultSetToString(ResultSet resultSet)
throws IllegalAccessException
+-------+-------+-------+ |column1|column2|column3| +-------+-------+-------+ |value1 |value2 |value3 | +-------+-------+-------+ |value1 |value2 |value3 | +-------+-------+-------+
resultSet - the result set to display as a string
IllegalAccessException - if the values of the result set cannot be
accessedpublic static String[] getColumnLabels(ResultSet resultSet)
resultSet - the result set to get the column labels for
public static Object[] getRowValues(Row row)
throws IllegalArgumentException,
IllegalAccessException,
InvocationTargetException,
NoSuchMethodException
row - the row to get the values for
IllegalArgumentException - if the value could not be extracted from
the row value
IllegalAccessException - if the row value could not be accessed
NoSuchMethodException - if the row value could not be accessed
InvocationTargetException - if the row value could not be accessed
public static String[] getRowStringValues(Row row)
throws IllegalArgumentException,
IllegalAccessException,
InvocationTargetException,
NoSuchMethodException
null values are interpreted as empty strings.
row - the row to get the values for
IllegalArgumentException - if the value could not be extracted from
the row value
IllegalAccessException - if the row value could not be accessed
NoSuchMethodException - if the row value could not be accessed
InvocationTargetException - if the row value could not be accessed
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||