Closed eclipse-ocl-bot closed 1 month ago
By Ed Willink on Sep 30, 2012 12:27
Read the OCL Standard Library section in http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.ocl.doc%2Fhelp%2FPivotStandalone.html.
By Ed Willink on May 27, 2014 09:45
CLOSED after more than a year in RESOLVED state.
By Ed Willink on May 27, 2014 09:53
and CLOSE
| --- | --- | | Bugzilla Link | 390768 | | Status | CLOSED INVALID | | Importance | P3 normal | | Reported | Sep 30, 2012 09:12 EDT | | Modified | May 27, 2014 09:53 EDT | | Reporter | Faiez Za |
Description
I define my file test.ocl using \ completeocl sources (org.eclipse.ocl.examples.xtext.completeocl -> Run As Eclipse Application)
[code]\ import 'MyEcore.ecore'\ package test
context TestClass ... ....\ [/code]
I try after to parse this file using Xtext.\ [code]\ package fr.enseeiht.completeocl.parser;
import java.io.IOException;\ import java.util.Map;
import org.eclipse.emf.common.util.URI;\ import org.eclipse.emf.ecore.resource.Resource;\ import org.eclipse.emf.ecore.resource.ResourceSet;\ import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl;\ import org.eclipse.emf.ecore.util.EcoreUtil;\ import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl;\ import org.eclipse.ocl.examples.xtext.completeocl.CompleteOCLStandaloneSetup;
[code]
public class Parser {
}\ [/code]
[/code]
I get this error
[code]\ Exception in thread "main" org.eclipse.ocl.examples.pivot.utilities.IllegalLibraryException: No OCL Standard Library content available\ at org.eclipse.ocl.examples.pivot.manager.PivotStandardLibrary.getRequiredLibraryType(PivotStandardLibrary.java:277)\ at org.eclipse.ocl.examples.pivot.manager.PivotStandardLibrary.resolveRequiredSimpleType(PivotStandardLibrary.java:376)\ at org.eclipse.ocl.examples.pivot.manager.PivotStandardLibrary.getOclInvalidType(PivotStandardLibrary.java:206)\ at org.eclipse.ocl.examples.xtext.base.baseCST.impl.PathElementCSImpl.getElement(PathElementCSImpl.java:354)\ at org.eclipse.ocl.examples.xtext.base.baseCST.impl.PathNameCSImpl.getElement(PathNameCSImpl.java:390)\ at org.eclipse.ocl.examples.xtext.completeocl.completeOCLCST.impl.ClassifierContextDeclCSImpl.getClassifier(ClassifierContextDeclCSImpl.java:201)\ at org.eclipse.ocl.examples.xtext.completeocl.completeOCLCST.impl.ClassifierContextDeclCSImpl.eIsSet(ClassifierContextDeclCSImpl.java:168)\ at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eIsSet(BasicEObjectImpl.java:1237)\ at org.eclipse.emf.ecore.util.EContentsEList$FeatureIteratorImpl.hasNext(EContentsEList.java:401)\ at org.eclipse.emf.ecore.util.EContentsEList$FeatureIteratorImpl.next(EContentsEList.java:559)\ at org.eclipse.emf.ecore.util.EcoreUtil.resolveCrossReferences(EcoreUtil.java:302)\ at org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(EcoreUtil.java:296)\ at org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(EcoreUtil.java:281)\ at fr.enseeiht.completeocl.parser.Parser.main(Parser.java:33)
[/code]
and if I comment this line\ [code]\ //EcoreUtil.resolveAll(resource); \ [/code]
My OCL file is parsed but without resolve cross references:\ For example,\ the \ [code]\ import 'SimplePDL.ecore'\ [/code]\ is parsed as\ [code]\ \
[/code]
Can you please help me to resolve this problem
Best regards,\ Thanks