|
1 | 1 | /***************************************************************************** |
2 | 2 | * SysML 2 Pilot Implementation |
3 | | - * Copyright (c) 2019, 2020 Model Driven Solutions, Inc. |
| 3 | + * Copyright (c) 2019-2022 Model Driven Solutions, Inc. |
4 | 4 | * |
5 | 5 | * This program is free software: you can redistribute it and/or modify |
6 | 6 | * it under the terms of the GNU Lesser General Public License as published by |
|
38 | 38 | import org.eclipse.emf.ecore.util.EcoreUtil; |
39 | 39 | import org.eclipse.xtext.resource.IResourceDescription.Manager; |
40 | 40 | import org.eclipse.xtext.resource.IResourceServiceProvider; |
| 41 | +import org.eclipse.xtext.resource.XtextResource; |
41 | 42 | import org.eclipse.xtext.resource.impl.ResourceDescriptionsData; |
42 | 43 | import org.omg.sysml.lang.sysml.SysMLPackage; |
43 | 44 |
|
@@ -68,6 +69,7 @@ protected SysMLUtil() { |
68 | 69 | protected SysMLUtil(ResourceDescriptionsData resourceDescriptionData) { |
69 | 70 | SysMLPackage.eINSTANCE.getName(); |
70 | 71 | this.resourceSet = new ResourceSetImpl(); |
| 72 | + this.resourceSet.getLoadOptions().put(XtextResource.OPTION_ENCODING, "UTF-8"); |
71 | 73 | this.index = resourceDescriptionData; |
72 | 74 | ResourceDescriptionsData.ResourceSetAdapter.installResourceDescriptionsData(this.resourceSet, this.index); |
73 | 75 | } |
@@ -214,7 +216,7 @@ public void readAll(final File file, boolean isInput) { |
214 | 216 | } |
215 | 217 |
|
216 | 218 | /** |
217 | | - * If the given path identifies an file with an allowable extension, then read it. |
| 219 | + * If the given path identifies a file with an allowable extension, then read it. |
218 | 220 | * If the given path is for a directory, then recursively read all the allowable files in it, |
219 | 221 | * directly or indirectly. |
220 | 222 | * |
|
0 commit comments