Enterprise Java
-
Delete records in database with JdbcTemplate
With this example we are going to demonstrate how to delete records in a database, using the JdbcTemplate class provided…
Read More » -
Create Data Source for JdbcTemplate
This is an example of how to create a Datasource for the JdbcTemplate class provided by the Spring Framework. The…
Read More » -
Update records in database with JdbcTemplate
In this example we shall show you how to update records in a database using the JdbcTemplate Class provided by…
Read More » -
Select records from database with JdbcTemplate
With this example we are going to demonstrate how to select records from a database using the JdbcTemplate class provided…
Read More » -
Insert record in database with JdbcTemplate
This is an example of how to insert a record to the database using the JdbcTemplate class provided by the…
Read More » -
Sending e-mails with Spring
We will create a simple Spring service that will be used for sending mail. One method will create a SimpleMailMessage…
Read More » -
Declare bean in Spring container
With this example we are going to demonstrate how to declare a Bean in the Spring container. A Spring bean…
Read More » -
Use preferences in Spring
Spring provides PreferencesPlaceholderConfigurer that can be used to load preferences. <bean id="preferencePlaceHolder" class="org.springframework.beans.factory.config.PreferencesPlaceholderConfigurer"> <property name="userTreePath" value="com.myapp.preference.staticPreferenceLoader" /> </bean> <bean id="myEntity"…
Read More » -
Spring MVC interceptor example
The demonstration code shows you how to modify the incoming HttpServletRequest object before it reaches your controller. This does nothing…
Read More » -
Add Restrictions to the Criteria object in Hibernate
In this example we shall show you how to add restrictions to the Criteria object in Hibernate. In Hibernate, Criteria…
Read More »