JSP ругается на поле с нижним подчеркиванием, но информации о том, что так делать нельзя, я не нашел.
Стек Tomcat:
SEVERE: Servlet.service() for servlet [jsp] threw exception
javax.el.PropertyNotFoundException: Property [the_year_of_publishing] not found on type [com.core.newbie.model.Book]
...
21:50:32.693 [http-nio-8080-exec-5] DEBUG
org.springframework.web.servlet.DispatcherServlet - Could not complete request
org.apache.jasper.JasperException: An exception occurred processing [/WEB-
INF/book/showBook.jsp] at line [84]
81: <td><a href="#">${book.name}</a></td>
82: <td>${book.author}</td>
83: <td></td>
84: <td>${book.the_year_of_publishing}</td>
Book.java, часть кода:
public String getPublishingHouse() {
return publishing_house;
}
public void setPublishingHouse(final String publishing_house) {
this.publishing_house = publishing_house == null ? null : publishing_house.trim();
}
public Integer getTheYearOfPublishing() {
return the_year_of_publishing;
}
public void setTheYearOfPublishing(final Integer the_year_of_publishing) {
this.the_year_of_publishing = the_year_of_publishing;
}
На эти оба поля ругается в JSP, одно убрал. В чем может быть дело?