Top "Annotations" questions

In programming, annotations are used to add information to a code element which cannot be expressed by the type system.

difference between @size(max = value ) and @min(value) @max(value)

I want ot do some domain validation in my object i am having one integer , now my question is if …

java spring validation annotations
Annotations from javax.validation.constraints not working

What configuration is needed to use annotations from javax.validation.constraints like @Size, @NotNull, etc.? Here's my code: import javax.…

java spring annotations constraints bean-validation
Hibernate Annotations - Which is better, field or property access?

This question is somewhat related to Hibernate Annotation Placement Question. But I want to know which is better? Access via …

java hibernate orm jpa annotations
Implement a simple factory pattern with Spring 3 annotations

I was wondering how I could implement the simple factory pattern with Spring 3 annotations. I saw in the documentation that …

java spring annotations factory-pattern
How and where are Annotations used in Java?

What are the major areas that we can use Annotations? Is the feature a replacement for XML based configuration?

java annotations
What's the difference between interface and @interface in java?

I haven't touched Java since using JBuilder in the late 90's while at University, so I'm a little out of …

java interface annotations language-features
How to inject a Map using the @Value Spring Annotation?

How can i inject values into a Map from the properties file using the @Value annotation in Spring ? My Spring …

java spring dependency-injection annotations spring-annotations
Why does Eclipse complain about @Override on interface methods?

I have an existing project that uses @Override on methods that override interface methods, rather than superclass methods. I cannot …

java eclipse interface annotations syntax-error
What does the length attribute do when set on the @Column JPA annontation?

What exactly does setting the length on a column do in JPA? @Column(name = "middle_name", nullable = false, length = 32) public …

java hibernate jpa annotations
Name attribute in @Entity and @Table

I have a doubt, because name attribute is there in both @Entity and @Table For example, I'm allowed to have …

java hibernate jpa annotations persistence