Creating a Java Bean Interface for a JDBC Connection

1. Declare the package for the class EmployeeBean.java

package com.oracle.jdbc.samples.bean;

2. Import Employee entity class as it contains the employee details

import com.oracle.jdbc.samples.entity.Employee;

3. Declare an interface EmployeeBean class. Add an open parenthesis ({) and closing parenthesis (}). Place the cursor in between the parenthesis

public interface EmployeeBean {

4. On the new line, declare a method getEmployees()that returns a List of Employee objects.

public List<Employee> getEmployees();