libjsr305-java-0.1~+svn49.orig/0000700000000000000000000000000011433313255012776 5ustar libjsr305-java-0.1~+svn49.orig/Readme.rtf0000600000000000000000000000071110572635662014725 0ustar {\rtf1\mac\ansicpg10000\cocoartf824\cocoasubrtf420 {\fonttbl\f0\fswiss\fcharset77 Helvetica;} {\colortbl;\red255\green255\blue255;} \margl1440\margr1440\vieww9000\viewh8400\viewkind0 \pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural\pardirnatural \f0\fs24 \cf0 After installing maven, do the update and at the main directory, run either\ \ * mvn eclipse:clean eclipse:eclipse\ * mvn idea:idea\ \ }libjsr305-java-0.1~+svn49.orig/.project0000600000000000000000000000031511017027711014443 0ustar jsr305-trunk libjsr305-java-0.1~+svn49.orig/ri/0000700000000000000000000000000011433313255013410 5ustar libjsr305-java-0.1~+svn49.orig/ri/.project0000600000000000000000000000056010634301623015060 0ustar JSR305-ri org.eclipse.jdt.core.javabuilder org.eclipse.jdt.core.javanature libjsr305-java-0.1~+svn49.orig/ri/build/0000700000000000000000000000000011433313255014507 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/0000700000000000000000000000000011433313255014177 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/0000700000000000000000000000000011433313255015123 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/resources/0000700000000000000000000000000011433313255017135 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/java/0000700000000000000000000000000011433313255016044 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/0000700000000000000000000000000011433313255017155 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/0000700000000000000000000000000011433313255021327 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/RegEx.java0000600000000000000000000000205011054435071023203 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.util.regex.Pattern; import java.util.regex.PatternSyntaxException; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.TypeQualifierValidator; import javax.annotation.meta.When; /** * This qualifier is used to denote String values that should be a Regular * expression. * */ @Documented @Syntax("RegEx") @TypeQualifierNickname @Retention(RetentionPolicy.RUNTIME) public @interface RegEx { When when() default When.ALWAYS; static class Checker implements TypeQualifierValidator { public When forConstantValue(RegEx annotation, Object value) { if (!(value instanceof String)) return When.NEVER; try { Pattern.compile((String) value); } catch (PatternSyntaxException e) { return When.NEVER; } return When.ALWAYS; } } } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Tainted.java0000600000000000000000000000056411054435071023571 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; @Documented @TypeQualifierNickname @Untainted(when = When.MAYBE) @Retention(RetentionPolicy.RUNTIME) public @interface Tainted { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Nonnull.java0000600000000000000000000000130211054435071023615 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.TypeQualifierValidator; import javax.annotation.meta.When; @Documented @TypeQualifier @Retention(RetentionPolicy.RUNTIME) public @interface Nonnull { When when() default When.ALWAYS; static class Checker implements TypeQualifierValidator { public When forConstantValue(Nonnull qualifierqualifierArgument, Object value) { if (value == null) return When.NEVER; return When.ALWAYS; } } } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/CheckForSigned.java0000600000000000000000000000127211054436016025014 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; /** * Used to annotate a value that may be either negative or nonnegative, and * indicates that uses of it should check for * negative values before using it in a way that requires the value to be * nonnegative, and check for it being nonnegative before using it in a way that * requires it to be negative. */ @Documented @TypeQualifierNickname @Nonnegative(when = When.MAYBE) @Retention(RetentionPolicy.RUNTIME) public @interface CheckForSigned { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Signed.java0000600000000000000000000000065011054435071023406 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; /** Used to annotate a value of unknown sign */ @Documented @TypeQualifierNickname @Nonnegative(when = When.UNKNOWN) @Retention(RetentionPolicy.RUNTIME) public @interface Signed { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Untainted.java0000600000000000000000000000055411054435071024133 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.When; @Documented @TypeQualifier @Retention(RetentionPolicy.RUNTIME) public @interface Untainted { When when() default When.ALWAYS; } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/ParametersAreNonnullByDefault.java0000600000000000000000000000154211054435071030077 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierDefault; /** * This annotation can be applied to a package, class or method to indicate that * the method parameters in that element are nonnull by default unless there is: * * */ @Documented @Nonnull @TypeQualifierDefault(ElementType.PARAMETER) @Retention(RetentionPolicy.RUNTIME) public @interface ParametersAreNonnullByDefault { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/WillCloseWhenClosed.java0000600000000000000000000000060111054435071026042 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; @Documented @Retention(RetentionPolicy.RUNTIME) /** * Used to annotate a constructor/factory parameter to indicate that returned * object (X) will close the resource when X is closed. */ public @interface WillCloseWhenClosed { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Detainted.java0000600000000000000000000000056711054435071024105 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; @Documented @TypeQualifierNickname @Untainted(when = When.ALWAYS) @Retention(RetentionPolicy.RUNTIME) public @interface Detainted { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/0000700000000000000000000000000011433313255022255 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/TypeQualifierNickname.java0000600000000000000000000000146611054435071027362 0ustar package javax.annotation.meta; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Target; /** * * This annotation is applied to a annotation, and marks the annotation as being * a qualifier nickname. Applying a nickname annotation X to a element Y should * be interpreted as having the same meaning as applying all of annotations of X * (other than QualifierNickname) to Y. * *

* Thus, you might define a qualifier SocialSecurityNumber as follows: *

* * * @Documented @TypeQualifierNickname @Pattern("[0-9]{3}-[0-9]{2}-[0-9]{4}") @Retention(RetentionPolicy.RUNTIME) public @interface SocialSecurityNumber { } * * */ @Documented @Target(ElementType.ANNOTATION_TYPE) public @interface TypeQualifierNickname { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/TypeQualifier.java0000600000000000000000000000143411054435071025707 0ustar package javax.annotation.meta; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * This qualifier is applied to an annotation to denote that the annotation * should be treated as a type qualifier. */ @Documented @Target(ElementType.ANNOTATION_TYPE) @Retention(RetentionPolicy.RUNTIME) public @interface TypeQualifier { /** * Describes the kinds of values the qualifier can be applied to. If a * numeric class is provided (e.g., Number.class or Integer.class) then the * annotation can also be applied to the corresponding primitive numeric * types. */ Class applicableTo() default Object.class; } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/TypeQualifierValidator.java0000600000000000000000000000125711054435071027560 0ustar package javax.annotation.meta; import java.lang.annotation.Annotation; import javax.annotation.Nonnull; public interface TypeQualifierValidator { /** * Given a type qualifier, check to see if a known specific constant value * is an instance of the set of values denoted by the qualifier. * * @param annotation * the type qualifier * @param value * the value to check * @return a value indicating whether or not the value is an member of the * values denoted by the type qualifier */ public @Nonnull When forConstantValue(@Nonnull A annotation, Object value); } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/TypeQualifierDefault.java0000600000000000000000000000111611054435071027211 0ustar package javax.annotation.meta; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * This qualifier is applied to an annotation to denote that the annotation * defines a default type qualifier that is visible within the scope of the * element it is applied to. */ @Documented @Target(ElementType.ANNOTATION_TYPE) @Retention(RetentionPolicy.RUNTIME) public @interface TypeQualifierDefault { ElementType[] value() default {}; } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/Exhaustive.java0000600000000000000000000000211111054435071025242 0ustar package javax.annotation.meta; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; /** * This annotation can be applied to the value() element of an annotation that * is annotated as a TypeQualifier. This is only appropriate if the value field * returns a value that is an Enumeration. * * Applications of the type qualifier with different values are exclusive, and * the enumeration is an exhaustive list of the possible values. * * For example, the following defines a type qualifier such that if you know a * value is neither {@literal @Foo(Color.Red)} or {@literal @Foo(Color.Blue)}, * then the value must be {@literal @Foo(Color.Green)}. And if you know it is * {@literal @Foo(Color.Green)}, you know it cannot be * {@literal @Foo(Color.Red)} or {@literal @Foo(Color.Blue)} * * * @TypeQualifier @interface Foo { * enum Color {RED, BLUE, GREEN}; * @Exhaustive Color value(); * } * */ @Documented @Retention(RetentionPolicy.RUNTIME) public @interface Exhaustive { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/Exclusive.java0000600000000000000000000000121211054435071025065 0ustar package javax.annotation.meta; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; /** * This annotation can be applied to the value() element of an annotation that * is annotated as a TypeQualifier. * * For example, the following defines a type qualifier such that if you know a * value is {@literal @Foo(1)}, then the value cannot be {@literal @Foo(2)} or {{@literal @Foo(3)}. * * * @TypeQualifier @interface Foo { * @Exclusive int value(); * } * * */ @Documented @Retention(RetentionPolicy.RUNTIME) public @interface Exclusive { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/meta/When.java0000600000000000000000000000117711054435071024031 0ustar package javax.annotation.meta; /** * Used to describe the relationship between a qualifier T and the set of values * S possible on an annotated element. * * In particular, an issues should be reported if an ALWAYS or MAYBE value is * used where a NEVER value is required, or if a NEVER or MAYBE value is used * where an ALWAYS value is required. * * */ public enum When { /** S is a subset of T */ ALWAYS, /** nothing definitive is known about the relation between S and T */ UNKNOWN, /** S intersection T is non empty and S - T is nonempty */ MAYBE, /** S intersection T is empty */ NEVER; } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/concurrent/0000700000000000000000000000000011433313255023511 5ustar libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/concurrent/NotThreadSafe.java0000600000000000000000000000157411054435071027054 0ustar package javax.annotation.concurrent; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /* * Copyright (c) 2005 Brian Goetz * Released under the Creative Commons Attribution License * (http://creativecommons.org/licenses/by/2.5) * Official home: http://www.jcip.net */ /** * NotThreadSafe * * The class to which this annotation is applied is not thread-safe. This * annotation primarily exists for clarifying the non-thread-safety of a class * that might otherwise be assumed to be thread-safe, despite the fact that it * is a bad idea to assume a class is thread-safe without good reason. * * @see ThreadSafe */ @Documented @Target(ElementType.TYPE) @Retention(RetentionPolicy.CLASS) public @interface NotThreadSafe { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/concurrent/Immutable.java0000600000000000000000000000246511054435071026304 0ustar package javax.annotation.concurrent; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /* * Copyright (c) 2005 Brian Goetz * Released under the Creative Commons Attribution License * (http://creativecommons.org/licenses/by/2.5) * Official home: http://www.jcip.net */ /** * Immutable * * The class to which this annotation is applied is immutable. This means that * its state cannot be seen to change by callers. Of necessity this means that * all public fields are final, and that all public final reference fields refer * to other immutable objects, and that methods do not publish references to any * internal state which is mutable by implementation even if not by design. * Immutable objects may still have internal mutable state for purposes of * performance optimization; some state variables may be lazily computed, so * long as they are computed from immutable state and that callers cannot tell * the difference. * * Immutable objects are inherently thread-safe; they may be passed between * threads or published without synchronization. */ @Documented @Target(ElementType.TYPE) @Retention(RetentionPolicy.CLASS) public @interface Immutable { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/concurrent/ThreadSafe.java0000600000000000000000000000136011054435071026364 0ustar package javax.annotation.concurrent; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * ThreadSafe * * The class to which this annotation is applied is thread-safe. This means that * no sequences of accesses (reads and writes to public fields, calls to public * methods) may put the object into an invalid state, regardless of the * interleaving of those actions by the runtime, and without requiring any * additional synchronization or coordination on the part of the caller. */ @Documented @Target(ElementType.TYPE) @Retention(RetentionPolicy.CLASS) public @interface ThreadSafe { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/concurrent/GuardedBy.java0000600000000000000000000000311311054435071026222 0ustar package javax.annotation.concurrent; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /* * Copyright (c) 2005 Brian Goetz * Released under the Creative Commons Attribution License * (http://creativecommons.org/licenses/by/2.5) * Official home: http://www.jcip.net */ /** * GuardedBy * * The field or method to which this annotation is applied can only be accessed * when holding a particular lock, which may be a built-in (synchronization) * lock, or may be an explicit java.util.concurrent.Lock. * * The argument determines which lock guards the annotated field or method: this : * The string literal "this" means that this field is guarded by the class in * which it is defined. class-name.this : For inner classes, it may be necessary * to disambiguate 'this'; the class-name.this designation allows you to specify * which 'this' reference is intended itself : For reference fields only; the * object to which the field refers. field-name : The lock object is referenced * by the (instance or static) field specified by field-name. * class-name.field-name : The lock object is reference by the static field * specified by class-name.field-name. method-name() : The lock object is * returned by calling the named nil-ary method. class-name.class : The Class * object for the specified class should be used as the lock object. */ @Target( { ElementType.FIELD, ElementType.METHOD }) @Retention(RetentionPolicy.CLASS) public @interface GuardedBy { String value(); } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/MatchesPattern.java0000600000000000000000000000156311054435071025123 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.util.regex.Pattern; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.TypeQualifierValidator; import javax.annotation.meta.When; @Documented @TypeQualifier(applicableTo = String.class) @Retention(RetentionPolicy.RUNTIME) public @interface MatchesPattern { @RegEx String value(); int flags() default 0; static class Checker implements TypeQualifierValidator { public When forConstantValue(MatchesPattern annotation, Object value) { Pattern p = Pattern.compile(annotation.value(), annotation.flags()); if (p.matcher(((String) value)).matches()) return When.ALWAYS; return When.NEVER; } } } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Syntax.java0000600000000000000000000000257611054435071023474 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.When; /** * This annotation a value that is of a particular syntax, such as Java syntax * or regular expression syntax. This can be used to provide syntax checking of * constant values at compile time, run time checking at runtime, and can assist * IDEs in deciding how to interpret String constants (e.g., should a * refactoring that renames method x() to y() update the String constant "x()"). * * */ @Documented @TypeQualifier(applicableTo = String.class) @Retention(RetentionPolicy.RUNTIME) public @interface Syntax { /** * Value indicating the particular syntax denoted by this annotation. * Different tools will recognize different syntaxes, but some proposed * canonical values are: *
    *
  • "Java" *
  • "RegEx" *
  • "JavaScript" *
  • "Ruby" *
  • "Groovy" *
  • "SQL" *
  • "FormatString" *
* * Syntax names can be followed by a colon and a list of key value pairs, * separated by commas. For example, "SQL:dialect=Oracle,version=2.3". Tools * should ignore any keys they don't recognize. */ String value(); When when() default When.ALWAYS; } ././@LongLink0000000000000000000000000000014700000000000011567 Lustar rootrootlibjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/OverridingMethodsMustInvokeSuper.javalibjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/OverridingMethodsMustInvokeSuper.ja0000600000000000000000000000110411054435071030341 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * When this annotation is applied to a method, it indicates that if this method * is overridden in a subclass, the overriding method should invoke this method * (through method invocation on super). * */ @Documented @Target( { ElementType.METHOD }) @Retention(RetentionPolicy.RUNTIME) public @interface OverridingMethodsMustInvokeSuper { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/CheckReturnValue.java0000600000000000000000000000075611054435071025416 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import javax.annotation.meta.When; @Documented @Target( { ElementType.METHOD, ElementType.CONSTRUCTOR, ElementType.TYPE, ElementType.PACKAGE }) @Retention(RetentionPolicy.RUNTIME) public @interface CheckReturnValue { When when() default When.ALWAYS; } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Nullable.java0000600000000000000000000000056511054435071023740 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; @Documented @TypeQualifierNickname @Nonnull(when = When.UNKNOWN) @Retention(RetentionPolicy.RUNTIME) public @interface Nullable { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/PropertyKey.java0000600000000000000000000000055611054435071024477 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.When; @Documented @TypeQualifier @Retention(RetentionPolicy.RUNTIME) public @interface PropertyKey { When when() default When.ALWAYS; } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/CheckForNull.java0000600000000000000000000000056711054435071024523 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; @Documented @TypeQualifierNickname @Nonnull(when = When.MAYBE) @Retention(RetentionPolicy.RUNTIME) public @interface CheckForNull { } ././@LongLink0000000000000000000000000000014500000000000011565 Lustar rootrootlibjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/ParametersAreNullableByDefault.javalibjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/ParametersAreNullableByDefault.java0000600000000000000000000000211011126543030030173 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierDefault; /** * This annotation can be applied to a package, class or method to indicate that * the method parameters in that element are nullable by default unless there is: *
    *
  • An explicit nullness annotation *
  • The method overrides a method in a superclass (in which case the * annotation of the corresponding parameter in the superclass applies) *
  • there is a default parameter annotation applied to a more tightly nested * element. *
*

This annotation implies the same "nullness" as no annotation. However, it is different * than having no annotation, as it is inherited and it can override a ParametersAreNonnullByDefault * annotation at an outer scope. * */ @Documented @Nullable @TypeQualifierDefault(ElementType.PARAMETER) @Retention(RetentionPolicy.RUNTIME) public @interface ParametersAreNullableByDefault { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/WillClose.java0000600000000000000000000000052111054442005024062 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; @Documented @Retention(RetentionPolicy.RUNTIME) /** * Used to annotate a method parameter to indicate that this method will close * the resource. */ public @interface WillClose { } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/Nonnegative.java0000600000000000000000000000242711054435071024456 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.TypeQualifierValidator; import javax.annotation.meta.When; /** Used to annotate a value that should only contain nonnegative values */ @Documented @TypeQualifier(applicableTo = Number.class) @Retention(RetentionPolicy.RUNTIME) public @interface Nonnegative { When when() default When.ALWAYS; class Checker implements TypeQualifierValidator { public When forConstantValue(Nonnegative annotation, Object v) { if (!(v instanceof Number)) return When.NEVER; boolean isNegative; Number value = (Number) v; if (value instanceof Long) isNegative = value.longValue() < 0; else if (value instanceof Double) isNegative = value.doubleValue() < 0; else if (value instanceof Float) isNegative = value.floatValue() < 0; else isNegative = value.intValue() < 0; if (isNegative) return When.NEVER; else return When.ALWAYS; } } } libjsr305-java-0.1~+svn49.orig/ri/src/main/java/javax/annotation/WillNotClose.java0000600000000000000000000000053011054435071024550 0ustar package javax.annotation; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; @Documented @Retention(RetentionPolicy.RUNTIME) /** * Used to annotate a method parameter to indicate that this method will not * close the resource. */ public @interface WillNotClose { } libjsr305-java-0.1~+svn49.orig/ri/nbproject/0000700000000000000000000000000011433313255015376 5ustar libjsr305-java-0.1~+svn49.orig/ri/nbproject/project.xml0000600000000000000000000000612311024516551017572 0ustar org.netbeans.modules.ant.freeform JSR305-ri JSR305-ri java src/main/java UTF-8 java src/main/resources UTF-8 . UTF-8 build clean clean build folder build build src/main/java src/main/resources build.xml src/main/java src/main/resources build 1.5 libjsr305-java-0.1~+svn49.orig/ri/pom.xml0000600000000000000000000000121511017024475014727 0ustar 4.0.0 org.jsr-305 jsr-305 0.1-SNAPSHOT org.jsr-305 ri jar JSR 305 Implementation 0.1-SNAPSHOT Implementation for JSR-305 libjsr305-java-0.1~+svn49.orig/ri/LICENSE0000600000000000000000000000310211126543030014406 0ustar Copyright (c) 2007-2009, JSR305 expert group All rights reserved. http://www.opensource.org/licenses/bsd-license.php Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the JSR305 expert group nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. libjsr305-java-0.1~+svn49.orig/ri/.settings/0000700000000000000000000000000011433313255015326 5ustar libjsr305-java-0.1~+svn49.orig/ri/.settings/org.eclipse.jdt.ui.prefs0000600000000000000000000000014610642264371022005 0ustar #Wed Jun 20 13:34:34 GMT-05:00 2007 eclipse.preferences.version=1 internal.default.compliance=default libjsr305-java-0.1~+svn49.orig/ri/.settings/org.eclipse.jdt.core.prefs0000600000000000000000000000115710642264371022323 0ustar #Wed Jun 20 13:34:34 GMT-05:00 2007 eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve org.eclipse.jdt.core.compiler.compliance=1.5 org.eclipse.jdt.core.compiler.debug.lineNumber=generate org.eclipse.jdt.core.compiler.debug.localVariable=generate org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error org.eclipse.jdt.core.compiler.source=1.5 libjsr305-java-0.1~+svn49.orig/ri/build.xml0000600000000000000000000000172011136142021015222 0ustar libjsr305-java-0.1~+svn49.orig/ri/.classpath0000600000000000000000000000036610634301623015400 0ustar libjsr305-java-0.1~+svn49.orig/tcl/0000700000000000000000000000000011433313252013555 5ustar libjsr305-java-0.1~+svn49.orig/tcl/src/0000700000000000000000000000000011433313251014343 5ustar libjsr305-java-0.1~+svn49.orig/tcl/src/main/0000700000000000000000000000000011433313252015270 5ustar libjsr305-java-0.1~+svn49.orig/tcl/src/main/resources/0000700000000000000000000000000011433313252017302 5ustar libjsr305-java-0.1~+svn49.orig/tcl/src/main/java/0000700000000000000000000000000011433313252016211 5ustar libjsr305-java-0.1~+svn49.orig/tcl/pom.xml0000600000000000000000000000150011017024475015074 0ustar 4.0.0 org.jsr-305 jsr-305 0.1-SNAPSHOT org.jsr-305 tcl jar JSR 305 Test Cases 0.1-SNAPSHOT Test Cases for JSR-305 Implementations org.jsr-305 ri 0.1-SNAPSHOT libjsr305-java-0.1~+svn49.orig/tcl/test/0000700000000000000000000000000011433313251014533 5ustar libjsr305-java-0.1~+svn49.orig/tcl/test/java/0000700000000000000000000000000011433313251015454 5ustar libjsr305-java-0.1~+svn49.orig/pom.xml0000600000000000000000000000203510572634645014331 0ustar 4.0.0 org.jsr-305 jsr-305 0.1-SNAPSHOT http://code.google.com/p/jsr-305/ pom JSR 305: Annotations for Software Defect Detection in Java Master Maven project for all JSR 305 projects ri tcl sampleUses proposedAnnotations org.apache.maven.plugins maven-compiler-plugin 1.5 1.5 libjsr305-java-0.1~+svn49.orig/proposedAnnotations/0000700000000000000000000000000011433313255017047 5ustar libjsr305-java-0.1~+svn49.orig/proposedAnnotations/src/0000700000000000000000000000000011433313255017636 5ustar libjsr305-java-0.1~+svn49.orig/proposedAnnotations/src/main/0000700000000000000000000000000011433313255020562 5ustar libjsr305-java-0.1~+svn49.orig/proposedAnnotations/src/main/resources/0000700000000000000000000000000011433313255022574 5ustar libjsr305-java-0.1~+svn49.orig/proposedAnnotations/src/main/java/0000700000000000000000000000000011433313255021503 5ustar libjsr305-java-0.1~+svn49.orig/proposedAnnotations/pom.xml0000600000000000000000000000124211017024475020366 0ustar 4.0.0 org.jsr-305 jsr-305 0.1-SNAPSHOT org.jsr-305 proposedAnnotations jar JSR 305 Proposed Annotations 0.1-SNAPSHOT Proposed Annotations for JSR-305 libjsr305-java-0.1~+svn49.orig/proposedAnnotations/test/0000700000000000000000000000000011433313255020026 5ustar libjsr305-java-0.1~+svn49.orig/proposedAnnotations/test/java/0000700000000000000000000000000011433313255020747 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/0000700000000000000000000000000011433313251015113 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/.project0000600000000000000000000000056210634772421016601 0ustar JSR305-uses org.eclipse.jdt.core.javabuilder org.eclipse.jdt.core.javanature libjsr305-java-0.1~+svn49.orig/sampleUses/src/0000700000000000000000000000000011433313251015702 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/0000700000000000000000000000000011433313251016626 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/resources/0000700000000000000000000000000011433313251020640 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/0000700000000000000000000000000011433313251017547 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/0000700000000000000000000000000011433313251020324 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/0000700000000000000000000000000011433313251021111 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/0000700000000000000000000000000011433313251021516 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/0000700000000000000000000000000011433313251023317 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/SlashedClassName.java0000600000000000000000000000062411015535022027336 0ustar package edu.umd.cs.findbugs; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.When; @Documented @TypeQualifier(applicableTo=CharSequence.class) @Retention(RetentionPolicy.RUNTIME) public @interface SlashedClassName { When when() default When.ALWAYS; } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/DottedClassName.java0000600000000000000000000000060211015535022027172 0ustar package edu.umd.cs.findbugs; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifierNickname; import javax.annotation.meta.When; @Documented @SlashedClassName(when=When.NEVER) @TypeQualifierNickname @Retention(RetentionPolicy.RUNTIME) public @interface DottedClassName { }libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/examples/0000700000000000000000000000000011433313251025135 5ustar ././@LongLink0000000000000000000000000000014700000000000011567 Lustar rootrootlibjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/examples/TestDefaults.javalibjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/examples/TestDefaults.ja0000600000000000000000000000061711015547616030100 0ustar package edu.umd.cs.findbugs.examples; import javax.annotation.meta.When; import edu.umd.cs.findbugs.DottedClassName; import edu.umd.cs.findbugs.SlashedClassName; @ParametersAreSlashedByDefault public class TestDefaults { public void foo(String c) {} public void foo2(@DottedClassName String c) { foo(c); } public void foo3(@SlashedClassName(when=When.UNKNOWN) String c) { foo(c); } } ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootlibjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/examples/ParametersAreSlashedByDefault.javalibjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/examples/ParametersAreSl0000600000000000000000000000044711015547616030133 0ustar package edu.umd.cs.findbugs.examples; import java.lang.annotation.ElementType; import javax.annotation.meta.TypeQualifierDefault; import edu.umd.cs.findbugs.SlashedClassName; @SlashedClassName @TypeQualifierDefault(ElementType.PARAMETER) public @interface ParametersAreSlashedByDefault { } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/edu/umd/cs/findbugs/examples/Test.java0000600000000000000000000000115411015535022026720 0ustar package edu.umd.cs.findbugs.examples; import javax.annotation.meta.When; import edu.umd.cs.findbugs.DottedClassName; import edu.umd.cs.findbugs.SlashedClassName; public class Test { public void foo(@SlashedClassName String foo) {} public void foo2(@DottedClassName String foo) { foo(foo); // should get warning here } public void foo3(String foo) { foo(foo); } public void foo4(@DottedClassName String foo) { foo3(foo); } public void foo5(@SlashedClassName(when=When.MAYBE) String foo) { foo(foo); } public void foo6(@SlashedClassName(when=When.UNKNOWN) String foo) { foo(foo); } } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/CreditCardNumber.java0000600000000000000000000000142111017021406023563 0ustar import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.MatchesPattern; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.TypeQualifierValidator; import javax.annotation.meta.When; @Documented @TypeQualifier @MatchesPattern("[0-9]{16}") @Retention(RetentionPolicy.RUNTIME) public @interface CreditCardNumber { class Checker implements TypeQualifierValidator { public When forConstantValue(CreditCardNumber annotation, Object v) { if (!(v instanceof String)) return When.NEVER; String s = (String) v; if (LuhnVerification.checkNumber(s)) return When.ALWAYS; return When.NEVER; } } } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/FixedLengthString.java0000600000000000000000000000132010675747364024027 0ustar import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; import javax.annotation.meta.TypeQualifierValidator; import javax.annotation.meta.When; @Documented @TypeQualifier(applicableTo=String.class) @Retention(RetentionPolicy.RUNTIME) public @interface FixedLengthString { int value(); class Checker implements TypeQualifierValidator { public When forConstantValue(FixedLengthString annotation, Object v) { if (!(v instanceof String)) return When.NEVER; String s = (String) v; if (s.length() == annotation.value()) return When.ALWAYS; return When.NEVER; } } }libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/LuhnVerification.java0000600000000000000000000000100010634772421023666 0ustar public class LuhnVerification { static boolean checkNumber(String value) { int result = 0; boolean special = false; for (int i = value.length() - 1; i >= 0; i--) { int v = value.charAt(i) - '0'; if (v < 0 || v > 9) return false; if (special) { v = v * 2; if (v > 9) v = v - 10 + 1; } result += v; special = !special; } System.out.println(result); return result % 10 == 0; } public static void main(String args[]) { System.out.println(checkNumber("")); } } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/SocialSecurityNumber.java0000600000000000000000000000064311017021406024526 0ustar import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.MatchesPattern; import javax.annotation.meta.TypeQualifierNickname; @Documented @TypeQualifierNickname @MatchesPattern("[0-9]{3}-[0-9]{2}-[0-9]{4}") @Retention(RetentionPolicy.RUNTIME) public @interface SocialSecurityNumber { } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/java/0000700000000000000000000000000011433313251020470 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/java/sql/0000700000000000000000000000000011433313251021267 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/java/sql/ResultSetType.java0000600000000000000000000000047510675747364024765 0ustar package java.sql; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; @Documented @TypeQualifier(applicableTo=Integer.class) @Retention(RetentionPolicy.RUNTIME) public @interface ResultSetType { } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/java/sql/ResultSetConcurrency.java0000600000000000000000000000050410675747364026327 0ustar package java.sql; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; @Documented @TypeQualifier(applicableTo=Integer.class) @Retention(RetentionPolicy.RUNTIME) public @interface ResultSetConcurrency { } libjsr305-java-0.1~+svn49.orig/sampleUses/src/main/java/java/sql/ResultSetHoldability.java0000600000000000000000000000050410675747364026301 0ustar package java.sql; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import javax.annotation.meta.TypeQualifier; @Documented @TypeQualifier(applicableTo=Integer.class) @Retention(RetentionPolicy.RUNTIME) public @interface ResultSetHoldability { } libjsr305-java-0.1~+svn49.orig/sampleUses/pom.xml0000600000000000000000000000162411017027635016443 0ustar 4.0.0 org.jsr-305 jsr-305 0.1-SNAPSHOT org.jsr-305 sampleUses jar JSR 305 Sample Use Cases 0.1-SNAPSHOT Use Cases for JSR-305 org.jsr-305 ri 0.1-SNAPSHOT libjsr305-java-0.1~+svn49.orig/sampleUses/.settings/0000700000000000000000000000000011433313251017031 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/test/0000700000000000000000000000000011433313251016072 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/test/java/0000700000000000000000000000000011433313251017013 5ustar libjsr305-java-0.1~+svn49.orig/sampleUses/.classpath0000600000000000000000000000050110634772421017106 0ustar