Skip to main content



      Home
Home » Modeling » EMF » Setting xsiSchemaLocation
Setting xsiSchemaLocation [message #1442069] Fri, 10 October 2014 11:15 Go to next message
Eclipse UserFriend
Hi,

Is there a way to programatically setting the schemaLocation of an XMI-file (including the path to the Ecore-file)?
Re: Setting xsiSchemaLocation [message #1442229 is a reply to message #1442069] Fri, 10 October 2014 16:36 Go to previous messageGo to next message
Eclipse UserFriend
http://wiki.eclipse.org/EMF/FAQ#How_can_I_ensure_that_an_xsi:schemaLocation_is_serialized_for_my_packages.3F

As of EMF 2.10, you can use an annotation on the EPakcage so that what's
described in the FAQ is generated from this lookup in GenPackageImpl:

public String getSchemaLocation()
{
String schemaLocation = EcoreUtil.getAnnotation(getEcorePackage(),
EcorePackage.eNS_URI, "schemaLocation");
return schemaLocation == null ? "eNS_URI" :
Literals.toStringLiteral(schemaLocation, getGenModel());
}

On 10/10/2014 5:16 PM, Peter Johnsen wrote:
> Hi,
>
> Is there a way to programatically setting the schemaLocation of an
> XMI-file (including the path to the Ecore-file)?
Re: Setting xsiSchemaLocation [message #1444090 is a reply to message #1442229] Mon, 13 October 2014 12:11 Go to previous message
Eclipse UserFriend
Thank you!
Previous Topic:[CDO] Consistency between XMIID and CDOId
Next Topic:Problems with namespaces when saving EMF model as xml file
Goto Forum:
  


Current Time: Mon Jun 23 06:06:10 EDT 2025

Powered by FUDForum. Page generated in 0.02929 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top