The following issues were found
src/test/java/com/alibaba/json/bvtVO/AccessHttpConfigModel.java
3 issues
Line: 6
import java.io.Serializable;
public class AccessHttpConfigModel {
/**
* 上传文件的配置.
*
* @author wangwb (mailto:wangwb@primeton.com)
*/
Reported by PMD.
Line: 13
* @author wangwb (mailto:wangwb@primeton.com)
*/
public static class FileUploadConfig implements Serializable{
private String tempDir;
private int maxSize;
private int inMemorySize;
Reported by PMD.
Line: 13
* @author wangwb (mailto:wangwb@primeton.com)
*/
public static class FileUploadConfig implements Serializable{
private String tempDir;
private int maxSize;
private int inMemorySize;
Reported by PMD.
src/test/java/com/alibaba/json/bvt/writeClassName/WriteDuplicateType.java
3 issues
Line: 16
public class WriteDuplicateType extends TestCase {
public void test_dupType() throws Exception {
DianDianCart cart = new DianDianCart();
cart.setId(1001);
LinkedHashMap<String, JSONObject> cartMap = new LinkedHashMap<String, JSONObject>();
Reported by PMD.
Line: 32
}
public void test_dupType2() throws Exception {
DianDianCart cart = new DianDianCart();
cart.setId(1001);
LinkedHashMap<String, HashMap<String, Object>> cartMap = new LinkedHashMap<String, HashMap<String, Object>>();
Reported by PMD.
Line: 49
}
public void test_dupType3() throws Exception {
DianDianCart cart = new DianDianCart();
cart.setId(1001);
LinkedHashMap<String, LinkedHashMap<String, Object>> cartMap = new LinkedHashMap<String, LinkedHashMap<String, Object>>();
Reported by PMD.
src/test/java/com/alibaba/json/test/a/GsonTest.java
3 issues
Line: 11
* Created by wenshao on 04/02/2017.
*/
public class GsonTest extends TestCase {
public void test_0() throws Exception {
String text = "{\"loader\":\"com.sun.org.apache.bcel.internal.util.ClassLoader\"}";
// Gson gson = new Gson();
// gson.fromJson(text, Model.class);
Reported by PMD.
Line: 11
* Created by wenshao on 04/02/2017.
*/
public class GsonTest extends TestCase {
public void test_0() throws Exception {
String text = "{\"loader\":\"com.sun.org.apache.bcel.internal.util.ClassLoader\"}";
// Gson gson = new Gson();
// gson.fromJson(text, Model.class);
Reported by PMD.
Line: 4
package com.alibaba.json.test.a;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.gson.Gson;
import junit.framework.TestCase;
/**
* Created by wenshao on 04/02/2017.
*/
Reported by PMD.
src/test/java/com/alibaba/json/demo/Demo1.java
3 issues
Line: 18
jsonObject.put("salary", new BigDecimal(8000));
String text = jsonObject.toJSONString();
System.out.println(text);
}
}
Reported by PMD.
Line: 11
public class Demo1 extends TestCase {
public void test_0() throws Exception {
JSONObject jsonObject = new JSONObject();
jsonObject.put("name", "Jobs");
jsonObject.put("age", 50);
jsonObject.put("salary", new BigDecimal(8000));
Reported by PMD.
Line: 11
public class Demo1 extends TestCase {
public void test_0() throws Exception {
JSONObject jsonObject = new JSONObject();
jsonObject.put("name", "Jobs");
jsonObject.put("age", 50);
jsonObject.put("salary", new BigDecimal(8000));
Reported by PMD.
src/test/java/com/alibaba/json/test/benchmark/encode/GroupEncode.java
3 issues
Line: 15
public class GroupEncode extends BenchmarkCase {
private Object object;
public GroupEncode(){
super("GroupEncode");
try {
Reported by PMD.
Line: 22
try {
String resource = "json/group.json";
InputStream is = Thread.currentThread().getContextClassLoader().getResourceAsStream(resource);
String text = IOUtils.toString(is);
is.close();
object = JSON.parseObject(text, Group.class);
} catch (IOException ex) {
Reported by PMD.
Line: 28
object = JSON.parseObject(text, Group.class);
} catch (IOException ex) {
ex.printStackTrace();
}
}
@Override
public void execute(Codec codec) throws Exception {
Reported by PMD.
src/test/java/com/alibaba/json/test/benchmark/entity/Entity100String.java
3 issues
Line: 1
package com.alibaba.json.test.benchmark.entity;
public class Entity100String {
private String f0 = "0";
private String f1 = "1";
private String f2 = "2";
private String f3 = "3";
private String f4 = "4";
Reported by PMD.
Line: 3
package com.alibaba.json.test.benchmark.entity;
public class Entity100String {
private String f0 = "0";
private String f1 = "1";
private String f2 = "2";
private String f3 = "3";
private String f4 = "4";
Reported by PMD.
Line: 3
package com.alibaba.json.test.benchmark.entity;
public class Entity100String {
private String f0 = "0";
private String f1 = "1";
private String f2 = "2";
private String f3 = "3";
private String f4 = "4";
Reported by PMD.
src/test/java/com/alibaba/json/test/codegen/GenTest.java
3 issues
Line: 17
generator.gen();
System.out.println(out.toString());
}
}
Reported by PMD.
Line: 11
public class GenTest extends TestCase {
public void test_codegen() throws Exception {
StringBuffer out = new StringBuffer();
DeserializerGen generator = new DeserializerGen(MediaContent.class, out);
generator.gen();
Reported by PMD.
Line: 11
public class GenTest extends TestCase {
public void test_codegen() throws Exception {
StringBuffer out = new StringBuffer();
DeserializerGen generator = new DeserializerGen(MediaContent.class, out);
generator.gen();
Reported by PMD.
src/test/java/com/alibaba/json/test/tmall/RateSearchItemDO.java
3 issues
Line: 1
package com.alibaba.json.test.tmall;
import com.alibaba.fastjson.annotation.JSONField;
/**
* ���������������
* User: jingxian.lzg
* Date: 2015/8/17
* Time: 16:26
Reported by PMD.
Line: 11
* Date: 2015/8/17
* Time: 16:26
*/
public class RateSearchItemDO {
/**
* ����id
*/
@JSONField(name = "feed_id")
private long feedId;
Reported by PMD.
Line: 11
* Date: 2015/8/17
* Time: 16:26
*/
public class RateSearchItemDO {
/**
* ����id
*/
@JSONField(name = "feed_id")
private long feedId;
Reported by PMD.
src/test/java/com/derbysoft/spitfire/fastjson/Generic.java
3 issues
Line: 6
import java.io.Serializable;
import java.util.List;
public class Generic<T> implements Serializable{
String header;
T payload;
// List<T>
Reported by PMD.
Line: 6
import java.io.Serializable;
import java.util.List;
public class Generic<T> implements Serializable{
String header;
T payload;
// List<T>
Reported by PMD.
Line: 4
package com.derbysoft.spitfire.fastjson;
import java.io.Serializable;
import java.util.List;
public class Generic<T> implements Serializable{
String header;
T payload;
Reported by PMD.
src/test/java/com/alibaba/json/test/entity/case1/IntObject_100_Entity.java
3 issues
Line: 1
package com.alibaba.json.test.entity.case1;
public class IntObject_100_Entity {
private Integer f0;
private Integer f1;
private Integer f2;
private Integer f3;
private Integer f4;
Reported by PMD.
Line: 3
package com.alibaba.json.test.entity.case1;
public class IntObject_100_Entity {
private Integer f0;
private Integer f1;
private Integer f2;
private Integer f3;
private Integer f4;
Reported by PMD.
Line: 3
package com.alibaba.json.test.entity.case1;
public class IntObject_100_Entity {
private Integer f0;
private Integer f1;
private Integer f2;
private Integer f3;
private Integer f4;
Reported by PMD.