Unterschiede
Hier werden die Unterschiede zwischen der gewählten und der aktuellen Version gezeigt.
| java:annotations 2014/03/26 07:55 | java:annotations 2020/01/22 20:59 aktuell | ||
|---|---|---|---|
| Zeile 1: | Zeile 1: | ||
| [[java|Java - Allgemein]]\\ | [[java|Java - Allgemein]]\\ | ||
| ====== Annotations ====== | ====== Annotations ====== | ||
| - | Annotations sind Informationen, die man zu einer Methode oder Klasse notieren und später wieder auslesen kann. | + | Annotations sind Informationen (Metadaten), die man zu einer Methode oder Klasse notieren und später wieder auslesen kann. |
| \\ | \\ | ||
| <html> | <html> | ||
| - | <script type="text/javascript"><!-- | + | <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script> |
| - | google_ad_client="pub-9681858985507948"; | + | <!-- javawiki.sowas.com-w --> |
| - | google_ad_width = 468; | + | <ins class="adsbygoogle" |
| - | google_ad_height = 60; | + | style="display:inline-block;width:728px;height:90px" |
| - | google_ad_format = "468x60_as"; | + | data-ad-client="ca-pub-9681858985507948" |
| - | google_ad_type = "text"; | + | data-ad-slot="1549999954"></ins> |
| - | google_ad_channel = ""; | + | <script> |
| - | google_color_border = "cccccc"; | + | (adsbygoogle = window.adsbygoogle || []).push({}); |
| - | google_color_bg = "FFFFFF"; | + | </script> |
| - | google_color_link = "1d2d8c"; | + | |
| - | google_color_text = "000000"; | + | |
| - | google_color_url = "1d2d8c"; | + | |
| - | //--> | + | |
| - | </script> | + | |
| - | <script type="text/javascript" | + | |
| - | src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> | + | |
| - | </script> | + | |
| </html> | </html> | ||
| \\ | \\ | ||
| Zeile 32: | Zeile 24: | ||
| Nun das Auslesen der Annotation:\\ | Nun das Auslesen der Annotation:\\ | ||
| <code java> | <code java> | ||
| - | boolean annotationsPresent = MyClass.class.isAnnotationPresent(MyAnnotation.class); | + | boolean annotationPresent = MyClass.class.isAnnotationPresent(MyAnnotation.class); |
| </code> | </code> | ||
| + | <html> | ||
| + | <iframe style="width:120px;height:240px;" marginwidth="0" marginheight="0" scrolling="no" frameborder="0" src="//ws-eu.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=DE&source=ac&ref=qf_sp_asin_til&ad_type=product_link&tracking_id=javawiki-21&marketplace=amazon®ion=DE&placement=3864902010&asins=3864902010&linkId=IY2UN7L4QP2SYEZX&show_border=true&link_opens_in_new_window=true"> | ||
| + | </iframe> | ||
| + | </html> | ||
| + | \\ | ||
| + | \\ | ||
| + | Stichworte: | ||
| + | <code> | ||
| + | Annotation, auslesen, Vorhandensein überprüfen, feststellen | ||
| + | </code> | ||
| + | |||