Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 322079

Summary: NPE in EMFModelValidationPlugin.getPluginId()
Product: [Modeling] EMF Services Reporter: Mirko Seifert <mirko.seifert>
Component: ValidationAssignee: EMF Services Validation inbox <emfservices.validation-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: pierre-charles.david
Version: unspecified   
Target Milestone: 1.13.0   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Mirko Seifert CLA 2010-08-08 09:48:00 EDT
Build Identifier: I20100608-0911

When I use the EMF validation class from an ANT script that runs inside of Eclipse I get the NPE mentioned above. The problem is that EMFPlugin.IS_ECLIPSE_RUNNING is true, because Eclipse is running, but the EMFValidation plug-in is not initialized.

The condition of the if/else statements should be extended to

!EMFPlugin.IS_ECLIPSE_RUNNING || getPlugin() == null

Reproducible: Always