perf[storage]: 优化storage,调整了结构并减少了重复的代码块

This commit is contained in:
godot
2022-07-08 15:34:10 +08:00
parent a6a276c8de
commit ba3e9051bc
41 changed files with 326 additions and 335 deletions
@@ -10,7 +10,6 @@
* See the License for the specific language governing permissions and limitations under the License.
*
*/
package com.zfoo.protocol.util;
import com.zfoo.protocol.model.Triple;
@@ -21,11 +20,9 @@ import org.junit.Test;
import java.util.*;
/**
* @author jaysunxiao
* @author godotg
* @version 3.0
*/
public class JsonUtilTest {
public static String id = "\"id\":\"1000\"";
@@ -114,5 +111,11 @@ public class JsonUtilTest {
var tripleStr = JsonUtils.object2String(triple);
var temp = JsonUtils.string2Object(tripleStr, Triple.class);
}
@Test
public void prettyPrinterTest() {
var user = JsonUtils.string2Object(userJson, User.class);
System.out.println(JsonUtils.object2StringPrettyPrinter(user));
}
}