-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added missed API visibility annotations for public APIs and enable th…
…e check at the build time (#12872) * Added missed API visibility annotations for public APIs and enable the check at the build time Signed-off-by: Andriy Redko <[email protected]> * Address code review comments Signed-off-by: Andriy Redko <[email protected]> --------- Signed-off-by: Andriy Redko <[email protected]> (cherry picked from commit 8e332b6)
- Loading branch information
Showing
61 changed files
with
203 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
import org.opensearch.common.inject.binder.AnnotatedBindingBuilder; | ||
import org.opensearch.common.inject.binder.AnnotatedConstantBindingBuilder; | ||
import org.opensearch.common.inject.binder.LinkedBindingBuilder; | ||
|
@@ -198,8 +199,9 @@ | |
* @author [email protected] (Jesse Wilson) | ||
* @author [email protected] (Kevin Bourrillion) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface Binder { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
import org.opensearch.common.inject.spi.BindingScopingVisitor; | ||
import org.opensearch.common.inject.spi.BindingTargetVisitor; | ||
import org.opensearch.common.inject.spi.Element; | ||
|
@@ -69,8 +70,9 @@ | |
* @author [email protected] (Bob Lee) | ||
* @author [email protected] (Jesse Wilson) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface Binding<T> extends Element { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
import org.opensearch.common.inject.internal.Errors; | ||
import org.opensearch.common.inject.spi.Message; | ||
|
||
|
@@ -46,8 +47,9 @@ | |
* @author [email protected] (Jesse Wilson) | ||
* @since 2.0 | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public final class ConfigurationException extends RuntimeException { | ||
private final Set<Message> messages; | ||
private Object partialValue = null; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,8 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
|
@@ -54,8 +56,9 @@ | |
* @author [email protected] (Bob Lee) | ||
* @author [email protected] (Jesse Wilson) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface Injector { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
import org.opensearch.common.inject.internal.Annotations; | ||
import org.opensearch.common.inject.internal.MoreTypes; | ||
import org.opensearch.common.inject.internal.ToStringBuilder; | ||
|
@@ -59,8 +60,9 @@ | |
* | ||
* @author [email protected] (Bob Lee) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public class Key<T> { | ||
|
||
private final AnnotationStrategy annotationStrategy; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,8 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
/** | ||
* Injects dependencies into the fields and methods on instances of type {@code T}. Ignores the | ||
* presence or absence of an injectable constructor. | ||
|
@@ -38,8 +40,9 @@ | |
* @author [email protected] (Jesse Wilson) | ||
* @since 2.0 | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface MembersInjector<T> { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
import org.opensearch.common.inject.binder.AnnotatedElementBuilder; | ||
|
||
/** | ||
|
@@ -38,8 +39,9 @@ | |
* @author [email protected] (Jesse Wilson) | ||
* @since 2.0 | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface PrivateBinder extends Binder { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,8 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
/** | ||
* An object capable of providing instances of type {@code T}. Providers are used in numerous ways | ||
* by Guice: | ||
|
@@ -50,8 +52,9 @@ | |
* @param <T> the type of object this provides | ||
* @author [email protected] (Bob Lee) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface Provider<T> { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,8 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
/** | ||
* A scope is a level of visibility that instances provided by Guice may have. | ||
* By default, an instance created by the {@link Injector} has <i>no scope</i>, | ||
|
@@ -42,8 +44,9 @@ | |
* | ||
* @author [email protected] (Bob Lee) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface Scope { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,13 +29,16 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
/** | ||
* The stage we're running in. | ||
* | ||
* @author [email protected] (Bob Lee) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public enum Stage { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
|
||
package org.opensearch.common.inject; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
import org.opensearch.common.inject.internal.MoreTypes; | ||
import org.opensearch.common.inject.util.Types; | ||
|
||
|
@@ -77,8 +78,9 @@ | |
* @author [email protected] (Bob Lee) | ||
* @author [email protected] (Jesse Wilson) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public class TypeLiteral<T> { | ||
|
||
final Class<? super T> rawType; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,15 +29,18 @@ | |
|
||
package org.opensearch.common.inject.binder; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
import java.lang.annotation.Annotation; | ||
|
||
/** | ||
* See the EDSL examples at {@link org.opensearch.common.inject.Binder}. | ||
* | ||
* @author [email protected] (Bob Lee) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface AnnotatedBindingBuilder<T> extends LinkedBindingBuilder<T> { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,15 +29,18 @@ | |
|
||
package org.opensearch.common.inject.binder; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
import java.lang.annotation.Annotation; | ||
|
||
/** | ||
* See the EDSL examples at {@link org.opensearch.common.inject.Binder}. | ||
* | ||
* @author [email protected] (Bob Lee) | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface AnnotatedConstantBindingBuilder { | ||
|
||
/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,8 @@ | |
|
||
package org.opensearch.common.inject.binder; | ||
|
||
import org.opensearch.common.annotation.PublicApi; | ||
|
||
import java.lang.annotation.Annotation; | ||
|
||
/** | ||
|
@@ -37,8 +39,9 @@ | |
* @author [email protected] (Jesse Wilson) | ||
* @since 2.0 | ||
* | ||
* @opensearch.internal | ||
* @opensearch.api | ||
*/ | ||
@PublicApi(since = "1.0.0") | ||
public interface AnnotatedElementBuilder { | ||
|
||
/** | ||
|
Oops, something went wrong.