Package org.jboss.riftsaw.management

Source Code of org.jboss.riftsaw.management.GsonFactory

package org.jboss.riftsaw.management;


import com.google.gson.Gson;
import com.google.gson.GsonBuilder;

/**
* @author Heiko.Braun <heiko.braun@jboss.com>
*/
public class GsonFactory
{
   public static Gson createInstance()
   {
      Gson gson = new GsonBuilder()
        .setDateFormat("yyyy-MM-dd HH:mm:ss")
        .registerTypeAdapter(java.sql.Timestamp.class, new SQLDateTypeAdapter())
        .create();
      return gson;
   }
}
TOP

Related Classes of org.jboss.riftsaw.management.GsonFactory

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.