Package com.google.refine.freebase

Examples of com.google.refine.freebase.FreebaseType


            boolean included = (obj.has("included") && obj.getBoolean("included"));
            if (included && columns != null) {
                JSONObject expected = obj.getJSONObject("expected");
               
                columns.add(new ColumnInfo(names2, path2,
                    new FreebaseType(expected.getString("id"), expected.getString("name"))));
            }
           
            return (included ? 1 : 0) +
                countColumns(obj.getJSONArray("properties"), columns, names2, path2);
        } else {
            if (columns != null) {
                JSONObject expected = obj.getJSONObject("expected");
               
                columns.add(new ColumnInfo(names2, path2,
                    new FreebaseType(expected.getString("id"), expected.getString("name"))));
            }
            return 1;
        }
    }
View Full Code Here


   
    static public ReconConfig reconstruct(JSONObject obj) throws Exception {
        JSONObject type = obj.getJSONObject("type");
       
        return new DataExtensionReconConfig(
            new FreebaseType(
                type.getString("id"),
                type.getString("name")
            )
        );
    }
View Full Code Here

            o.getString("name")
        );
    }
   
    static protected FreebaseType reconstructType(JSONObject o) throws JSONException {
        return new FreebaseType(
            o.getString("id"),
            o.getString("name")
        );
    }
View Full Code Here

TOP

Related Classes of com.google.refine.freebase.FreebaseType

Copyright © 2018 www.massapicom. 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.