import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.gson.Gson;
import de.undercouch.bson4jackson.BsonFactory;
public class jack {
public static void main(String ss[]) throws Exception
{
testuser t=new testuser();
t.setId(1);
t.setUsername("admin");
t.setPassword("admin88888");
Gson gson = new Gson();
String str = gson.toJson(t);
FileOutputStream in = new FileOutputStream("c:/jack1.bin");
in.write(str.getBytes());
in.flush();
in.close();
FileOutputStream baos = new FileOutputStream("c:/jack.bin");
ObjectMapper mapper = new Obj