[guice] Add missing @since tags for classes (#916)

3 views
Skip to first unread message

Ben McCann

unread,
Apr 21, 2015, 7:21:55 PM4/21/15
to google/guice

You can view, comment on, or merge this pull request online at:

  https://github.com/google/guice/pull/916

Commit Summary

  • Add missing @since tags for classes

File Changes

Patch Links:


Reply to this email directly or view it on GitHub.

Sam Berlin

unread,
Apr 21, 2015, 7:23:25 PM4/21/15
to google/guice

In extensions/multibindings/src/com/google/inject/multibindings/ProvidesIntoOptional.java:

> @@ -50,6 +50,9 @@
>  @Target(METHOD)
>  @Retention(RUNTIME)
>  public @interface ProvidesIntoOptional {
> +  /**
> +   * @since 4.0

This should be on the top-level type instead I think?

Sam Berlin

unread,
Apr 21, 2015, 7:25:22 PM4/21/15
to google/guice

In extensions/multibindings/src/com/google/inject/multibindings/ProvidesIntoOptional.java:

> @@ -50,6 +50,9 @@
>  @Target(METHOD)
>  @Retention(RUNTIME)
>  public @interface ProvidesIntoOptional {
> +  /**
> +   * @since 4.0

Oh nevermind it's already there -- we can kill this one I think since it's an inner class on a brand new type.

Sam Berlin

unread,
Apr 21, 2015, 7:26:04 PM4/21/15
to google/guice

In core/src/com/google/inject/spi/ProvisionListener.java:

> @@ -49,7 +49,11 @@
>     */
>    <T> void onProvision(ProvisionInvocation<T> provision);
>  
> -  /** Encapsulates a single act of provisioning.*/ 
> +  /**
> +   * Encapsulates a single act of provisioning.
> +   *
> +   * @since 4.0

can rm this too since it's in a newly introduced class.

Sam Berlin

unread,
Apr 21, 2015, 7:26:19 PM4/21/15
to google/guice

In extensions/grapher/src/com/google/inject/grapher/AbstractInjectorGrapher.java:

> @@ -39,7 +40,10 @@
>    private final NodeCreator nodeCreator;
>    private final EdgeCreator edgeCreator;
>  
> -  /** Parameters used to override default settings of the grapher. */
> +  /**
> +   * Parameters used to override default settings of the grapher.
> +   * @since 4.0

and this.

Ben McCann

unread,
Apr 21, 2015, 7:28:16 PM4/21/15
to google/guice

In extensions/multibindings/src/com/google/inject/multibindings/ProvidesIntoOptional.java:

> @@ -50,6 +50,9 @@
>  @Target(METHOD)
>  @Retention(RUNTIME)
>  public @interface ProvidesIntoOptional {
> +  /**
> +   * @since 4.0

The reason I added them was because they're included in the report that ant jdiff spits out. I can remove them from the inner classes if you don't mind the report not having a clean output

Sam Berlin

unread,
Apr 21, 2015, 7:28:16 PM4/21/15
to google/guice

Thanks Ben! Will merge after rm'ing the inner class @sinces. Any chance you'll send a followup with missing @sinces in methods? :-)

Sam Berlin

unread,
Apr 21, 2015, 7:29:37 PM4/21/15
to google/guice

In extensions/multibindings/src/com/google/inject/multibindings/ProvidesIntoOptional.java:

> @@ -50,6 +50,9 @@
>  @Target(METHOD)
>  @Retention(RUNTIME)
>  public @interface ProvidesIntoOptional {
> +  /**
> +   * @since 4.0

Ahh, hmm. If jdiff wants it, I guess it's no big deal to keep them.

Sam Berlin

unread,
Apr 21, 2015, 7:30:15 PM4/21/15
to google/guice

Will merge once travis gives the green light (don't see any reason it wouldn't... but stranger things have happened).

James Roper

unread,
Apr 21, 2015, 8:35:13 PM4/21/15
to google/guice

Travis has been behaving very oddly on my projects today... don't get your hopes up :)

Ben McCann

unread,
Apr 21, 2015, 9:52:35 PM4/21/15
to google/guice

In extensions/grapher/src/com/google/inject/grapher/BindingEdge.java:

> @@ -22,6 +22,7 @@
>   * Edge that connects an interface to the type or instance that is bound to implement it.
>   *
>   * @author phop...@gmail.com (Pete Hopkins)
> + * @since 4.0
>   */
>  public class BindingEdge extends Edge {

@sameb looks like this class was in 3.0, but was previously parameterized. i'll remove the since tag on it if that makes sense to you

Sam Berlin

unread,
Apr 21, 2015, 9:57:59 PM4/21/15
to google/guice

In extensions/grapher/src/com/google/inject/grapher/BindingEdge.java:

> @@ -22,6 +22,7 @@
>   * Edge that connects an interface to the type or instance that is bound to implement it.
>   *
>   * @author phop...@gmail.com (Pete Hopkins)
> + * @since 4.0
>   */
>  public class BindingEdge extends Edge {

removing SGTM

Ben McCann

unread,
Apr 21, 2015, 10:03:46 PM4/21/15
to google/guice

I double checked all the places I added a since tag against the 3.0 javadoc. I ended up removing a few of them: BindingEdge, DependencyEdge, ImplementationNode, and InterfaceNode were in 3.0, but were previously paramaterized. I guess removing the type parameter made them show up in jdiff. I'm not sure what the deal was with the ElementVisitor ones. jdiff bug I guess. Everything else looked legit.

I think we should be good now as soon as Travis successfully completes

Sam Berlin

unread,
Apr 21, 2015, 10:12:59 PM4/21/15
to google/guice

Thanks again Ben.

Ben McCann

unread,
Apr 22, 2015, 12:30:37 AM4/22/15
to google/guice

Hmm. Travis has been running for a few hours and still hasn't returned...

@sameb no problem. happy to help!

btw, jroper and I are both maintainers for Play Framework and we have a big release coming up where one of the main highlights is better support for Guice and DI. hoping to get guice 4 in if we can. you think it might be released in the next week or two?

Sam Berlin

unread,
Apr 22, 2015, 7:16:19 AM4/22/15
to google/guice

Merged #916.

Reply all
Reply to author
Forward
0 new messages