| /******************************************************************************* |
| * Copyright (c) 2010,2013 E.D.Willink and others. |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License v1.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/epl-v10.html |
| * |
| * Contributors: |
| * E.D.Willink - initial API and implementation |
| * E.D.Willink (CEA LIST) - Bug 424034 |
| * |
| * Run As->MWE2 Workflow to regenerate the pivot model. |
| *******************************************************************************/ |
| module GenerateOCLstdlibModel |
| |
| import org.eclipse.ocl.examples.build.utilities.* |
| import org.eclipse.ocl.examples.build.xtend.* |
| import org.eclipse.emf.mwe.utils.* |
| import org.eclipse.emf.mwe.utils.* |
| import org.eclipse.emf.ecore.resource.impl.* |
| |
| var sourceName = "org.eclipse.ocl.examples.library" |
| var targetName = "org.eclipse.ocl.examples.pivot" |
| |
| /** |
| * Generate the OCLstdlib Model, by converting oclstdlib.oclstdlib to OCLstdlib.java. |
| */ |
| Workflow { |
| bean = ResourceSetImpl : resourceSet {} |
| bean = StandaloneSetup { resourceSet = resourceSet |
| platformUri = ".." |
| } |
| bean = GenModelSetup { resourceSet = resourceSet } |
| component = GenerateOCLstdlibXtend { resourceSet = resourceSet |
| projectName = "${sourceName}" |
| modelFile = "model/OCL-2.5.oclstdlib" |
| uri = "http://www.eclipse.org/ocl/3.1.0/OCL.oclstdlib" |
| javaFolder = "/${targetName}/emf-gen" |
| javaPackageName = "${targetName}.model" |
| javaClassName = "OCLstdlib" |
| } |
| component = GenerateModel { resourceSet = resourceSet skipOnErrors = true |
| genModel = "/${sourceName}/model/oclstdlib.genmodel" |
| } |
| component = Model2tablesGenerator { resourceSet = resourceSet |
| genModelFile = "/${sourceName}/model/oclstdlib.genmodel" |
| genOCLstdlib = true |
| } |
| } |
| |