Package com.google.refine.freebase

Examples of com.google.refine.freebase.FreebaseTopic


   
    static public ReconConfig reconstruct(JSONObject obj) throws Exception {
        JSONObject ns = obj.getJSONObject("namespace");
       
        return new KeyBasedReconConfig(
            new FreebaseTopic(
                ns.getString("id"),
                ns.getString("name")
            )
        );
    }
View Full Code Here


    protected JSONObject addJsonContext(JSONObject parent, String key, Object value) {
        JSONObject o = new JSONObject();
       
        try {
            if (value instanceof FreebaseTopic) {
                FreebaseTopic topic = (FreebaseTopic) value;
                o.put("id", topic.id);
                o.put("name", topic.name);
            } else {
                o.put("v", value);
            }
View Full Code Here

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

TOP

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

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.