public ISourceParser getSourceParser ( IVdmProject project ) throws CoreException { IConfigurationElement [ ] config = Platform . getExtensionRegistry ( ) . getConfigurationElementsFor ( ICoreConstants . EXTENSION_PARSER_ID ) ; IConfigurationElement selectedParser = getParserWithHeighestPriority ( project . getVdmNature ( ) , config ) ; if ( selectedParser != null ) { final Object o = selectedParser . createExecutableExtension ( "class" ) ; if ( o instanceof AbstractParserParticipant ) { AbstractParserParticipant parser = ( AbstractParserParticipant ) o ; parser . setProject ( project ) ; return parser ; } } return null ; }
Loads a source parser for the given project