You can implement them without a framework if you want, but you are giving up any advantages that the infrastructure offers you.
, , - ; . Spring, , .
, , Spring. SQL . , .
, .
, JDBC, JSP, JSTL ( ). , , .
Foo, , , :
package model;
public class Foo
{
}
package persistence;
public interface FooDao
{
Foo find(Long id);
List<Foo> find();
void saveOrUpdate(Foo foo);
void delete(Foo foo);
}
package service;
public interface FooService
{
Foo find(Long id);
List<Foo> find();
void saveOrUpdate(Foo foo);
void delete(Foo foo);
}
package view;
public interface FooController
{
ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response);
}
, , . .