5 Oct 11:25
annotations again
From: Marius Danciu <marius.danciu <at> gmail.com>
Subject: annotations again
Newsgroups: gmane.comp.lang.scala
Date: 2008-10-05 09:26:05 GMT
Subject: annotations again
Newsgroups: gmane.comp.lang.scala
Date: 2008-10-05 09:26:05 GMT
Hi,
Maybe this topic has been discussed quite a few time by now but I have a few question. Is is so that Scala annotations are not translated to Java annotations to be accessible at runtime using Java reflection?
if I have
class MyField extends scala.Annotation
class A {
<at> MyField
var a: Strimg = _
}
compiles just fine but of course at runtime if I obtain the the field's annotations java.lang.reflect.Field#getDeclaredAnnotations I get nothing.
Br's,
Marius
Maybe this topic has been discussed quite a few time by now but I have a few question. Is is so that Scala annotations are not translated to Java annotations to be accessible at runtime using Java reflection?
if I have
class MyField extends scala.Annotation
class A {
<at> MyField
var a: Strimg = _
}
compiles just fine but of course at runtime if I obtain the the field's annotations java.lang.reflect.Field#getDeclaredAnnotations I get nothing.
Br's,
Marius
RSS Feed