I have a java class using an annotation for a url, e.g.,
I can't hard-code the url in the java code during deployment to appserver. I'm wondering if there's a way to use properties file value in this annotation, so that the url can be pickup up during runtime?
Did you ever get its answer? I am looking for the same but it seems the annotation value has to be a constant and a variable cannot be used unless it is a constant.
private final static val = 1000;
@Anno(value=val) - will work but
private final static val = Integer.valueOf(bundle.getString("val"));
@Anno(value=val) - will not!
But if there is a way I would be very interested.