Class GsonFactory

java.lang.Object
com.amilesend.tvmaze.client.parse.GsonFactory

public class GsonFactory extends Object
Factory that vends new pre-configured Gson instances.
  • Method Details

    • getInstance

      public static GsonFactory getInstance()
      Gets the singleton GsonFactory instance.
      Returns:
      the factory instance
    • newInstanceForConnection

      public com.google.gson.Gson newInstanceForConnection()
      Gets a new Gson instance that is configured for use by Connection.
      Returns:
      the pre-configured Gson instance
    • newInstanceForPrettyPrinting

      public com.google.gson.Gson newInstanceForPrettyPrinting()
      Gets a new Gson instance that is configured for use by Connection that provides pretty-printed formatted JSON (i.e., useful for testing and/or debugging).
      Returns:
      the pre-configured Gson instance