Using a method validator based on a view object accessor

In this recipe, we will show how to validate an entity object against a view accessor using a custom entity method validator. The use case that we will cover—based on the HR schema—will not allow the user to enter more than a specified number of employees per department.

Getting ready

We will be using the HRComponents workspace that we created in the previous recipes in this chapter so that we don't repeat these steps again. You will need access to the HR database schema.

How to do it…

  1. Right-click on the com.packt.jdeveloper.cookbook.hr.components.model.view package of the HRComponentsBC business components project of the HRComponents workspace, and select New View Object….
  2. Use the Create View ...

Get Oracle JDeveloper 11gR2 Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.