类 JSONDatastore

java.lang.Object
com.sh.javax.datastore.Datastore
com.sh.javax.datastore.JSONDatastore
所有已实现的接口:
DatastoreInterface, Serializable, Cloneable

public class JSONDatastore extends Datastore

Description: 基于JSON的数据集

Title:首亨软件 - 聚天平台

从以下版本开始:
2018年11月23日
另请参阅:
  • 构造器详细资料

    • JSONDatastore

      public JSONDatastore()
  • 方法详细资料

    • fromJSONArray

      public static Datastore fromJSONArray(JSONArray array)
      通过JSONArray转换为数据集Datastore
      参数:
      array -
      返回:
      Datastore
    • load

      public boolean load(String key)
    • refresh

      public boolean refresh(String key)
    • load

      public boolean load(String key, List<RequestPagesConfig_Head> headList)
    • refresh

      public boolean refresh(String key, List<RequestPagesConfig_Head> headList)
      重新生成数据集,因为一个Json对象中可能包含多个数组,将json转化为方便操作的Datastore对象
      参数:
      key - 数组对应的键值,可以对应数组或对象,key1.key2的方式指定路径
      headList - List
      返回:
      boolean
    • getJsonDataObj

      public JSONObject getJsonDataObj()
    • setJsonDataObj

      public void setJsonDataObj(JSONObject jsonDataObj)
    • setJsonDataObj

      public boolean setJsonDataObj(JSONArray dataArray)
    • setCallback

      public void setCallback(JSONDatastoreRender_I callback)