Annotation VisibleForTesting

  • All Implemented Interfaces:
    java.lang.annotation.Annotation

    @Target(value = {})@Retention(value = SOURCE)@Documented() 
    public @interface VisibleForTesting
    
                        

    The annotated entity should have more restricted visibility but needs to be visible for tests.

    This annotation is to be used on any class, method or property that needs package or public visibilty purely for testing purposes, and should only be used internally in production code. Technically, it has no effect on the code. There is no mechanism to enforce that the annotated entity is only used where it is intended to be used. It is purely a marker that the visibility of the annotated entity is chosen for testing purposes, and it should not be relied upon for API purposes.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      • Methods inherited from class java.lang.annotation.Annotation

        annotationType, equals, hashCode, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail