Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[wtp-dev] Validation component api changes


Api Requirement and Implementation

We got a new requirement today for the validation framework to expose the kind of build that is presently occurring to the validator. The JSP validator was the validator that raised this requirement so it can better handle the situation when an empty uri list is being passed in through the IValidationContext::getURIs() to the validator and the JSP Validator wanted to take an appropriate action based on the build kind that was occurring.

To satisfy this api requirement we have added an new api on IValidationContext :: public int getBuildKind(). This api returns the kind of build that the BuildManager passes to the ValidationBuilder. Now any validator that wants to take an action on a particular kind of build (INCREMENTAL_BUILD or FULL_BUILD or AUTO_BUILD or CLEAN_BUILD) can do so.

Api change effecting existing clients

Any implementer's of IValidationContext need to implement this additional getBuildKind() method and can just return 0 if they are not interested in knowing the build kind. Users of default implementation of the IValidationContext i.e WorkbenchContext will need not have to do anything and just use the api if they need it in for their validator.

These changes are being released to head now.

Thanks,

Regards, Vijay
-------------------------------------------------
Vijay Bhadriraju                                        
Rational Tools, J2EE Tooling              
Ph: (919) 486-1898, T/L: 526-1898    
Internet: vbhadrir@xxxxxxxxxx          
-------------------------------------------------

Back to the top