资源简介
2019年全国大学生软件测试大赛全国总决赛,开发者测试赛项中,“json”题目资源下载,可直接导入eclipse运行。本题使用的源码来自eclipse的json模块,在安装mooctest插件的eclipse中可以查看自己的行覆盖和分支覆盖以及成绩。

代码片段和文件信息
/*******************************************************************************
* Copyright (c) 2015 2016 EclipseSource.
*
* Permission is hereby granted free of charge to any person obtaining a copy
* of this software and associated documentation files (the “Software“) to deal
* in the Software without restriction including without limitation the rights
* to use copy modify merge publish distribute sublicense and/or sell
* copies of the Software and to permit persons to whom the Software is
* furnished to do so subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED “AS IS“ WITHOUT WARRANTY OF ANY KIND EXPRESS OR
* IMPLIED INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM DAMAGES OR OTHER
* LIABILITY WHETHER IN AN ACTION OF CONTRACT TORT OR OTHERWISE ARISING FROM
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
******************************************************************************/
package net.mooctest;
import java.io.IOException;
import java.io.Reader;
/**
* This class serves as the entry point to the minimal-json API.
*
* To parse a given JSON input use the parse()
methods like in this
* example:
*
*
* Jsonobject object = Json.parse(string).asobject();
*
*
* To create a JSON data structure to be serialized use the methods
* value()
array()
and object()
. For example the following
* snippet will produce the JSON string {“foo“: 23 “bar“: true}:
*
*
* String string = Json.object().add(“foo“ 23).add(“bar“ true).toString();
*
*
* To create a JSON array from a given Java array you can use one of the array()
* methods with varargs parameters:
*
*
* String[] names = ...
* JsonArray array = Json.array(names);
*
*/
public final class Json {
private Json() {
// not meant to be instantiated
}
/**
* Represents the JSON literal null
.
*/
public static final JsonValue NULL = new JsonLiteral(“null“);
/**
* Represents the JSON literal true
.
*/
public static final JsonValue TRUE = new JsonLiteral(“true“);
/**
* Represents the JSON literal false
.
*/
public static final JsonValue FALSE = new JsonLiteral(“false“);
/**
* Returns a JsonValue instance that represents the given int
value.
*
* @param value
* the value to get a JSON representation for
* @return a JSON value that represents the given value
*/
public static JsonValue value(int value) {
return new
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 955 2019-11-28 10:14 .classpath
文件 556 2019-11-28 10:08 .project
目录 0 2019-11-28 10:08 .settings\
文件 93 2019-11-28 10:09 .settings\org.eclipse.core.resources.prefs
文件 243 2019-11-28 10:09 .settings\org.eclipse.jdt.core.prefs
文件 90 2019-11-28 10:08 .settings\org.eclipse.m2e.core.prefs
文件 1537 2019-11-28 10:49 pom.xm
目录 0 2019-11-28 10:08 src\
目录 0 2019-11-28 10:08 src\main\
目录 0 2019-11-28 10:14 src\main\java\
目录 0 2019-11-28 10:08 src\main\java\net\
目录 0 2019-11-28 10:11 src\main\java\net\mooctest\
文件 11557 2019-11-28 10:11 src\main\java\net\mooctest\Json.java
文件 16348 2019-11-28 10:12 src\main\java\net\mooctest\JsonArray.java
文件 9749 2019-11-28 10:12 src\main\java\net\mooctest\JsonHandler.java
文件 2641 2019-11-28 10:12 src\main\java\net\mooctest\JsonLiteral.java
文件 2553 2019-11-28 10:12 src\main\java\net\mooctest\JsonNumber.java
文件 34827 2019-11-28 10:14 src\main\java\net\mooctest\Jsonob
文件 13382 2019-11-28 10:12 src\main\java\net\mooctest\JsonParser.java
文件 2224 2019-11-28 10:12 src\main\java\net\mooctest\JsonString.java
文件 16878 2019-11-28 10:12 src\main\java\net\mooctest\JsonValue.java
文件 4728 2019-11-28 10:12 src\main\java\net\mooctest\JsonWriter.java
文件 2248 2019-11-28 10:12 src\main\java\net\mooctest\Location.java
文件 2859 2019-11-28 10:12 src\main\java\net\mooctest\ParseException.java
文件 4445 2019-11-28 10:12 src\main\java\net\mooctest\PrettyPrint.java
文件 1974 2019-11-28 10:12 src\main\java\net\mooctest\WriterConfig.java
文件 3074 2019-11-28 10:12 src\main\java\net\mooctest\WritingBuffer.java
目录 0 2019-11-28 10:08 src\test\
目录 0 2019-11-28 10:08 src\test\java\
目录 0 2019-11-28 10:08 src\test\java\net\
目录 0 2019-11-28 10:49 src\test\java\net\mooctest\
............此处省略4个文件信息
- 上一篇:千锋ElasticSearch6教程的资料
- 下一篇:ECSHOP版权
相关资源
- GBT 15532-2008 计算机软件测试规范
- 华为校园招聘机试题目
- 软件方法测试RTX时钟
- 通信类大公司华为中兴公司面试题目
- 历年深信服软件测试师考试题
- 一个不错的测试用例计划——物业管
- 数字电路课程设计—交通灯
- 软件测试技术大全:测试基础、流行
- 2017黑马软件测试全套完整视频教程
- 软件测试试题卷
- 小马老师2019年上半年软考高项课件
- 程序设计实践(ACM)
- 科来杯山东省大学生网络安全技能大
- 中创入职定级考试题目及答案
- 中科大软院软件测试3
- 软件测试参考论文
- 泰迪杯20162017年题目及优秀论文
- 2016山东省NOI省队集训DAY2 题目题解数
- 联通面试和笔试题目.
- 中国移动软件测试工程师笔试题
- 2012年微机原理课程设计题目
- 1994-2016全国大学生电子设计竞赛仪器
- 亚信面试题目
- 工商银行笔试题目及面试题目
- 湖南大学 计算机组成与原理实验题目
- 软件测试实验报告——LR
- 电子技术基础课程设计题目数字部分
- 苏宁企业文化考试题目2020年11月
- 2019美赛ABCDEF题题目附C题数据
- 数学建模美国赛2004MCM-A Faster QuickPas
评论
共有 条评论