All pastes #462890 Raw Edit

Untitled

public java v1 · immutable
#462890 ·published 2007-04-28 16:41 UTC
rendered paste body
import org.eclipse.emf.common.util.URI;import org.eclipse.emf.ecore.xmi.impl.XMIResourceImpl;/** * A simple extension of {@link XMIResourceImpl}. * <p> * The only difference to {@link XMIResourceImpl} is that objects that have no IDs will * automatically have UUIDs generated. * </p> */public class UUIDXMIResourceImpl extends XMIResourceImpl {	/**	 * Constructor for UUIDXMIResourceImpl	 */	public UUIDXMIResourceImpl() {		super();	}	/**	 * Constructor for UUIDXMIResourceImpl	 * @param uri the URI for the resource	 */	public UUIDXMIResourceImpl(URI uri) {		super(uri);	}		/**	 * Sets the default encoding to UTF-8.	 */	protected void init() {		encoding = "UTF-8";	}	/**	 * Enable auto-generation of UUIDs for all objects for identification.	 * @return true, indicating that UUIDs should be auto-generated.	 */	protected boolean useUUIDs() {		return true;	}}