code: private Grammar cloneGrammarIntoNewResourceSet(Grammar original) {
  		Resource originalResource = original.eResource();
  		ResourceSet clonedResourceSet = EcoreUtil2.clone(new XtextResourceSet(), originalResource.getResourceSet());
  		Resource clonedResource = clonedResourceSet.getResource(originalResource.getURI(), false);
  		Grammar clonedGrammar = (Grammar) clonedResource.getContents().get(0);
  		return clonedGrammar;
  	}
docs: Create a clone of the original grammar. The clone will not refer to a node model.