github.com/keysonZZZ/kmg@v0.0.0-20151121023212-05317bfd7d39/kmgRpc/kmgRpcJava/java/src/com/google/gson/JsonSyntaxException.java (about)

     1  /*
     2   * Copyright (C) 2010 Google Inc.
     3   *
     4   * Licensed under the Apache License, Version 2.0 (the "License");
     5   * you may not use this file except in compliance with the License.
     6   * You may obtain a copy of the License at
     7   *
     8   * http://www.apache.org/licenses/LICENSE-2.0
     9   *
    10   * Unless required by applicable law or agreed to in writing, software
    11   * distributed under the License is distributed on an "AS IS" BASIS,
    12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    13   * See the License for the specific language governing permissions and
    14   * limitations under the License.
    15   */
    16  package com.google.gson;
    17  
    18  /**
    19   * This exception is raised when Gson attempts to read (or write) a malformed
    20   * JSON element.
    21   *
    22   * @author Inderjeet Singh
    23   * @author Joel Leitch
    24   */
    25  public final class JsonSyntaxException extends JsonParseException {
    26  
    27    private static final long serialVersionUID = 1L;
    28  
    29    public JsonSyntaxException(String msg) {
    30      super(msg);
    31    }
    32  
    33    public JsonSyntaxException(String msg, Throwable cause) {
    34      super(msg, cause);
    35    }
    36  
    37    /**
    38     * Creates exception with the specified cause. Consider using
    39     * {@link #JsonSyntaxException(String, Throwable)} instead if you can
    40     * describe what actually happened.
    41     *
    42     * @param cause root exception that caused this exception to be thrown.
    43     */
    44    public JsonSyntaxException(Throwable cause) {
    45      super(cause);
    46    }
    47  }