Remove need for synthetic accessor methods.

This commit is contained in:
Eric Cochran 2017-04-22 17:32:59 -07:00
parent 5412f21431
commit 3270e8d972
3 changed files with 3 additions and 3 deletions

View File

@ -111,7 +111,7 @@ public abstract class UnsafeAllocator {
* throw an {@link java.lang.UnsupportedOperationException}
* @param c instance of the class to be checked
*/
private static void assertInstantiable(Class<?> c) {
static void assertInstantiable(Class<?> c) {
int modifiers = c.getModifiers();
if (Modifier.isInterface(modifiers)) {
throw new UnsupportedOperationException("Interface can't be instantiated! Interface name: " + c.getName());

View File

@ -41,7 +41,7 @@ import java.lang.reflect.Type;
public final class TreeTypeAdapter<T> extends TypeAdapter<T> {
private final JsonSerializer<T> serializer;
private final JsonDeserializer<T> deserializer;
private final Gson gson;
final Gson gson;
private final TypeToken<T> typeToken;
private final TypeAdapterFactory skipPast;
private final GsonContextImpl context = new GsonContextImpl();

View File

@ -1459,7 +1459,7 @@ public class JsonReader implements Closeable {
return getClass().getSimpleName() + locationString();
}
private String locationString() {
String locationString() {
int line = lineNumber + 1;
int column = pos - lineStart + 1;
return " at line " + line + " column " + column + " path " + getPath();