Browse Source

数据集接口

refactor
richie 5 years ago
parent
commit
1af53ffcff
  1. 3
      src/main/java/com/fr/plugin/db/redis/bean/ParameterBean.java
  2. 5
      src/main/java/com/fr/plugin/db/redis/util/RedisUtils.java

3
src/main/java/com/fr/plugin/db/redis/bean/ParameterBean.java

@ -1,7 +1,6 @@
package com.fr.plugin.db.redis.bean;
import com.fanruan.api.util.StringKit;
import com.fr.base.ParameterTypeHandler;
import com.fr.stable.ParameterProvider;
import java.util.ArrayList;
@ -17,7 +16,7 @@ public class ParameterBean{
public static final String NAME = "name";
public static final String VALUE = "value";
private String type = ParameterTypeHandler.String.name();
private String type = "String";
private String name;
private String value;

5
src/main/java/com/fr/plugin/db/redis/util/RedisUtils.java

@ -6,7 +6,6 @@ import com.fanruan.api.util.ArrayKit;
import com.fanruan.api.util.GeneralKit;
import com.fanruan.api.util.RenderKit;
import com.fanruan.api.util.StringKit;
import com.fr.base.Parameter;
import com.fr.json.JSONArray;
import com.fr.plugin.db.redis.core.order.OrderValue;
import com.fr.plugin.db.redis.help.ScriptBridge;
@ -75,9 +74,9 @@ public class RedisUtils {
}
public static ParameterProvider[] analyzeParameter(JSONArray existParameters, OrderValue orderValue, String... parameterTexts) {
Parameter[] oldParameters = new Parameter[existParameters.size()];
ParameterProvider[] oldParameters = new ParameterProvider[existParameters.size()];
for (int i = 0; i < existParameters.size(); i++) {
oldParameters[i] = Parameter.getParameterFromJson(existParameters.getJSONObject(i));
oldParameters[i] = ParameterKit.json2Parameter(existParameters.getJSONObject(i));
}
ParameterProvider[] newParameters = ParameterKit.analyzeAndUnionSameParameters(parameterTexts, oldParameters);
ParameterProvider[] newOrderParameters = orderValue.analyze4Parameters();

Loading…
Cancel
Save