diff options
author | Josh Haberman <jhaberman@gmail.com> | 2018-09-04 10:58:54 -0700 |
---|---|---|
committer | Josh Haberman <jhaberman@gmail.com> | 2018-09-04 10:58:54 -0700 |
commit | d61aede89cf188367766b971f59cf57d7835d8e8 (patch) | |
tree | a19842c62c3c8f51389912ecafdf932d0a572bea /java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java | |
parent | 45d03a977193d1dcce5251e4bffe17bf0ba738ec (diff) | |
download | protobuf-d61aede89cf188367766b971f59cf57d7835d8e8.tar.gz protobuf-d61aede89cf188367766b971f59cf57d7835d8e8.tar.bz2 protobuf-d61aede89cf188367766b971f59cf57d7835d8e8.zip |
Down-integrate from google3.
Diffstat (limited to 'java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java')
-rw-r--r-- | java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java b/java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java index 89f7ab9b..f070aae7 100644 --- a/java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java +++ b/java/core/src/main/java/com/google/protobuf/ExtensionRegistryFactory.java @@ -35,16 +35,15 @@ import static com.google.protobuf.ExtensionRegistryLite.EMPTY_REGISTRY_LITE; /** * A factory object to create instances of {@link ExtensionRegistryLite}. * - * <p> - * This factory detects (via reflection) if the full (non-Lite) protocol buffer libraries - * are available, and if so, the instances returned are actually {@link ExtensionRegistry}. + * <p>This factory detects (via reflection) if the full (non-Lite) protocol buffer libraries are + * available, and if so, the instances returned are actually {@link ExtensionRegistry}. */ final class ExtensionRegistryFactory { static final String FULL_REGISTRY_CLASS_NAME = "com.google.protobuf.ExtensionRegistry"; /* Visible for Testing - @Nullable */ + @Nullable */ static final Class<?> EXTENSION_REGISTRY_CLASS = reflectExtensionRegistry(); /* @Nullable */ @@ -90,7 +89,7 @@ final class ExtensionRegistryFactory { private static final ExtensionRegistryLite invokeSubclassFactory(String methodName) throws Exception { - return (ExtensionRegistryLite) EXTENSION_REGISTRY_CLASS - .getDeclaredMethod(methodName).invoke(null); + return (ExtensionRegistryLite) + EXTENSION_REGISTRY_CLASS.getDeclaredMethod(methodName).invoke(null); } } |