Made constructors package private for package private classes.

This commit is contained in:
Inderjeet Singh 2011-03-10 23:55:16 +00:00
parent 4e4f9b3a69
commit baf9591d3b
4 changed files with 4 additions and 4 deletions

View File

@ -27,7 +27,7 @@ import java.util.Collection;
final class DisjunctionExclusionStrategy implements ExclusionStrategy {
private final Collection<ExclusionStrategy> strategies;
public DisjunctionExclusionStrategy(Collection<ExclusionStrategy> strategies) {
DisjunctionExclusionStrategy(Collection<ExclusionStrategy> strategies) {
Preconditions.checkNotNull(strategies);
this.strategies = strategies;
}

View File

@ -464,7 +464,7 @@ public final class GsonBuilder {
*/
public GsonBuilder registerTypeHierarchyAdapter(Class<?> baseType, Object typeAdapter) {
Preconditions.checkArgument(typeAdapter instanceof JsonSerializer<?>
|| typeAdapter instanceof JsonDeserializer<?> || typeAdapter instanceof InstanceCreator<?>);
|| typeAdapter instanceof JsonDeserializer<?> || typeAdapter instanceof InstanceCreator<?>);
if (typeAdapter instanceof InstanceCreator<?>) {
registerInstanceCreatorForTypeHierarchy(baseType, (InstanceCreator<?>) typeAdapter);
}

View File

@ -62,7 +62,7 @@ final class ModifyFirstLetterNamingPolicy extends RecursiveFieldNamingPolicy {
* @param modifier the type of modification that should be performed
* @throws IllegalArgumentException if {@code modifier} is null
*/
public ModifyFirstLetterNamingPolicy(LetterModifier modifier) {
ModifyFirstLetterNamingPolicy(LetterModifier modifier) {
Preconditions.checkNotNull(modifier);
this.letterModifier = modifier;
}

View File

@ -28,7 +28,7 @@ import com.google.gson.annotations.Until;
final class VersionExclusionStrategy implements ExclusionStrategy {
private final double version;
public VersionExclusionStrategy(double version) {
VersionExclusionStrategy(double version) {
Preconditions.checkArgument(version >= 0.0D);
this.version = version;
}