From: markt Date: Fri, 25 Apr 2008 22:55:38 +0000 (+0000) Subject: Fix bug https://issues.apache.org/bugzilla/show_bug.cgi?id=43425 X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=c646a0d984f956176fc698eddc595b2d95a68cdf;p=tomcat7.0 Fix bug https://issues.apache.org/bugzilla/show_bug.cgi?id=43425 Annotations not spec compliant. Patch provided by Dain Sundstrom. git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@651732 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/javax/annotation/security/DenyAll.java b/java/javax/annotation/security/DenyAll.java index c16550a9d..f54b92555 100644 --- a/java/javax/annotation/security/DenyAll.java +++ b/java/javax/annotation/security/DenyAll.java @@ -23,7 +23,7 @@ import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -@Target({ElementType.TYPE, ElementType.METHOD}) +@Target({ElementType.METHOD}) @Retention(RetentionPolicy.RUNTIME) public @interface DenyAll { diff --git a/java/javax/ejb/EJB.java b/java/javax/ejb/EJB.java index 99dcd7a95..1ea40a904 100644 --- a/java/javax/ejb/EJB.java +++ b/java/javax/ejb/EJB.java @@ -28,6 +28,7 @@ import java.lang.annotation.Target; public @interface EJB { String name() default ""; + String description() default ""; Class beanInterface() default java.lang.Object.class; String beanName() default ""; String mappedName() default ""; diff --git a/java/javax/persistence/PersistenceContext.java b/java/javax/persistence/PersistenceContext.java index 20b58d876..e8417e2c7 100644 --- a/java/javax/persistence/PersistenceContext.java +++ b/java/javax/persistence/PersistenceContext.java @@ -30,4 +30,5 @@ public @interface PersistenceContext { String name() default ""; String unitName() default ""; PersistenceContextType type() default PersistenceContextType.TRANSACTION; + PersistenceProperty[] properties() default {}; } diff --git a/java/javax/persistence/PersistenceProperty.java b/java/javax/persistence/PersistenceProperty.java new file mode 100644 index 000000000..372a870a4 --- /dev/null +++ b/java/javax/persistence/PersistenceProperty.java @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You 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 javax.persistence; + +import java.lang.annotation.Target; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; + +@Target({}) +@Retention(RetentionPolicy.RUNTIME) + +public @interface PersistenceProperty { + String name(); + String value(); +}