Skip to content

Commit

Permalink
optimize
Browse files Browse the repository at this point in the history
  • Loading branch information
Gosling committed Jan 7, 2015
1 parent bcfec33 commit 5dd5dff
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 19 deletions.
23 changes: 8 additions & 15 deletions src/test/java/com/creative/commons/utils/CodecTest.java
Original file line number Diff line number Diff line change
@@ -1,28 +1,21 @@
package com.creative.commons.utils;

import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.*;
import java.util.concurrent.TimeUnit;

import com.caucho.hessian.io.*;
import com.creative.model.Certificates;
import com.creative.model.Father;
import com.creative.model.Message;
import com.creative.model.Son;
import com.google.common.base.Stopwatch;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;

import com.google.common.base.Stopwatch;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import java.io.*;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.*;
import java.util.concurrent.TimeUnit;

/**
* @author Von Gosling
Expand Down
7 changes: 3 additions & 4 deletions src/test/java/com/creative/commons/utils/JsonCodecTest.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.creative.commons.utils;

import com.creative.model.Father;
import com.creative.model.Message;
import com.creative.model.Son;
import com.google.common.base.Stopwatch;
Expand All @@ -19,9 +18,9 @@ public void jsonCodecSizeTest() throws Throwable {

@Test
public void jsonCodecTest() {
Father father = new Father();
byte[] obj1 = JsonCodec.encode(father);
Father fatherCopy = JsonCodec.decode(obj1, Father.class);
//Father father = new Father();
//byte[] obj1 = JsonCodec.encode(father);
//Father fatherCopy = JsonCodec.decode(obj1, Father.class);

//Timestamp type
//System.out.println(fatherCopy.getLocation_time());
Expand Down

0 comments on commit 5dd5dff

Please sign in to comment.