├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── pom.xml ├── release.sh └── src └── main ├── java └── javax │ └── annotation │ ├── Generated.java │ ├── ManagedBean.java │ ├── PostConstruct.java │ ├── PreDestroy.java │ ├── Priority.java │ ├── Resource.java │ ├── Resources.java │ ├── package.html │ ├── security │ ├── DeclareRoles.java │ ├── DenyAll.java │ ├── PermitAll.java │ ├── RolesAllowed.java │ ├── RunAs.java │ └── package.html │ └── sql │ ├── DataSourceDefinition.java │ └── DataSourceDefinitions.java └── javadoc └── doc-files └── speclicense.html /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | #### :warning:This project is now part of the EE4J initiative. This repository has been archived as all activities are now happening in the [corresponding Eclipse repository](https://github.com/eclipse-ee4j/common-annotations-api). See [here](https://www.eclipse.org/ee4j/status.php) for the overall EE4J transition status. 2 | 3 | --- 4 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.1 2 | 3 | 1. Definitions. 4 | 5 | 1.1. "Contributor" means each individual or entity that creates or 6 | contributes to the creation of Modifications. 7 | 8 | 1.2. "Contributor Version" means the combination of the Original 9 | Software, prior Modifications used by a Contributor (if any), and 10 | the Modifications made by that particular Contributor. 11 | 12 | 1.3. "Covered Software" means (a) the Original Software, or (b) 13 | Modifications, or (c) the combination of files containing Original 14 | Software with files containing Modifications, in each case including 15 | portions thereof. 16 | 17 | 1.4. "Executable" means the Covered Software in any form other than 18 | Source Code. 19 | 20 | 1.5. "Initial Developer" means the individual or entity that first 21 | makes Original Software available under this License. 22 | 23 | 1.6. "Larger Work" means a work which combines Covered Software or 24 | portions thereof with code not governed by the terms of this License. 25 | 26 | 1.7. "License" means this document. 27 | 28 | 1.8. "Licensable" means having the right to grant, to the maximum 29 | extent possible, whether at the time of the initial grant or 30 | subsequently acquired, any and all of the rights conveyed herein. 31 | 32 | 1.9. "Modifications" means the Source Code and Executable form of 33 | any of the following: 34 | 35 | A. Any file that results from an addition to, deletion from or 36 | modification of the contents of a file containing Original Software 37 | or previous Modifications; 38 | 39 | B. Any new file that contains any part of the Original Software or 40 | previous Modification; or 41 | 42 | C. Any new file that is contributed or otherwise made available 43 | under the terms of this License. 44 | 45 | 1.10. "Original Software" means the Source Code and Executable form 46 | of computer software code that is originally released under this 47 | License. 48 | 49 | 1.11. "Patent Claims" means any patent claim(s), now owned or 50 | hereafter acquired, including without limitation, method, process, 51 | and apparatus claims, in any patent Licensable by grantor. 52 | 53 | 1.12. "Source Code" means (a) the common form of computer software 54 | code in which modifications are made and (b) associated 55 | documentation included in or with such code. 56 | 57 | 1.13. "You" (or "Your") means an individual or a legal entity 58 | exercising rights under, and complying with all of the terms of, 59 | this License. For legal entities, "You" includes any entity which 60 | controls, is controlled by, or is under common control with You. For 61 | purposes of this definition, "control" means (a) the power, direct 62 | or indirect, to cause the direction or management of such entity, 63 | whether by contract or otherwise, or (b) ownership of more than 64 | fifty percent (50%) of the outstanding shares or beneficial 65 | ownership of such entity. 66 | 67 | 2. License Grants. 68 | 69 | 2.1. The Initial Developer Grant. 70 | 71 | Conditioned upon Your compliance with Section 3.1 below and subject 72 | to third party intellectual property claims, the Initial Developer 73 | hereby grants You a world-wide, royalty-free, non-exclusive license: 74 | 75 | (a) under intellectual property rights (other than patent or 76 | trademark) Licensable by Initial Developer, to use, reproduce, 77 | modify, display, perform, sublicense and distribute the Original 78 | Software (or portions thereof), with or without Modifications, 79 | and/or as part of a Larger Work; and 80 | 81 | (b) under Patent Claims infringed by the making, using or selling of 82 | Original Software, to make, have made, use, practice, sell, and 83 | offer for sale, and/or otherwise dispose of the Original Software 84 | (or portions thereof). 85 | 86 | (c) The licenses granted in Sections 2.1(a) and (b) are effective on 87 | the date Initial Developer first distributes or otherwise makes the 88 | Original Software available to a third party under the terms of this 89 | License. 90 | 91 | (d) Notwithstanding Section 2.1(b) above, no patent license is 92 | granted: (1) for code that You delete from the Original Software, or 93 | (2) for infringements caused by: (i) the modification of the 94 | Original Software, or (ii) the combination of the Original Software 95 | with other software or devices. 96 | 97 | 2.2. Contributor Grant. 98 | 99 | Conditioned upon Your compliance with Section 3.1 below and subject 100 | to third party intellectual property claims, each Contributor hereby 101 | grants You a world-wide, royalty-free, non-exclusive license: 102 | 103 | (a) under intellectual property rights (other than patent or 104 | trademark) Licensable by Contributor to use, reproduce, modify, 105 | display, perform, sublicense and distribute the Modifications 106 | created by such Contributor (or portions thereof), either on an 107 | unmodified basis, with other Modifications, as Covered Software 108 | and/or as part of a Larger Work; and 109 | 110 | (b) under Patent Claims infringed by the making, using, or selling 111 | of Modifications made by that Contributor either alone and/or in 112 | combination with its Contributor Version (or portions of such 113 | combination), to make, use, sell, offer for sale, have made, and/or 114 | otherwise dispose of: (1) Modifications made by that Contributor (or 115 | portions thereof); and (2) the combination of Modifications made by 116 | that Contributor with its Contributor Version (or portions of such 117 | combination). 118 | 119 | (c) The licenses granted in Sections 2.2(a) and 2.2(b) are effective 120 | on the date Contributor first distributes or otherwise makes the 121 | Modifications available to a third party. 122 | 123 | (d) Notwithstanding Section 2.2(b) above, no patent license is 124 | granted: (1) for any code that Contributor has deleted from the 125 | Contributor Version; (2) for infringements caused by: (i) third 126 | party modifications of Contributor Version, or (ii) the combination 127 | of Modifications made by that Contributor with other software 128 | (except as part of the Contributor Version) or other devices; or (3) 129 | under Patent Claims infringed by Covered Software in the absence of 130 | Modifications made by that Contributor. 131 | 132 | 3. Distribution Obligations. 133 | 134 | 3.1. Availability of Source Code. 135 | 136 | Any Covered Software that You distribute or otherwise make available 137 | in Executable form must also be made available in Source Code form 138 | and that Source Code form must be distributed only under the terms 139 | of this License. You must include a copy of this License with every 140 | copy of the Source Code form of the Covered Software You distribute 141 | or otherwise make available. You must inform recipients of any such 142 | Covered Software in Executable form as to how they can obtain such 143 | Covered Software in Source Code form in a reasonable manner on or 144 | through a medium customarily used for software exchange. 145 | 146 | 3.2. Modifications. 147 | 148 | The Modifications that You create or to which You contribute are 149 | governed by the terms of this License. You represent that You 150 | believe Your Modifications are Your original creation(s) and/or You 151 | have sufficient rights to grant the rights conveyed by this License. 152 | 153 | 3.3. Required Notices. 154 | 155 | You must include a notice in each of Your Modifications that 156 | identifies You as the Contributor of the Modification. You may not 157 | remove or alter any copyright, patent or trademark notices contained 158 | within the Covered Software, or any notices of licensing or any 159 | descriptive text giving attribution to any Contributor or the 160 | Initial Developer. 161 | 162 | 3.4. Application of Additional Terms. 163 | 164 | You may not offer or impose any terms on any Covered Software in 165 | Source Code form that alters or restricts the applicable version of 166 | this License or the recipients' rights hereunder. You may choose to 167 | offer, and to charge a fee for, warranty, support, indemnity or 168 | liability obligations to one or more recipients of Covered Software. 169 | However, you may do so only on Your own behalf, and not on behalf of 170 | the Initial Developer or any Contributor. You must make it 171 | absolutely clear that any such warranty, support, indemnity or 172 | liability obligation is offered by You alone, and You hereby agree 173 | to indemnify the Initial Developer and every Contributor for any 174 | liability incurred by the Initial Developer or such Contributor as a 175 | result of warranty, support, indemnity or liability terms You offer. 176 | 177 | 3.5. Distribution of Executable Versions. 178 | 179 | You may distribute the Executable form of the Covered Software under 180 | the terms of this License or under the terms of a license of Your 181 | choice, which may contain terms different from this License, 182 | provided that You are in compliance with the terms of this License 183 | and that the license for the Executable form does not attempt to 184 | limit or alter the recipient's rights in the Source Code form from 185 | the rights set forth in this License. If You distribute the Covered 186 | Software in Executable form under a different license, You must make 187 | it absolutely clear that any terms which differ from this License 188 | are offered by You alone, not by the Initial Developer or 189 | Contributor. You hereby agree to indemnify the Initial Developer and 190 | every Contributor for any liability incurred by the Initial 191 | Developer or such Contributor as a result of any such terms You offer. 192 | 193 | 3.6. Larger Works. 194 | 195 | You may create a Larger Work by combining Covered Software with 196 | other code not governed by the terms of this License and distribute 197 | the Larger Work as a single product. In such a case, You must make 198 | sure the requirements of this License are fulfilled for the Covered 199 | Software. 200 | 201 | 4. Versions of the License. 202 | 203 | 4.1. New Versions. 204 | 205 | Oracle is the initial license steward and may publish revised and/or 206 | new versions of this License from time to time. Each version will be 207 | given a distinguishing version number. Except as provided in Section 208 | 4.3, no one other than the license steward has the right to modify 209 | this License. 210 | 211 | 4.2. Effect of New Versions. 212 | 213 | You may always continue to use, distribute or otherwise make the 214 | Covered Software available under the terms of the version of the 215 | License under which You originally received the Covered Software. If 216 | the Initial Developer includes a notice in the Original Software 217 | prohibiting it from being distributed or otherwise made available 218 | under any subsequent version of the License, You must distribute and 219 | make the Covered Software available under the terms of the version 220 | of the License under which You originally received the Covered 221 | Software. Otherwise, You may also choose to use, distribute or 222 | otherwise make the Covered Software available under the terms of any 223 | subsequent version of the License published by the license steward. 224 | 225 | 4.3. Modified Versions. 226 | 227 | When You are an Initial Developer and You want to create a new 228 | license for Your Original Software, You may create and use a 229 | modified version of this License if You: (a) rename the license and 230 | remove any references to the name of the license steward (except to 231 | note that the license differs from this License); and (b) otherwise 232 | make it clear that the license contains terms which differ from this 233 | License. 234 | 235 | 5. DISCLAIMER OF WARRANTY. 236 | 237 | COVERED SOFTWARE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" BASIS, 238 | WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, 239 | INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED SOFTWARE 240 | IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR 241 | NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF 242 | THE COVERED SOFTWARE IS WITH YOU. SHOULD ANY COVERED SOFTWARE PROVE 243 | DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY 244 | OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, 245 | REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN 246 | ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED SOFTWARE IS 247 | AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. 248 | 249 | 6. TERMINATION. 250 | 251 | 6.1. This License and the rights granted hereunder will terminate 252 | automatically if You fail to comply with terms herein and fail to 253 | cure such breach within 30 days of becoming aware of the breach. 254 | Provisions which, by their nature, must remain in effect beyond the 255 | termination of this License shall survive. 256 | 257 | 6.2. If You assert a patent infringement claim (excluding 258 | declaratory judgment actions) against Initial Developer or a 259 | Contributor (the Initial Developer or Contributor against whom You 260 | assert such claim is referred to as "Participant") alleging that the 261 | Participant Software (meaning the Contributor Version where the 262 | Participant is a Contributor or the Original Software where the 263 | Participant is the Initial Developer) directly or indirectly 264 | infringes any patent, then any and all rights granted directly or 265 | indirectly to You by such Participant, the Initial Developer (if the 266 | Initial Developer is not the Participant) and all Contributors under 267 | Sections 2.1 and/or 2.2 of this License shall, upon 60 days notice 268 | from Participant terminate prospectively and automatically at the 269 | expiration of such 60 day notice period, unless if within such 60 270 | day period You withdraw Your claim with respect to the Participant 271 | Software against such Participant either unilaterally or pursuant to 272 | a written agreement with Participant. 273 | 274 | 6.3. If You assert a patent infringement claim against Participant 275 | alleging that the Participant Software directly or indirectly 276 | infringes any patent where such claim is resolved (such as by 277 | license or settlement) prior to the initiation of patent 278 | infringement litigation, then the reasonable value of the licenses 279 | granted by such Participant under Sections 2.1 or 2.2 shall be taken 280 | into account in determining the amount or value of any payment or 281 | license. 282 | 283 | 6.4. In the event of termination under Sections 6.1 or 6.2 above, 284 | all end user licenses that have been validly granted by You or any 285 | distributor hereunder prior to termination (excluding licenses 286 | granted to You by any distributor) shall survive termination. 287 | 288 | 7. LIMITATION OF LIABILITY. 289 | 290 | UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT 291 | (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE 292 | INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF 293 | COVERED SOFTWARE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE 294 | TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR 295 | CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT 296 | LIMITATION, DAMAGES FOR LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER 297 | FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR 298 | LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE 299 | POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT 300 | APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH 301 | PARTY'S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH 302 | LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR 303 | LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION 304 | AND LIMITATION MAY NOT APPLY TO YOU. 305 | 306 | 8. U.S. GOVERNMENT END USERS. 307 | 308 | The Covered Software is a "commercial item," as that term is defined 309 | in 48 C.F.R. 2.101 (Oct. 1995), consisting of "commercial computer 310 | software" (as that term is defined at 48 C.F.R. § 311 | 252.227-7014(a)(1)) and "commercial computer software documentation" 312 | as such terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent 313 | with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 314 | (June 1995), all U.S. Government End Users acquire Covered Software 315 | with only those rights set forth herein. This U.S. Government Rights 316 | clause is in lieu of, and supersedes, any other FAR, DFAR, or other 317 | clause or provision that addresses Government rights in computer 318 | software under this License. 319 | 320 | 9. MISCELLANEOUS. 321 | 322 | This License represents the complete agreement concerning subject 323 | matter hereof. If any provision of this License is held to be 324 | unenforceable, such provision shall be reformed only to the extent 325 | necessary to make it enforceable. This License shall be governed by 326 | the law of the jurisdiction specified in a notice contained within 327 | the Original Software (except to the extent applicable law, if any, 328 | provides otherwise), excluding such jurisdiction's conflict-of-law 329 | provisions. Any litigation relating to this License shall be subject 330 | to the jurisdiction of the courts located in the jurisdiction and 331 | venue specified in a notice contained within the Original Software, 332 | with the losing party responsible for costs, including, without 333 | limitation, court costs and reasonable attorneys' fees and expenses. 334 | The application of the United Nations Convention on Contracts for 335 | the International Sale of Goods is expressly excluded. Any law or 336 | regulation which provides that the language of a contract shall be 337 | construed against the drafter shall not apply to this License. You 338 | agree that You alone are responsible for compliance with the United 339 | States export administration regulations (and the export control 340 | laws and regulation of any other countries) when You use, distribute 341 | or otherwise make available any Covered Software. 342 | 343 | 10. RESPONSIBILITY FOR CLAIMS. 344 | 345 | As between Initial Developer and the Contributors, each party is 346 | responsible for claims and damages arising, directly or indirectly, 347 | out of its utilization of rights under this License and You agree to 348 | work with Initial Developer and Contributors to distribute such 349 | responsibility on an equitable basis. Nothing herein is intended or 350 | shall be deemed to constitute any admission of liability. 351 | 352 | ------------------------------------------------------------------------ 353 | 354 | NOTICE PURSUANT TO SECTION 9 OF THE COMMON DEVELOPMENT AND DISTRIBUTION 355 | LICENSE (CDDL) 356 | 357 | The code released under the CDDL shall be governed by the laws of the 358 | State of California (excluding conflict-of-law provisions). Any 359 | litigation relating to this License shall be subject to the jurisdiction 360 | of the Federal Courts of the Northern District of California and the 361 | state courts of the State of California, with venue lying in Santa Clara 362 | County, California. 363 | 364 | 365 | 366 | The GNU General Public License (GPL) Version 2, June 1991 367 | 368 | Copyright (C) 1989, 1991 Free Software Foundation, Inc. 369 | 51 Franklin Street, Fifth Floor 370 | Boston, MA 02110-1335 371 | USA 372 | 373 | Everyone is permitted to copy and distribute verbatim copies 374 | of this license document, but changing it is not allowed. 375 | 376 | Preamble 377 | 378 | The licenses for most software are designed to take away your freedom to 379 | share and change it. By contrast, the GNU General Public License is 380 | intended to guarantee your freedom to share and change free software--to 381 | make sure the software is free for all its users. This General Public 382 | License applies to most of the Free Software Foundation's software and 383 | to any other program whose authors commit to using it. (Some other Free 384 | Software Foundation software is covered by the GNU Library General 385 | Public License instead.) You can apply it to your programs, too. 386 | 387 | When we speak of free software, we are referring to freedom, not price. 388 | Our General Public Licenses are designed to make sure that you have the 389 | freedom to distribute copies of free software (and charge for this 390 | service if you wish), that you receive source code or can get it if you 391 | want it, that you can change the software or use pieces of it in new 392 | free programs; and that you know you can do these things. 393 | 394 | To protect your rights, we need to make restrictions that forbid anyone 395 | to deny you these rights or to ask you to surrender the rights. These 396 | restrictions translate to certain responsibilities for you if you 397 | distribute copies of the software, or if you modify it. 398 | 399 | For example, if you distribute copies of such a program, whether gratis 400 | or for a fee, you must give the recipients all the rights that you have. 401 | You must make sure that they, too, receive or can get the source code. 402 | And you must show them these terms so they know their rights. 403 | 404 | We protect your rights with two steps: (1) copyright the software, and 405 | (2) offer you this license which gives you legal permission to copy, 406 | distribute and/or modify the software. 407 | 408 | Also, for each author's protection and ours, we want to make certain 409 | that everyone understands that there is no warranty for this free 410 | software. If the software is modified by someone else and passed on, we 411 | want its recipients to know that what they have is not the original, so 412 | that any problems introduced by others will not reflect on the original 413 | authors' reputations. 414 | 415 | Finally, any free program is threatened constantly by software patents. 416 | We wish to avoid the danger that redistributors of a free program will 417 | individually obtain patent licenses, in effect making the program 418 | proprietary. To prevent this, we have made it clear that any patent must 419 | be licensed for everyone's free use or not licensed at all. 420 | 421 | The precise terms and conditions for copying, distribution and 422 | modification follow. 423 | 424 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 425 | 426 | 0. This License applies to any program or other work which contains a 427 | notice placed by the copyright holder saying it may be distributed under 428 | the terms of this General Public License. The "Program", below, refers 429 | to any such program or work, and a "work based on the Program" means 430 | either the Program or any derivative work under copyright law: that is 431 | to say, a work containing the Program or a portion of it, either 432 | verbatim or with modifications and/or translated into another language. 433 | (Hereinafter, translation is included without limitation in the term 434 | "modification".) Each licensee is addressed as "you". 435 | 436 | Activities other than copying, distribution and modification are not 437 | covered by this License; they are outside its scope. The act of running 438 | the Program is not restricted, and the output from the Program is 439 | covered only if its contents constitute a work based on the Program 440 | (independent of having been made by running the Program). Whether that 441 | is true depends on what the Program does. 442 | 443 | 1. You may copy and distribute verbatim copies of the Program's source 444 | code as you receive it, in any medium, provided that you conspicuously 445 | and appropriately publish on each copy an appropriate copyright notice 446 | and disclaimer of warranty; keep intact all the notices that refer to 447 | this License and to the absence of any warranty; and give any other 448 | recipients of the Program a copy of this License along with the Program. 449 | 450 | You may charge a fee for the physical act of transferring a copy, and 451 | you may at your option offer warranty protection in exchange for a fee. 452 | 453 | 2. You may modify your copy or copies of the Program or any portion of 454 | it, thus forming a work based on the Program, and copy and distribute 455 | such modifications or work under the terms of Section 1 above, provided 456 | that you also meet all of these conditions: 457 | 458 | a) You must cause the modified files to carry prominent notices 459 | stating that you changed the files and the date of any change. 460 | 461 | b) You must cause any work that you distribute or publish, that in 462 | whole or in part contains or is derived from the Program or any part 463 | thereof, to be licensed as a whole at no charge to all third parties 464 | under the terms of this License. 465 | 466 | c) If the modified program normally reads commands interactively 467 | when run, you must cause it, when started running for such 468 | interactive use in the most ordinary way, to print or display an 469 | announcement including an appropriate copyright notice and a notice 470 | that there is no warranty (or else, saying that you provide a 471 | warranty) and that users may redistribute the program under these 472 | conditions, and telling the user how to view a copy of this License. 473 | (Exception: if the Program itself is interactive but does not 474 | normally print such an announcement, your work based on the Program 475 | is not required to print an announcement.) 476 | 477 | These requirements apply to the modified work as a whole. If 478 | identifiable sections of that work are not derived from the Program, and 479 | can be reasonably considered independent and separate works in 480 | themselves, then this License, and its terms, do not apply to those 481 | sections when you distribute them as separate works. But when you 482 | distribute the same sections as part of a whole which is a work based on 483 | the Program, the distribution of the whole must be on the terms of this 484 | License, whose permissions for other licensees extend to the entire 485 | whole, and thus to each and every part regardless of who wrote it. 486 | 487 | Thus, it is not the intent of this section to claim rights or contest 488 | your rights to work written entirely by you; rather, the intent is to 489 | exercise the right to control the distribution of derivative or 490 | collective works based on the Program. 491 | 492 | In addition, mere aggregation of another work not based on the Program 493 | with the Program (or with a work based on the Program) on a volume of a 494 | storage or distribution medium does not bring the other work under the 495 | scope of this License. 496 | 497 | 3. You may copy and distribute the Program (or a work based on it, 498 | under Section 2) in object code or executable form under the terms of 499 | Sections 1 and 2 above provided that you also do one of the following: 500 | 501 | a) Accompany it with the complete corresponding machine-readable 502 | source code, which must be distributed under the terms of Sections 1 503 | and 2 above on a medium customarily used for software interchange; or, 504 | 505 | b) Accompany it with a written offer, valid for at least three 506 | years, to give any third party, for a charge no more than your cost 507 | of physically performing source distribution, a complete 508 | machine-readable copy of the corresponding source code, to be 509 | distributed under the terms of Sections 1 and 2 above on a medium 510 | customarily used for software interchange; or, 511 | 512 | c) Accompany it with the information you received as to the offer to 513 | distribute corresponding source code. (This alternative is allowed 514 | only for noncommercial distribution and only if you received the 515 | program in object code or executable form with such an offer, in 516 | accord with Subsection b above.) 517 | 518 | The source code for a work means the preferred form of the work for 519 | making modifications to it. For an executable work, complete source code 520 | means all the source code for all modules it contains, plus any 521 | associated interface definition files, plus the scripts used to control 522 | compilation and installation of the executable. However, as a special 523 | exception, the source code distributed need not include anything that is 524 | normally distributed (in either source or binary form) with the major 525 | components (compiler, kernel, and so on) of the operating system on 526 | which the executable runs, unless that component itself accompanies the 527 | executable. 528 | 529 | If distribution of executable or object code is made by offering access 530 | to copy from a designated place, then offering equivalent access to copy 531 | the source code from the same place counts as distribution of the source 532 | code, even though third parties are not compelled to copy the source 533 | along with the object code. 534 | 535 | 4. You may not copy, modify, sublicense, or distribute the Program 536 | except as expressly provided under this License. Any attempt otherwise 537 | to copy, modify, sublicense or distribute the Program is void, and will 538 | automatically terminate your rights under this License. However, parties 539 | who have received copies, or rights, from you under this License will 540 | not have their licenses terminated so long as such parties remain in 541 | full compliance. 542 | 543 | 5. You are not required to accept this License, since you have not 544 | signed it. However, nothing else grants you permission to modify or 545 | distribute the Program or its derivative works. These actions are 546 | prohibited by law if you do not accept this License. Therefore, by 547 | modifying or distributing the Program (or any work based on the 548 | Program), you indicate your acceptance of this License to do so, and all 549 | its terms and conditions for copying, distributing or modifying the 550 | Program or works based on it. 551 | 552 | 6. Each time you redistribute the Program (or any work based on the 553 | Program), the recipient automatically receives a license from the 554 | original licensor to copy, distribute or modify the Program subject to 555 | these terms and conditions. You may not impose any further restrictions 556 | on the recipients' exercise of the rights granted herein. You are not 557 | responsible for enforcing compliance by third parties to this License. 558 | 559 | 7. If, as a consequence of a court judgment or allegation of patent 560 | infringement or for any other reason (not limited to patent issues), 561 | conditions are imposed on you (whether by court order, agreement or 562 | otherwise) that contradict the conditions of this License, they do not 563 | excuse you from the conditions of this License. If you cannot distribute 564 | so as to satisfy simultaneously your obligations under this License and 565 | any other pertinent obligations, then as a consequence you may not 566 | distribute the Program at all. For example, if a patent license would 567 | not permit royalty-free redistribution of the Program by all those who 568 | receive copies directly or indirectly through you, then the only way you 569 | could satisfy both it and this License would be to refrain entirely from 570 | distribution of the Program. 571 | 572 | If any portion of this section is held invalid or unenforceable under 573 | any particular circumstance, the balance of the section is intended to 574 | apply and the section as a whole is intended to apply in other 575 | circumstances. 576 | 577 | It is not the purpose of this section to induce you to infringe any 578 | patents or other property right claims or to contest validity of any 579 | such claims; this section has the sole purpose of protecting the 580 | integrity of the free software distribution system, which is implemented 581 | by public license practices. Many people have made generous 582 | contributions to the wide range of software distributed through that 583 | system in reliance on consistent application of that system; it is up to 584 | the author/donor to decide if he or she is willing to distribute 585 | software through any other system and a licensee cannot impose that choice. 586 | 587 | This section is intended to make thoroughly clear what is believed to be 588 | a consequence of the rest of this License. 589 | 590 | 8. If the distribution and/or use of the Program is restricted in 591 | certain countries either by patents or by copyrighted interfaces, the 592 | original copyright holder who places the Program under this License may 593 | add an explicit geographical distribution limitation excluding those 594 | countries, so that distribution is permitted only in or among countries 595 | not thus excluded. In such case, this License incorporates the 596 | limitation as if written in the body of this License. 597 | 598 | 9. The Free Software Foundation may publish revised and/or new 599 | versions of the General Public License from time to time. Such new 600 | versions will be similar in spirit to the present version, but may 601 | differ in detail to address new problems or concerns. 602 | 603 | Each version is given a distinguishing version number. If the Program 604 | specifies a version number of this License which applies to it and "any 605 | later version", you have the option of following the terms and 606 | conditions either of that version or of any later version published by 607 | the Free Software Foundation. If the Program does not specify a version 608 | number of this License, you may choose any version ever published by the 609 | Free Software Foundation. 610 | 611 | 10. If you wish to incorporate parts of the Program into other free 612 | programs whose distribution conditions are different, write to the 613 | author to ask for permission. For software which is copyrighted by the 614 | Free Software Foundation, write to the Free Software Foundation; we 615 | sometimes make exceptions for this. Our decision will be guided by the 616 | two goals of preserving the free status of all derivatives of our free 617 | software and of promoting the sharing and reuse of software generally. 618 | 619 | NO WARRANTY 620 | 621 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO 622 | WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. 623 | EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR 624 | OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, 625 | EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 626 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE 627 | ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH 628 | YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL 629 | NECESSARY SERVICING, REPAIR OR CORRECTION. 630 | 631 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN 632 | WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY 633 | AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR 634 | DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL 635 | DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM 636 | (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED 637 | INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF 638 | THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR 639 | OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 640 | 641 | END OF TERMS AND CONDITIONS 642 | 643 | How to Apply These Terms to Your New Programs 644 | 645 | If you develop a new program, and you want it to be of the greatest 646 | possible use to the public, the best way to achieve this is to make it 647 | free software which everyone can redistribute and change under these terms. 648 | 649 | To do so, attach the following notices to the program. It is safest to 650 | attach them to the start of each source file to most effectively convey 651 | the exclusion of warranty; and each file should have at least the 652 | "copyright" line and a pointer to where the full notice is found. 653 | 654 | One line to give the program's name and a brief idea of what it does. 655 | Copyright (C) 656 | 657 | This program is free software; you can redistribute it and/or modify 658 | it under the terms of the GNU General Public License as published by 659 | the Free Software Foundation; either version 2 of the License, or 660 | (at your option) any later version. 661 | 662 | This program is distributed in the hope that it will be useful, but 663 | WITHOUT ANY WARRANTY; without even the implied warranty of 664 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 665 | General Public License for more details. 666 | 667 | You should have received a copy of the GNU General Public License 668 | along with this program; if not, write to the Free Software 669 | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA 670 | 671 | Also add information on how to contact you by electronic and paper mail. 672 | 673 | If the program is interactive, make it output a short notice like this 674 | when it starts in an interactive mode: 675 | 676 | Gnomovision version 69, Copyright (C) year name of author 677 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type 678 | `show w'. This is free software, and you are welcome to redistribute 679 | it under certain conditions; type `show c' for details. 680 | 681 | The hypothetical commands `show w' and `show c' should show the 682 | appropriate parts of the General Public License. Of course, the commands 683 | you use may be called something other than `show w' and `show c'; they 684 | could even be mouse-clicks or menu items--whatever suits your program. 685 | 686 | You should also get your employer (if you work as a programmer) or your 687 | school, if any, to sign a "copyright disclaimer" for the program, if 688 | necessary. Here is a sample; alter the names: 689 | 690 | Yoyodyne, Inc., hereby disclaims all copyright interest in the 691 | program `Gnomovision' (which makes passes at compilers) written by 692 | James Hacker. 693 | 694 | signature of Ty Coon, 1 April 1989 695 | Ty Coon, President of Vice 696 | 697 | This General Public License does not permit incorporating your program 698 | into proprietary programs. If your program is a subroutine library, you 699 | may consider it more useful to permit linking proprietary applications 700 | with the library. If this is what you want to do, use the GNU Library 701 | General Public License instead of this License. 702 | 703 | # 704 | 705 | Certain source files distributed by Oracle America, Inc. and/or its 706 | affiliates are subject to the following clarification and special 707 | exception to the GPLv2, based on the GNU Project exception for its 708 | Classpath libraries, known as the GNU Classpath Exception, but only 709 | where Oracle has expressly included in the particular source file's 710 | header the words "Oracle designates this particular file as subject to 711 | the "Classpath" exception as provided by Oracle in the LICENSE file 712 | that accompanied this code." 713 | 714 | You should also note that Oracle includes multiple, independent 715 | programs in this software package. Some of those programs are provided 716 | under licenses deemed incompatible with the GPLv2 by the Free Software 717 | Foundation and others. For example, the package includes programs 718 | licensed under the Apache License, Version 2.0. Such programs are 719 | licensed to you under their original licenses. 720 | 721 | Oracle facilitates your further distribution of this package by adding 722 | the Classpath Exception to the necessary parts of its GPLv2 code, which 723 | permits you to use that code in combination with other independent 724 | modules not licensed under the GPLv2. However, note that this would 725 | not permit you to commingle code under an incompatible license with 726 | Oracle's GPLv2 licensed code by, for example, cutting and pasting such 727 | code into a file also containing Oracle's GPLv2 licensed code and then 728 | distributing the result. Additionally, if you were to remove the 729 | Classpath Exception from any of the files to which it applies and 730 | distribute the result, you would likely be required to license some or 731 | all of the other code in that distribution under the GPLv2 as well, and 732 | since the GPLv2 is incompatible with the license terms of some items 733 | included in the distribution by Oracle, removing the Classpath 734 | Exception could therefore effectively compromise your ability to 735 | further distribute the package. 736 | 737 | Proceed with caution and we recommend that you obtain the advice of a 738 | lawyer skilled in open source matters before removing the Classpath 739 | Exception or making modifications to this package which may 740 | subsequently be redistributed and/or involve the use of third party 741 | software. 742 | 743 | CLASSPATH EXCEPTION 744 | Linking this library statically or dynamically with other modules is 745 | making a combined work based on this library. Thus, the terms and 746 | conditions of the GNU General Public License version 2 cover the whole 747 | combination. 748 | 749 | As a special exception, the copyright holders of this library give you 750 | permission to link this library with independent modules to produce an 751 | executable, regardless of the license terms of these independent 752 | modules, and to copy and distribute the resulting executable under 753 | terms of your choice, provided that you also meet, for each linked 754 | independent module, the terms and conditions of the license of that 755 | module. An independent module is a module which is not derived from or 756 | based on this library. If you modify this library, you may extend this 757 | exception to your version of the library, but you are not obligated to 758 | do so. If you do not wish to do so, delete this exception statement 759 | from your version. 760 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | #### :warning:This project is now part of the EE4J initiative. This repository has been archived as all activities are now happening in the [corresponding Eclipse repository](https://github.com/eclipse-ee4j/common-annotations-api). See [here](https://www.eclipse.org/ee4j/status.php) for the overall EE4J transition status. 2 | 3 | --- 4 | 5 | # Java(TM) Common Annotations 6 | 7 | The intention of Java(TM) Common Annotations is to develop annotations for common semantic 8 | concepts in the Java SE and Java EE platforms that apply across a variety of individual 9 | technologies. It was envisioned that various JSRs would use annotations to enable a declarative 10 | style of programming. It would be especially valuable to have consistency within the Java EE 11 | component JSRs, but it is also valuable to allow consistency between Java EE and Java SE. 12 | 13 | This standalone release of Java(TM) Common Annotations uses a 14 | [Java Platform Module System](http://openjdk.java.net/projects/jigsaw/spec/) 15 | "automatic" module name of `java.annotation`, to match the module name 16 | used in JDK 9. A future version will include full module metadata. 17 | -------------------------------------------------------------------------------- /pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 43 | 44 | 45 | 4.0.0 46 | 47 | net.java 48 | jvnet-parent 49 | 3 50 | 51 | 52 | javax.annotation 53 | javax.annotation-api 54 | 1.3.3-SNAPSHOT 55 | 56 | 57 | false 58 | 1.3 59 | javax.annotation 60 | javax.annotation-api 61 | Oracle Corporation 62 | org.glassfish 63 | 2.3.1 64 | exclude.xml 65 | Low 66 | 67 | ${extension.name} API 68 | Common Annotations for the JavaTM Platform API 69 | 70 | http://jcp.org/en/jsr/detail?id=250 71 | 72 | 73 | 74 | ldemichiel 75 | Linda De Michiel 76 | Oracle Corp. 77 | 78 | lead 79 | 80 | 81 | 82 | 83 | 84 | GlassFish Community 85 | https://javaee.github.io/glassfish 86 | 87 | 88 | 89 | CDDL + GPLv2 with classpath exception 90 | https://github.com/javaee/javax.annotation/blob/master/LICENSE 91 | repo 92 | A business-friendly OSS license 93 | 94 | 95 | 96 | GitHub 97 | https://github.com/javaee/javax.annotation/issues 98 | 99 | 100 | 101 | GlassFish Developer 102 | javaee-spec@javaee.groups.io 103 | 104 | 105 | 106 | scm:git:https://github.com/javaee/javax.annotation.git 107 | scm:git:git@github.com:javaee/javax.annotation.git 108 | https://github.com/javaee/javax.annotation 109 | HEAD 110 | 111 | 112 | 113 | 114 | 115 | src/main/java 116 | 117 | **/*.properties 118 | **/*.html 119 | 120 | 121 | 122 | src/main/resources 123 | 124 | META-INF/README 125 | 126 | 127 | 128 | 129 | 130 | maven-compiler-plugin 131 | 2.5.1 132 | 133 | 1.8 134 | 1.8 135 | -Xlint:unchecked 136 | 137 | 138 | 139 | org.glassfish.build 140 | spec-version-maven-plugin 141 | 1.2 142 | 143 | 144 | ${non.final} 145 | api 146 | ${spec.build} 147 | ${spec.version} 148 | ${new.spec.version} 149 | ${project.version} 150 | ${extension.name} 151 | 152 | 153 | 154 | 155 | 156 | set-spec-properties 157 | check-module 158 | 159 | 160 | 161 | 162 | 163 | org.apache.felix 164 | maven-bundle-plugin 165 | 1.4.3 166 | 167 | 168 | jar 169 | 170 | 171 | ${spec.bundle.version} 172 | ${spec.bundle.symbolic-name} 173 | ${spec.extension.name} 174 | ${spec.implementation.version} 175 | ${spec.specification.version} 176 | 177 | Java(TM) Common Annotations ${spec.version} API Design Specification 178 | 179 | ${vendor.name} 180 | ${project.organization.name} 181 | ${implementation.vendor.id} 182 | 183 | 184 | 185 | 186 | bundle-manifest 187 | process-classes 188 | 189 | manifest 190 | 191 | 192 | 193 | 194 | 195 | org.apache.maven.plugins 196 | maven-jar-plugin 197 | 2.4 198 | 199 | 200 | ${project.build.outputDirectory}/META-INF/MANIFEST.MF 201 | 202 | 203 | 204 | java.annotation 205 | 206 | 207 | 208 | 209 | **/*.java 210 | 211 | 212 | 213 | 214 | org.apache.maven.plugins 215 | maven-remote-resources-plugin 216 | 1.2.1 217 | 218 | 219 | 220 | process 221 | 222 | 223 | 224 | org.glassfish:legal:1.1 225 | 226 | 227 | 228 | 229 | 230 | 231 | org.apache.maven.plugins 232 | maven-source-plugin 233 | 2.1 234 | 235 | true 236 | 237 | 238 | 239 | attach-sources 240 | 241 | jar-no-fork 242 | 243 | 244 | 245 | 246 | 247 | org.apache.maven.plugins 248 | maven-javadoc-plugin 249 | 2.8 250 | 251 | 252 | attach-javadocs 253 | 254 | jar 255 | 256 | 257 | 258 | javadoc 259 | 260 | javadoc 261 | 262 | 263 | 264 | 265 | Common Annotations API Documentation 266 | javax.annotation 267 | 268 | 269 | 270 | Oracle 272 | and/or its affiliates. All Rights Reserved. 273 | Use is subject to 274 | license terms. 275 | ]]> 276 | 277 | 278 | 279 | 280 | 281 | 282 | org.codehaus.mojo 283 | findbugs-maven-plugin 284 | ${findbugs.version} 285 | 286 | ${findbugs.threshold} 287 | ${findbugs.exclude} 288 | true 289 | true 290 | 291 | 292 | 293 | org.apache.maven.plugins 294 | maven-release-plugin 295 | 2.5.3 296 | 297 | forked-path 298 | false 299 | ${release.arguments} 300 | @{project.version} 301 | 302 | 303 | 304 | org.apache.maven.plugins 305 | maven-site-plugin 306 | 3.1 307 | 308 | 309 | 310 | 311 | org.codehaus.mojo 312 | findbugs-maven-plugin 313 | ${findbugs.version} 314 | 315 | ${findbugs.threshold} 316 | ${findbugs.exclude} 317 | 318 | 319 | 320 | 321 | 322 | 323 | 324 | org.apache.maven.plugins 325 | maven-gpg-plugin 326 | 327 | 328 | sign-artifacts 329 | verify 330 | 331 | sign 332 | 333 | 334 | 335 | 336 | 337 | 338 | 339 | -------------------------------------------------------------------------------- /release.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | #------------------------------------------------------ 3 | #-- BE SURE TO HAVE THE FOLLOWING IN YOUR SETTINGS.XML 4 | #------------------------------------------------------ 5 | # 6 | # 7 | # 8 | # jvnet-nexus-staging 9 | # jvnet_id 10 | # password 11 | # 12 | # 13 | # 14 | # 15 | # release 16 | # 17 | # -Dhttps.proxyHost=www-proxy.us.oracle.com -Dhttps.proxyPort=80 -Dgpg.passphrase=glassfish -Pjvnet-release 18 | # 19 | # 20 | # false 21 | # 22 | # 23 | # 24 | 25 | # see the following URL for gpg issues 26 | # https://docs.sonatype.org/display/Repository/How+To+Generate+PGP+Signatures+With+Maven#HowToGeneratePGPSignaturesWithMaven-GenerateaKeyPair 27 | 28 | # login to nexus at maven.java.net and release (Close) the artifact 29 | # https://maven.java.net/index.html#stagingRepositories 30 | 31 | # More information: 32 | # https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide#SonatypeOSSMavenRepositoryUsageGuide-8.ReleaseIt 33 | # http://aseng-wiki.us.oracle.com/asengwiki/display/GlassFish/Migrating+Maven+deployment+to+maven.java.net 34 | 35 | mvn -B release:prepare -Prelease 36 | mvn -B release:perform -Prelease 37 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/Generated.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * The Generated annotation is used to mark source code 48 | * that has been generated. 49 | * It can also be used to differentiate user written code from generated code 50 | * in a single file. 51 | *

The value element must have the name of the 52 | * code generator. The recommended convention is to use the fully qualified 53 | * name of the code generator in the value field, 54 | * for example com.company.package.classname.

55 | *

The date element is used to indicate the date the 56 | * source was generated. 57 | * The date element must follow the ISO 8601 standard. 58 | * For example, the date element could have the 59 | * value 2001-07-04T12:08:56.235-0700, 60 | * which represents 2001-07-04 12:08:56 local time in the U.S. Pacific 61 | * time zone.

62 | *

The comment element is a place holder for any comments 63 | * that the code generator may want to include in the generated code.

64 | * 65 | * @since 1.6, Common Annotations 1.0 66 | */ 67 | 68 | @Documented 69 | @Retention(SOURCE) 70 | @Target({PACKAGE, TYPE, ANNOTATION_TYPE, METHOD, CONSTRUCTOR, FIELD, 71 | LOCAL_VARIABLE, PARAMETER}) 72 | public @interface Generated { 73 | /** 74 | * The value element must have the name of the code generator. 75 | * The recommended convention is to use the fully qualified name of the 76 | * code generator. For example: com.acme.generator.CodeGen. 77 | */ 78 | String[] value(); 79 | 80 | /** 81 | * Date when the source was generated. 82 | */ 83 | String date() default ""; 84 | 85 | /** 86 | * A place holder for any comments that the code generator may want to 87 | * include in the generated code. 88 | */ 89 | String comments() default ""; 90 | } 91 | 92 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/ManagedBean.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2009-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | 43 | import java.lang.annotation.*; 44 | import static java.lang.annotation.ElementType.*; 45 | import static java.lang.annotation.RetentionPolicy.*; 46 | 47 | /** 48 | * The ManagedBean annotation marks a POJO (Plain Old Java Object) 49 | * as a ManagedBean. A ManagedBean supports a small set of basic services 50 | * such as resource injection, lifecycle callbacks and interceptors. 51 | * 52 | * @since Common Annotations 1.1 53 | */ 54 | @Target(TYPE) 55 | @Retention(RUNTIME) 56 | public @interface ManagedBean { 57 | /** 58 | * The name of the Managed Bean. Managed Bean names must be unique within a 59 | * Java EE module. For each named Managed Bean, Java EE containers must make 60 | * available the following entries in JNDI, using the same naming scheme used 61 | * for EJB components. 62 | *

63 | * In the application namespace:

64 | * java:app/<module-name>/<bean-name>

65 | * In the module namespace of the module containing the Managed Bean: 66 | *

java:module/<bean-name> 67 | * 68 | */ 69 | public String value() default ""; 70 | } 71 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/PostConstruct.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | 43 | import java.lang.annotation.*; 44 | import static java.lang.annotation.ElementType.*; 45 | import static java.lang.annotation.RetentionPolicy.*; 46 | 47 | /** 48 | * The PostConstruct annotation is used on a method that 49 | * needs to be executed after dependency injection is done to perform 50 | * any initialization. This method must be invoked before the class 51 | * is put into service. This annotation must be supported on all classes 52 | * that support dependency injection. The method annotated with 53 | * PostConstruct must be invoked even if the class does 54 | * not request any resources to be injected. Only one 55 | * method in a given class can be annotated with this annotation. 56 | * The method on which the PostConstruct annotation is 57 | * applied must fulfill all of the following criteria: 58 | *

88 | * 89 | * @see javax.annotation.PreDestroy 90 | * @see javax.annotation.Resource 91 | * @since 1.6, Common Annotations 1.0 92 | */ 93 | @Documented 94 | @Retention (RUNTIME) 95 | @Target(METHOD) 96 | public @interface PostConstruct { 97 | } 98 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/PreDestroy.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | 43 | import java.lang.annotation.*; 44 | import static java.lang.annotation.ElementType.*; 45 | import static java.lang.annotation.RetentionPolicy.*; 46 | 47 | /** 48 | * The PreDestroy annotation is used on a method as a 49 | * callback notification to signal that the instance is in the 50 | * process of being removed by the container. The method annotated 51 | * with PreDestroy is typically used to 52 | * release resources that it has been holding. This annotation must be 53 | * supported by all container-managed objects that support the use of 54 | * the PostConstruct annotation except the Java EE application 55 | * client. The method on which the PreDestroy annotation 56 | * is applied must fulfill all of the following criteria: 57 | * 87 | * 88 | * @see javax.annotation.PostConstruct 89 | * @see javax.annotation.Resource 90 | * @since 1.6, Common Annotations 1.0 91 | */ 92 | 93 | @Documented 94 | @Retention (RUNTIME) 95 | @Target(METHOD) 96 | public @interface PreDestroy { 97 | } 98 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/Priority.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | 43 | import java.lang.annotation.*; 44 | import static java.lang.annotation.ElementType.*; 45 | import static java.lang.annotation.RetentionPolicy.*; 46 | 47 | /** 48 | * The Priority annotation can be applied to classes 49 | * or parameters to indicate in what order they should be used. 50 | * The effect of using the Priority annotation in 51 | * any particular instance is defined by other specifications that 52 | * define the use of a specific class. 53 | *

54 | * For example, the Interceptors specification defines the use of 55 | * priorities on interceptors to control the order in which 56 | * interceptors are called.

57 | *

58 | * Priority values should generally be non-negative, with negative values 59 | * reserved for special meanings such as "undefined" or "not specified". 60 | * A specification that defines use of the Priority annotation may define 61 | * the range of allowed priorities and any priority values with special 62 | * meaning.

63 | * 64 | * @since Common Annotations 1.2 65 | */ 66 | @Target({TYPE,PARAMETER}) 67 | @Retention(RUNTIME) 68 | @Documented 69 | public @interface Priority { 70 | /** 71 | * The priority value. 72 | */ 73 | int value(); 74 | } 75 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/Resource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | 43 | import java.lang.annotation.*; 44 | import static java.lang.annotation.ElementType.*; 45 | import static java.lang.annotation.RetentionPolicy.*; 46 | 47 | /** 48 | * The Resource annotation marks a resource that is needed 49 | * by the application. This annotation may be applied to an 50 | * application component class, or to fields or methods of the 51 | * component class. When the annotation is applied to a 52 | * field or method, the container will inject an instance 53 | * of the requested resource into the application component 54 | * when the component is initialized. If the annotation is 55 | * applied to the component class, the annotation declares a 56 | * resource that the application will look up at runtime. 57 | *

58 | * Even though this annotation is not marked Inherited, deployment 59 | * tools are required to examine all superclasses of any component 60 | * class to discover all uses of this annotation in all superclasses. 61 | * All such annotation instances specify resources that are needed 62 | * by the application component. Note that this annotation may 63 | * appear on private fields and methods of superclasses; the container 64 | * is required to perform injection in these cases as well.

65 | * 66 | * @since 1.6, Common Annotations 1.0 67 | */ 68 | @Target({TYPE, FIELD, METHOD}) 69 | @Retention(RUNTIME) 70 | @Repeatable(Resources.class) 71 | public @interface Resource { 72 | /** 73 | * The JNDI name of the resource. For field annotations, 74 | * the default is the field name. For method annotations, 75 | * the default is the JavaBeans property name corresponding 76 | * to the method. For class annotations, there is no default 77 | * and this must be specified. 78 | */ 79 | String name() default ""; 80 | 81 | /** 82 | * The name of the resource that the reference points to. It can 83 | * link to any compatible resource using the global JNDI names. 84 | * 85 | * @since 1.7, Common Annotations 1.1 86 | */ 87 | 88 | String lookup() default ""; 89 | 90 | /** 91 | * The Java type of the resource. For field annotations, 92 | * the default is the type of the field. For method annotations, 93 | * the default is the type of the JavaBeans property. 94 | * For class annotations, there is no default and this must be 95 | * specified. 96 | */ 97 | Class type() default java.lang.Object.class; 98 | 99 | /** 100 | * The two possible authentication types for a resource. 101 | */ 102 | enum AuthenticationType { 103 | CONTAINER, 104 | APPLICATION 105 | } 106 | 107 | /** 108 | * The authentication type to use for this resource. 109 | * This may be specified for resources representing a 110 | * connection factory of any supported type, and must 111 | * not be specified for resources of other types. 112 | */ 113 | AuthenticationType authenticationType() default AuthenticationType.CONTAINER; 114 | 115 | /** 116 | * Indicates whether this resource can be shared between 117 | * this component and other components. 118 | * This may be specified for resources representing a 119 | * connection factory of any supported type, and must 120 | * not be specified for resources of other types. 121 | */ 122 | boolean shareable() default true; 123 | 124 | /** 125 | * A product-specific name that this resource should be mapped to. 126 | * The mappedName element provides for mapping the 127 | * resource reference to the name of a resource known to the 128 | * applicaiton server. The mapped name could be of any form. 129 | *

Application servers are not required to support any particular 130 | * form or type of mapped name, nor the ability to use mapped names. 131 | * The mapped name is product-dependent and often installation-dependent. 132 | * No use of a mapped name is portable.

133 | */ 134 | String mappedName() default ""; 135 | 136 | /** 137 | * Description of this resource. The description is expected 138 | * to be in the default language of the system on which the 139 | * application is deployed. The description can be presented 140 | * to the Deployer to help in choosing the correct resource. 141 | */ 142 | String description() default ""; 143 | } 144 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/Resources.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * This class is used to allow multiple resources declarations. 48 | * 49 | * @see javax.annotation.Resource 50 | * @since 1.6, Common Annotations 1.0 51 | */ 52 | 53 | @Documented 54 | @Retention(RUNTIME) 55 | @Target(TYPE) 56 | public @interface Resources { 57 | /** 58 | * Array used for multiple resource declarations. 59 | */ 60 | Resource[] value(); 61 | } 62 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/package.html: -------------------------------------------------------------------------------- 1 | 42 | 43 | 44 | 45 | This package defines the common annotations. 46 | 47 | 48 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/security/DeclareRoles.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.security; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * Used by application to declare security roles. It can be 48 | * specified on a class. The value of the DeclareRoles 49 | * annotation is a list of security role names. 50 | * 51 | * @since Common Annotations 1.0 52 | */ 53 | @Documented 54 | @Retention (RUNTIME) 55 | @Target(TYPE) 56 | public @interface DeclareRoles { 57 | /** 58 | * List of security role names. 59 | */ 60 | String[] value(); 61 | } 62 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/security/DenyAll.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.security; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * Specifies that no security roles are allowed to invoke the specified 48 | * method(s). 49 | * 50 | * @see javax.annotation.security.RolesAllowed 51 | * @see javax.annotation.security.PermitAll 52 | * @since Common Annotations 1.0 53 | */ 54 | @Documented 55 | @Retention (RUNTIME) 56 | @Target({TYPE, METHOD}) 57 | public @interface DenyAll { 58 | } 59 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/security/PermitAll.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.security; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * Specifies that all security roles are allowed to invoke the specified 48 | * method(s) — i.e., that the specified method(s) are "unchecked". 49 | * It can be specified on a class or on methods. Specifying it on the class 50 | * means that it applies to all methods of the class. If specified at the 51 | * method level, it only affects that method. If the RolesAllowed 52 | * annotation is specified at the class level and this annotation is 53 | * applied at the method level, the PermitAll 54 | * annotation overrides the RolesAllowed annotation for 55 | * the specified method. 56 | * 57 | * @see javax.annotation.security.RolesAllowed 58 | * @see javax.annotation.security.DenyAll 59 | * 60 | * @since Common Annotations 1.0 61 | */ 62 | @Documented 63 | @Retention (RUNTIME) 64 | @Target({TYPE, METHOD}) 65 | public @interface PermitAll { 66 | } 67 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/security/RolesAllowed.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.security; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * Specifies the list of security roles permitted to access method(s) in an 48 | * application. The value of the RolesAllowed annotation 49 | * is a list of security role names. 50 | * This annotation can be specified on a class or on method(s). Specifying it 51 | * at a class level means that it applies to all the methods in the class. 52 | * Specifying it on a method means that it is applicable to that method only. 53 | * If applied at both the class and methods level, the method value overrides 54 | * the class value if the two conflict. 55 | * 56 | * @since Common Annotations 1.0 57 | */ 58 | @Documented 59 | @Retention (RUNTIME) 60 | @Target({TYPE, METHOD}) 61 | public @interface RolesAllowed { 62 | /** 63 | * List of roles that are permitted access. 64 | */ 65 | String[] value(); 66 | } 67 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/security/RunAs.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2005-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.security; 42 | import java.lang.annotation.*; 43 | import static java.lang.annotation.ElementType.*; 44 | import static java.lang.annotation.RetentionPolicy.*; 45 | 46 | /** 47 | * Defines the identity of the application during execution. 48 | * This allows developers to execute an application under a particular role. 49 | * The role must map to the user / group information in the container's 50 | * security realm. Its value is the name of a security role. 51 | * 52 | * @since Common Annotations 1.0 53 | */ 54 | @Documented 55 | @Retention (RUNTIME) 56 | @Target(TYPE) 57 | public @interface RunAs { 58 | /** 59 | * Name of a security role. 60 | */ 61 | String value(); 62 | } 63 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/security/package.html: -------------------------------------------------------------------------------- 1 | 42 | 43 | 44 | 45 | This package contains the security common annotations. 46 | 47 | 48 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/sql/DataSourceDefinition.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2009-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.sql; 42 | 43 | import java.lang.annotation.*; 44 | import java.lang.annotation.Target; 45 | import java.lang.annotation.Retention; 46 | import java.lang.annotation.ElementType; 47 | import java.lang.annotation.RetentionPolicy; 48 | 49 | /** 50 | * Annotation used to define a container DataSource to 51 | * be registered with JNDI. The DataSource may be configured by 52 | * setting the annotation elements for commonly used DataSource 53 | * properties. Additional standard and vendor-specific properties may be 54 | * specified using the properties element. 55 | *

56 | * 57 | * The data source will be registered under the name specified in the 58 | * name element. It may be defined to be in any valid 59 | * Java EE namespace, which will determine the accessibility of 60 | * the data source from other components. 61 | *

62 | * A JDBC driver implementation class of the appropriate type, either 63 | * DataSource, ConnectionPoolDataSource, or 64 | * XADataSource, must be indicated by the className 65 | * element. The availability of the driver class will be assumed at runtime. 66 | *

67 | * DataSource properties should not be specified more than once. If 68 | * the url annotation element contains a DataSource property that was also 69 | * specified using the corresponding annotation element or was specified in 70 | * the properties annotation element, the precedence order is undefined 71 | * and implementation specific: 72 | *

73 | *

 74 |  *   @DataSourceDefinition(name="java:global/MyApp/MyDataSource",
 75 |  *      className="org.apache.derby.jdbc.ClientDataSource",
 76 |  *      url="jdbc:derby://localhost:1527/myDB;user=bill",
 77 |  *      user="lance",
 78 |  *      password="secret",
 79 |  *      databaseName="testDB",
 80 |  *      serverName="luckydog"
 81 |  *   )// DO NOT DO THIS!!!
 82 |  * 
83 | *

84 | * In the above example, the databaseName, user 85 | * and serverName properties were specified as part of the 86 | * url property and using the corresponding 87 | * annotation elements. This should be avoided. 88 | *

89 | * If the properties annotation element is used and contains a 90 | * DataSource property that was also specified using the corresponding 91 | * annotation element, the annotation element value takes precedence. 92 | * For example: 93 | *

94 | *

 95 |  *   @DataSourceDefinition(name="java:global/MyApp/MyDataSource",
 96 |  *      className="org.apache.derby.jdbc.ClientDataSource",
 97 |  *      user="lance",
 98 |  *      password="secret",
 99 |  *      databaseName="testDB",
100 |  *      serverName="luckydog",
101 |  *       properties= {"databaseName=myDB", "databaseProp=doThis"}
102 |  *   )// DO NOT DO THIS!!!
103 |  * 
104 | *

105 | * This would result in the following values being used when configuring 106 | * the DataSource: 107 | *

115 | *

116 | * Vendors are not required to support properties that do not normally 117 | * apply to a specific data source type. For example, specifying the 118 | * transactional property to be true but supplying 119 | * a value for className that implements a data source class 120 | * other than XADataSource may not be supported. 121 | *

122 | * Vendor-specific properties may be combined with or used to 123 | * override standard data source properties defined using this annotation. 124 | *

125 | * DataSource properties that are specified and are not supported 126 | * in a given configuration or cannot be mapped to a vendor specific 127 | * configuration property may be ignored. 128 | *

129 | * Examples: 130 | *
131 | *

132 |  *   @DataSourceDefinition(name="java:global/MyApp/MyDataSource",
133 |  *      className="com.foobar.MyDataSource",
134 |  *      portNumber=6689,
135 |  *      serverName="myserver.com",
136 |  *      user="lance",
137 |  *      password="secret"
138 |  *   )
139 |  * 
140 |  * 
141 | *

142 | * Using a URL: 143 | *
144 | *

145 |  *  @DataSourceDefinition(name="java:global/MyApp/MyDataSource",
146 |  *    className="org.apache.derby.jdbc.ClientDataSource",
147 |  *    url="jdbc:derby://localhost:1527/myDB",
148 |  *    user="lance",
149 |  *    password="secret"
150 |  * )
151 |  * 
152 | *

153 | * An example lookup of the DataSource from an EJB: 154 | *

155 |  * @Stateless
156 |  * public class MyStatelessEJB {
157 |  *   @Resource(lookup="java:global/MyApp/myDataSource")
158 |  *    DataSource myDB;
159 |  *      ...
160 |  * }
161 |  * 
162 | *

163 | * @see javax.sql.DataSource 164 | * @see javax.sql.XADataSource 165 | * @see javax.sql.ConnectionPoolDataSource 166 | * @since Common Annotations 1.1 167 | */ 168 | @Target({ElementType.TYPE}) 169 | @Retention(RetentionPolicy.RUNTIME) 170 | @Repeatable(DataSourceDefinitions.class) 171 | public @interface DataSourceDefinition { 172 | 173 | /** 174 | * JNDI name by which the data source will be registered. 175 | * @since 1.1 176 | */ 177 | String name(); 178 | 179 | /** 180 | * Name of a DataSource class that implements 181 | * javax.sql.DataSource or javax.sql.XADataSource 182 | * or javax.sql.ConnectionPoolDataSource. 183 | * @since 1.1 184 | */ 185 | String className(); 186 | 187 | /** 188 | * Description of this data source 189 | * @since 1.1 190 | */ 191 | String description() default ""; 192 | 193 | /** 194 | * A JDBC URL. If the url annotation element contains a 195 | * DataSource property that was also specified using the corresponding 196 | * annotation element, the precedence order is undefined and 197 | * implementation specific. 198 | * @since 1.1 199 | */ 200 | String url() default ""; 201 | 202 | /** 203 | * User name to use for connection authentication. 204 | * @since 1.1 205 | */ 206 | String user() default ""; 207 | 208 | /** 209 | * Password to use for connection authentication. 210 | * @since 1.1 211 | */ 212 | String password() default ""; 213 | 214 | /** 215 | * Name of a database on a server. 216 | * @since 1.1 217 | */ 218 | String databaseName() default ""; 219 | 220 | /** 221 | * Port number where a server is listening for requests. 222 | * @since 1.1 223 | */ 224 | int portNumber() default -1; 225 | 226 | /** 227 | * Database server name. 228 | * @since 1.1 229 | */ 230 | String serverName() default "localhost"; 231 | 232 | /** 233 | * Isolation level for connections. The Isolation level 234 | * must be one of the following: 235 | *

236 | *

243 | *

244 | * Default is vendor-specific. 245 | * @since 1.1 246 | */ 247 | int isolationLevel() default -1; 248 | 249 | /** 250 | * Set to false if connections should not participate 251 | * in transactions. 252 | *

253 | * Default is to enlist in a transaction when one is active or becomes 254 | * active. 255 | * @since 1.1 256 | */ 257 | boolean transactional() default true; 258 | 259 | /** 260 | * Number of connections that should be created when a connection pool 261 | * is initialized. 262 | *

263 | * Default is vendor-specific 264 | * @since 1.1 265 | */ 266 | int initialPoolSize() default -1; 267 | 268 | /** 269 | * Maximum number of connections that should be concurrently allocated for a 270 | * connection pool. 271 | *

272 | * Default is vendor-specific. 273 | * @since 1.1 274 | */ 275 | int maxPoolSize() default -1; 276 | 277 | /** 278 | * Minimum number of connections that should be allocated for a 279 | * connection pool. 280 | *

281 | * Default is vendor-specific. 282 | * @since 1.1 283 | */ 284 | int minPoolSize() default -1; 285 | 286 | /** 287 | * The number of seconds that a physical connection 288 | * should remain unused in the pool before the 289 | * connection is closed for a connection pool. 290 | *

291 | * Default is vendor-specific 292 | * @since 1.1 293 | */ 294 | int maxIdleTime() default -1; 295 | 296 | /** 297 | * The total number of statements that a connection pool should keep open. 298 | * A value of 0 indicates that the caching of statements is disabled for 299 | * a connection pool. 300 | *

301 | * Default is vendor-specific 302 | * @since 1.1 303 | */ 304 | int maxStatements() default -1; 305 | /** 306 | * Used to specify vendor-specific properties and less commonly 307 | * used DataSource properties such as: 308 | *

309 | *

315 | *

316 | * Properties are specified using the format: 317 | * propertyName=propertyValue with one property per array element. 318 | *

319 | * If a DataSource property is specified in the properties 320 | * element and the annotation element for the property is also 321 | * specified, the annotation element value takes precedence. 322 | * @since 1.1 323 | */ 324 | String[] properties() default {}; 325 | 326 | 327 | /** 328 | * Sets the maximum time in seconds that this data source will wait while 329 | * attempting to connect to a database. A value of zero specifies that 330 | * the timeout is the default system timeout if there is one; otherwise, 331 | * it specifies that there is no timeout. 332 | *

333 | * Default is vendor-specific. 334 | * @since 1.1 335 | */ 336 | int loginTimeout() default 0; 337 | } 338 | -------------------------------------------------------------------------------- /src/main/java/javax/annotation/sql/DataSourceDefinitions.java: -------------------------------------------------------------------------------- 1 | /* 2 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3 | * 4 | * Copyright (c) 2009-2018 Oracle and/or its affiliates. All rights reserved. 5 | * 6 | * The contents of this file are subject to the terms of either the GNU 7 | * General Public License Version 2 only ("GPL") or the Common Development 8 | * and Distribution License("CDDL") (collectively, the "License"). You 9 | * may not use this file except in compliance with the License. You can 10 | * obtain a copy of the License at 11 | * https://oss.oracle.com/licenses/CDDL+GPL-1.1 12 | * or LICENSE.txt. See the License for the specific 13 | * language governing permissions and limitations under the License. 14 | * 15 | * When distributing the software, include this License Header Notice in each 16 | * file and include the License file at LICENSE.txt. 17 | * 18 | * GPL Classpath Exception: 19 | * Oracle designates this particular file as subject to the "Classpath" 20 | * exception as provided by Oracle in the GPL Version 2 section of the License 21 | * file that accompanied this code. 22 | * 23 | * Modifications: 24 | * If applicable, add the following below the License Header, with the fields 25 | * enclosed by brackets [] replaced by your own identifying information: 26 | * "Portions Copyright [year] [name of copyright owner]" 27 | * 28 | * Contributor(s): 29 | * If you wish your version of this file to be governed by only the CDDL or 30 | * only the GPL Version 2, indicate your decision by adding "[Contributor] 31 | * elects to include this software in this distribution under the [CDDL or GPL 32 | * Version 2] license." If you don't indicate a single choice of license, a 33 | * recipient has the option to distribute your version of this file under 34 | * either the CDDL, the GPL Version 2 or to extend the choice of license to 35 | * its licensees as provided above. However, if you add GPL Version 2 code 36 | * and therefore, elected the GPL Version 2 license, then the option applies 37 | * only if the new code is made subject to such option by the copyright 38 | * holder. 39 | */ 40 | 41 | package javax.annotation.sql; 42 | 43 | import java.lang.annotation.Target; 44 | import java.lang.annotation.Retention; 45 | import java.lang.annotation.ElementType; 46 | import java.lang.annotation.RetentionPolicy; 47 | 48 | /** 49 | * Declares one or more DataSourceDefinition annotations. 50 | * 51 | * @see javax.annotation.sql.DataSourceDefinition 52 | * @since Common Annotations 1.1 53 | */ 54 | @Target({ElementType.TYPE}) 55 | @Retention(RetentionPolicy.RUNTIME) 56 | public @interface DataSourceDefinitions { 57 | DataSourceDefinition[] value (); 58 | 59 | } 60 | -------------------------------------------------------------------------------- /src/main/javadoc/doc-files/speclicense.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Specification License 4 | 5 | 6 | Specification: JSR-250 Common Annotation for the Java Platform Specification ("Specification") 7 |
8 | Version: 1.3 9 |
10 | Status: Maintenance Release 11 |
12 | Specification Lead: Oracle America, Inc. ("Specification Lead") 13 |
14 | Release: July 2016 15 |
16 | 17 |
18 | Copyright © 2016 Oracle America, Inc. 19 |
20 | All rights reserved. 21 |
22 |

23 | LIMITED LICENSE GRANTS 24 |
25 | 1. License for Evaluation Purposes. Specification Lead hereby grants 26 | you a fully-paid, non-exclusive, non-transferable, worldwide, limited 27 | license (without the right to sublicense), under Specification Lead's 28 | applicable intellectual property rights to view, download, use and 29 | reproduce the Specification only for the purpose of internal 30 | evaluation. This includes (i) developing applications intended to run 31 | on an implementation of the Specification, provided that such 32 | applications do not themselves implement any portion(s) of the 33 | Specification, and (ii) discussing the Specification with any third 34 | party; and (iii) excerpting brief portions of the Specification in oral 35 | or written communications which discuss the Specification provided that 36 | such excerpts do not in the aggregate constitute a significant portion 37 | of the Specification. 38 |

39 |

40 | 2. License for the Distribution of Compliant Implementations. 41 | Specification Lead also grants you a perpetual, non-exclusive, 42 | non-transferable, worldwide, fully paid-up, royalty free, limited 43 | license (without the right to sublicense) under any applicable 44 | copyrights or, subject to the provisions of subsection 4 below, patent 45 | rights it may have covering the Specification to create and/or 46 | distribute an Independent Implementation of the Specification that: (a) 47 | fully implements the Specification including all its required 48 | interfaces and functionality; (b) does not modify, subset, superset or 49 | otherwise extend the Licensor Name Space, or include any public or 50 | protected packages, classes, Java interfaces, fields or methods within 51 | the Licensor Name Space other than those required/authorized by the 52 | Specification or Specifications being implemented; and (c) passes the 53 | Technology Compatibility Kit (including satisfying the requirements of 54 | the applicable TCK Users Guide) for such Specification ("Compliant 55 | Implementation"). In addition, the foregoing license is expressly 56 | conditioned on your not acting outside its scope. No license is 57 | granted hereunder for any other purpose (including, for example, 58 | modifying the Specification, other than to the extent of your fair use 59 | rights, or distributing the Specification to third parties). Also, no 60 | right, title, or interest in or to any trademarks, service marks, or 61 | trade names of Specification Lead or Specification Lead's licensors is 62 | granted hereunder. Java, and Java-related logos, marks and names are 63 | trademarks or registered trademarks of Oracle America, Inc. in the U.S. 64 | and other countries. 65 |

66 |

67 | 3. Pass-through Conditions. You need not include limitations (a)-(c) 68 | from the previous paragraph or any other particular "pass through" 69 | requirements in any license You grant concerning the use of your 70 | Independent Implementation or products derived from it. However, 71 | except with respect to Independent Implementations (and products 72 | derived from them) that satisfy limitations (a)-(c) from the previous 73 | paragraph, You may neither: (a) grant or otherwise pass through to 74 | your licensees any licenses under Specification Lead's applicable 75 | intellectual property rights; nor (b) authorize your licensees to make 76 | any claims concerning their implementation's compliance with the 77 | Specification in question. 78 |

79 |

80 | 4. Reciprocity Concerning Patent Licenses. 81 |
82 | a. With respect to any patent claims covered by the license granted 83 | under subparagraph 2 above that would be infringed by all technically 84 | feasible implementations of the Specification, such license is 85 | conditioned upon your offering on fair, reasonable and 86 | non-discriminatory terms, to any party seeking it from You, a 87 | perpetual, non-exclusive, non-transferable, worldwide license under 88 | Your patent rights which are or would be infringed by all technically 89 | feasible implementations of the Specification to develop, distribute 90 | and use a Compliant Implementation. 91 |
92 | b. With respect to any patent claims owned by Specification Lead and 93 | covered by the license granted under subparagraph 2, whether or not 94 | their infringement can be avoided in a technically feasible manner when 95 | implementing the Specification, such license shall terminate with 96 | respect to such claims if You initiate a claim against Specification 97 | Lead that it has, in the course of performing its responsibilities as 98 | the Specification Lead, induced any other entity to infringe Your 99 | patent rights. 100 |
101 | c. Also with respect to any patent claims owned by Specification Lead 102 | and covered by the license granted under subparagraph 2 above, where 103 | the infringement of such claims can be avoided in a technically 104 | feasible manner when implementing the Specification such license, with 105 | respect to such claims, shall terminate if You initiate a claim against 106 | Specification Lead that its making, having made, using, offering to 107 | sell, selling or importing a Compliant Implementation infringes Your 108 | patent rights. 109 |

110 |

111 | 5. Definitions. For the purposes of this Agreement: "Independent 112 | Implementation" shall mean an implementation of the Specification that 113 | neither derives from any of Specification Lead's source code or binary 114 | code materials nor, except with an appropriate and separate license 115 | from Specification Lead, includes any of Specification Lead's source 116 | code or binary code materials; "Licensor Name Space" shall mean the 117 | public class or interface declarations whose names begin with "java", 118 | "javax", "com.sun" and "com.oracle" or their equivalents in any 119 | subsequent naming convention adopted by Oracle America, Inc. through 120 | the Java Community Process, or any recognized successors or 121 | replacements thereof; and "Technology Compatibility Kit" or "TCK" shall 122 | mean the test suite and accompanying TCK User's Guide provided by 123 | Specification Lead which corresponds to the Specification and that was 124 | available either (i) from Specification Lead's 120 days before the 125 | first release of Your Independent Implementation that allows its use 126 | for commercial purposes, or (ii) more recently than 120 days from such 127 | release but against which You elect to test Your implementation of the 128 | Specification. 129 |

130 |

131 | This Agreement will terminate immediately without notice from 132 | Specification Lead if you breach the Agreement or act outside the scope 133 | of the licenses granted above. 134 |

135 |

136 | DISCLAIMER OF WARRANTIES 137 |
138 | THE SPECIFICATION IS PROVIDED "AS IS". SPECIFICATION LEAD MAKES NO 139 | REPRESENTATIONS OR WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING BUT 140 | NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR 141 | PURPOSE, NON-INFRINGEMENT (INCLUDING AS A CONSEQUENCE OF ANY PRACTICE 142 | OR IMPLEMENTATION OF THE SPECIFICATION), OR THAT THE CONTENTS OF THE 143 | SPECIFICATION ARE SUITABLE FOR ANY PURPOSE. This document does not 144 | represent any commitment to release or implement any portion of the 145 | Specification in any product. In addition, the Specification could 146 | include technical inaccuracies or typographical errors. 147 |

148 |

149 | LIMITATION OF LIABILITY 150 |
151 | TO THE EXTENT NOT PROHIBITED BY LAW, IN NO EVENT WILL SPECIFICATION 152 | LEAD OR ITS LICENSORS BE LIABLE FOR ANY DAMAGES, INCLUDING WITHOUT 153 | LIMITATION, LOST REVENUE, PROFITS OR DATA, OR FOR SPECIAL, INDIRECT, 154 | CONSEQUENTIAL, INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER CAUSED AND 155 | REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF OR RELATED IN ANY 156 | WAY TO YOUR HAVING, IMPELEMENTING OR OTHERWISE USING USING THE 157 | SPECIFICATION, EVEN IF SPECIFICATION LEAD AND/OR ITS LICENSORS HAVE 158 | BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. You will indemnify, 159 | hold harmless, and defend Specification Lead and its licensors from any 160 | claims arising or resulting from: (i) your use of the Specification; 161 | (ii) the use or distribution of your Java application, applet and/or 162 | implementation; and/or (iii) any claims that later versions or releases 163 | of any Specification furnished to you are incompatible with the 164 | Specification provided to you under this license. 165 |

166 |

167 | RESTRICTED RIGHTS LEGEND 168 |
169 | U.S. Government: If this Specification is being acquired by or on 170 | behalf of the U.S. Government or by a U.S. Government prime contractor 171 | or subcontractor (at any tier), then the Government's rights in the 172 | Software and accompanying documentation shall be only as set forth in 173 | this license; this is in accordance with 48 C.F.R. 227.7201 through 174 | 227.7202-4 (for Department of Defense (DoD) acquisitions) and with 48 175 | C.F.R. 2.101 and 12.212 (for non-DoD acquisitions). 176 |

177 |

178 | REPORT 179 |
180 | If you provide Specification Lead with any comments or suggestions 181 | concerning the Specification ("Feedback"), you hereby: (i) agree that 182 | such Feedback is provided on a non-proprietary and non-confidential 183 | basis, and (ii) grant Specification Lead a perpetual, non-exclusive, 184 | worldwide, fully paid-up, irrevocable license, with the right to 185 | sublicense through multiple levels of sublicensees, to incorporate, 186 | disclose, and use without limitation the Feedback for any purpose. 187 |

188 |

189 | GENERAL TERMS 190 |
191 | Any action related to this Agreement will be governed by California law 192 | and controlling U.S. federal law. The U.N. Convention for the 193 | International Sale of Goods and the choice of law rules of any 194 | jurisdiction will not apply. 195 |

196 |

197 | The Specification is subject to U.S. export control laws and may be 198 | subject to export or import regulations in other countries. Licensee 199 | agrees to comply strictly with all such laws and regulations and 200 | acknowledges that it has the responsibility to obtain such licenses to 201 | export, re-export or import as may be required after delivery to 202 | Licensee. 203 |

204 |

205 | This Agreement is the parties' entire agreement relating to its subject 206 | matter. It supersedes all prior or contemporaneous oral or written 207 | communications, proposals, conditions, representations and warranties 208 | and prevails over any conflicting or additional terms of any quote, 209 | order, acknowledgment, or other communication between the parties 210 | relating to its subject matter during the term of this Agreement. No 211 | modification to this Agreement will be binding, unless in writing and 212 | signed by an authorized representative of each party. 213 |

214 | 215 | 216 | --------------------------------------------------------------------------------