提交 bd556bd1 编写于 作者: J Jake Wharton

Visibility housekeeping: reduce to least access level.

上级 c7090c9c
......@@ -88,7 +88,7 @@ final class RequestBuilder {
relativeUrl = relativeUrl.replace("{" + name + "}", canonicalize(value, encoded));
}
static String canonicalize(String input, boolean alreadyEncoded) {
private static String canonicalize(String input, boolean alreadyEncoded) {
int codePoint;
for (int i = 0, limit = input.length(); i < limit; i += Character.charCount(codePoint)) {
codePoint = input.codePointAt(i);
......@@ -107,7 +107,8 @@ final class RequestBuilder {
return input;
}
static void canonicalize(Buffer out, String input, int pos, int limit, boolean alreadyEncoded) {
private static void canonicalize(Buffer out, String input, int pos, int limit,
boolean alreadyEncoded) {
Buffer utf8Buffer = null; // Lazily allocated.
int codePoint;
for (int i = pos; i < limit; i += Character.charCount(codePoint)) {
......
......@@ -531,7 +531,7 @@ final class RequestFactoryParser {
return patterns;
}
static Class<?> boxIfPrimitive(Class<?> type) {
private static Class<?> boxIfPrimitive(Class<?> type) {
if (boolean.class == type) return Boolean.class;
if (byte.class == type) return Byte.class;
if (char.class == type) return Character.class;
......
......@@ -89,7 +89,7 @@ final class Utils {
}
}
public static Type getParameterUpperBound(int index, ParameterizedType type) {
static Type getParameterUpperBound(int index, ParameterizedType type) {
Type[] types = type.getActualTypeArguments();
if (types.length <= index) {
throw new IllegalArgumentException(
......@@ -102,7 +102,7 @@ final class Utils {
return paramType;
}
public static boolean hasUnresolvableType(Type type) {
static boolean hasUnresolvableType(Type type) {
if (type instanceof Class<?>) {
return false;
}
......@@ -130,7 +130,7 @@ final class Utils {
}
// This method is copyright 2008 Google Inc. and is taken from Gson under the Apache 2.0 license.
public static Class<?> getRawType(Type type) {
static Class<?> getRawType(Type type) {
if (type instanceof Class<?>) {
// Type is a normal class.
return (Class<?>) type;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册