You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jcs-dev@jakarta.apache.org by hc...@apache.org on 2005/01/22 22:33:51 UTC
cvs commit: jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate CopyRightApache.java CopyRightType.java TestOnly.java ThreadSafety.java ThreadSafetyType.java TODO.java UnsupportedOperation.java
hchar 2005/01/22 13:33:51
Added: sandbox/yajcache/src/org/apache/jcs/yajcache/annotate
CopyRightApache.java CopyRightType.java
TestOnly.java ThreadSafety.java
ThreadSafetyType.java TODO.java
UnsupportedOperation.java
Log:
move yajcache to sandbox
Revision Changes Path
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/CopyRightApache.java
Index: CopyRightApache.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
import java.lang.annotation.*;
/**
* Annotates the Apache Copyright.
*
* @author Hanson Char
*/
@CopyRightApache
@Documented
@Retention(RetentionPolicy.RUNTIME)
public @interface CopyRightApache {
CopyRightType value() default CopyRightType.APACHE;
}
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/CopyRightType.java
Index: CopyRightType.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
/**
* Copyright Types.
*
* @author Hanson Char
*/
@CopyRightApache
public enum CopyRightType {
APACHE {
@Override public String toString() {
return "\n"
+ "/* ========================================================================\n"
+ " * Copyright 2004 The Apache Software Foundation\n"
+ " *\n"
+ " * Licensed under the Apache License, Version 2.0 (the \"License\");\n"
+ " * you may not use this file except in compliance with the License.\n"
+ " * You may obtain a copy of the License at\n"
+ " *\n"
+ " * http://www.apache.org/licenses/LICENSE-2.0\n"
+ " *\n"
+ " * Unless required by applicable law or agreed to in writing, software\n"
+ " * distributed under the License is distributed on an \"AS IS\" BASIS,\n"
+ " * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n"
+ " * See the License for the specific language governing permissions and\n"
+ " * limitations under the License.\n"
+ " * ========================================================================\n"
+ " */\n"
;
}
};
}
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/TestOnly.java
Index: TestOnly.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
import java.lang.annotation.*;
/**
* Annotates the target is for testing purposes only.
*
* @author Hanson Char
*/
@CopyRightApache
@Documented
@Inherited
@Retention(RetentionPolicy.RUNTIME)
public @interface TestOnly {
String value() default "";
}
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/ThreadSafety.java
Index: ThreadSafety.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
import java.lang.annotation.*;
/**
* Characterizing thread safety.
*
* http://www-106.ibm.com/developerworks/java/library/j-jtp09263.html
*
* @author Hanson Char
*/
@CopyRightApache
@Documented
@Retention(RetentionPolicy.RUNTIME)
public @interface ThreadSafety {
ThreadSafetyType value();
String caveat() default "";
String note() default "";
}
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/ThreadSafetyType.java
Index: ThreadSafetyType.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
/**
* Thread Safety Types.
*
* http://www-106.ibm.com/developerworks/java/library/j-jtp09263.html
*
* @author Hanson Char
*/
@CopyRightApache
public enum ThreadSafetyType {
/** Immutable objects are guaranteed to be thread-safe. */
IMMUTABLE,
SAFE,
/**
* Conditionally thread-safe classes are those for which each individual
* operation may be thread-safe, but certain sequences of operations may
* require external synchronization. The most common example of
* conditional thread safety is traversing an iterator returned from
* Hashtable or Vector -- the fail-fast iterators returned by these
* classes assume that the underlying collection will not be mutated
* while the iterator traversal is in progress. To ensure that other
* threads will not mutate the collection during traversal, the
* iterating thread should be sure that it has exclusive access to
* the collection for the entirety of the traversal. Typically,
* exclusive access is ensured by synchronizing on a lock -- and the
* class's documentation should specify which lock that is
* (typically the object's intrinsic monitor).
*/
CONDITIONAL,
/**
* Thread-compatible classes are not thread-safe, but can be used
* safely in concurrent environments by using synchronization
* appropriately.
*/
COMPATIBLE,
/**
* Thread-hostile classes are those that cannot be rendered safe to
* use concurrently, regardless of what external synchronization is
* invoked.
*/
HOSTILE
}
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/TODO.java
Index: TODO.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
import java.lang.annotation.*;
/**
* Annotates what needs to be done.
*
* @author Hanson Char
*/
@CopyRightApache
@Documented
@Retention(RetentionPolicy.SOURCE)
public @interface TODO {
/** Summary of what needs to be done. */
String value() default "";
/** Details of what needs to be done. */
String details() default "";
}
1.1 jakarta-turbine-jcs/sandbox/yajcache/src/org/apache/jcs/yajcache/annotate/UnsupportedOperation.java
Index: UnsupportedOperation.java
===================================================================
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jcs.yajcache.annotate;
import java.lang.annotation.*;
/**
* Unsupported Operation.
*
* @author Hanson Char
*/
@CopyRightApache
@Documented
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface UnsupportedOperation {
String value() default "";
}
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-jcs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-jcs-dev-help@jakarta.apache.org