Examples of optArray()


Examples of org.mapfish.print.wrapper.json.PJsonObject.optArray()

    private static List<String> getTableColumnKeys(final PJsonObject oldTablePage) {
        final PJsonObject table = oldTablePage.optJSONObject("table");
        final List<String> columnKeys = new LinkedList<String>();
        if (table != null) {
            final PArray columns = table.optArray("columns", new PJsonArray(table, new JSONArray(), "columns"));

            for (int i = 0; i < columns.size(); i++) {
                columnKeys.add(columns.getString(i));
            }
        }
View Full Code Here

Examples of org.mapfish.print.wrapper.json.PJsonObject.optArray()

            final PJsonObject oldTablePage) {
        final PJsonObject table = oldTablePage.optJSONObject("table");

        final List<JSONArray> tableData = new LinkedList<JSONArray>();
        if (table != null) {
            final PArray oldTableRows = table.optArray("data", new PJsonArray(table, new JSONArray(), "data"));

            for (int i = 0; i < oldTableRows.size(); i++) {
                final PObject oldRow = oldTableRows.getObject(i);
                if (!oldRow.keys().hasNext()) {
                    // row is empty, skip
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.