Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2012-09-21 15:33:56 +0000
committerEike Stepper2012-09-21 15:33:56 +0000
commitaa8ddb342aa0fa1e95a1b01a3e3a7bed2cb5751e (patch)
tree56139ad43eecbfb278fd27c814390284f46e726c /plugins/org.eclipse.emf.cdo.transfer/src
parentdabe8f109238937b2ba15b593fcd38a39bb8386c (diff)
downloadcdo-aa8ddb342aa0fa1e95a1b01a3e3a7bed2cb5751e.tar.gz
cdo-aa8ddb342aa0fa1e95a1b01a3e3a7bed2cb5751e.tar.xz
cdo-aa8ddb342aa0fa1e95a1b01a3e3a7bed2cb5751e.zip
[353448] Attempt to Modify Historical Revision
https://bugs.eclipse.org/bugs/show_bug.cgi?id=353448
Diffstat (limited to 'plugins/org.eclipse.emf.cdo.transfer/src')
-rw-r--r--plugins/org.eclipse.emf.cdo.transfer/src/org/eclipse/emf/cdo/transfer/TransferTest.java66
1 files changed, 0 insertions, 66 deletions
diff --git a/plugins/org.eclipse.emf.cdo.transfer/src/org/eclipse/emf/cdo/transfer/TransferTest.java b/plugins/org.eclipse.emf.cdo.transfer/src/org/eclipse/emf/cdo/transfer/TransferTest.java
deleted file mode 100644
index e31b3a77e3..0000000000
--- a/plugins/org.eclipse.emf.cdo.transfer/src/org/eclipse/emf/cdo/transfer/TransferTest.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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:
- * Eike Stepper - initial API and implementation
- */
-package org.eclipse.emf.cdo.transfer;
-
-import org.eclipse.emf.cdo.spi.transfer.FileSystemTransferSystem;
-
-import org.eclipse.emf.ecore.xmi.impl.EcoreResourceFactoryImpl;
-
-/**
- * @author Eike Stepper
- * @since 4.2
- */
-public class TransferTest
-{
- public static final CDOTransferSystem FILE_SYSTEM = new FileSystemTransferSystem();
-
- public static void main(String[] args) throws Exception
- {
- CDOTransfer transfer = createTransfer();
- dump(transfer.getRootMapping());
-
- transfer.getModelTransferContext().registerTargetExtension("ecore", new EcoreResourceFactoryImpl());
- transfer.getModelTransferContext().registerTargetExtension("genmodel", new EcoreResourceFactoryImpl());
- transfer.perform();
- }
-
- public static CDOTransfer createTransfer()
- {
- CDOTransfer transfer = new CDOTransfer(FILE_SYSTEM, FILE_SYSTEM);
- transfer.getRootMapping().setRelativePath("C:/develop/transfer");
- transfer.setDefaultTransferType(CDOTransferType.UTF8);
- transfer.getModelTransferContext().registerSourceExtension("ecore", new EcoreResourceFactoryImpl());
- transfer.getModelTransferContext().registerSourceExtension("genmodel", new EcoreResourceFactoryImpl());
-
- CDOTransferMapping mapping = transfer.map("C:/develop/git/cdo/plugins/org.eclipse.emf.cdo.tests.model2");
- mapping.setRelativePath("");
- mapping.getChild(".classpath").setName("my.classpath");
- mapping.getChild(".settings").unmap();
- mapping.getChild("META-INF").setRelativePath("osgi/inf");
- mapping.getChild("bin").unmap();
- mapping.getChild("src").unmap();
-
- CDOTransferMapping model = mapping.getChild("model");
- model.getChild("model2.genmodel").setTransferType(CDOTransferType.UTF8);
- model.getChild("model2.legacy-genmodel").setTransferType(CDOTransferType.BINARY);
-
- return transfer;
- }
-
- protected static void dump(CDOTransferMapping mapping)
- {
- System.out.println(mapping + " --> " + mapping.getTransferType() + " --> " + mapping.getStatus());
- for (CDOTransferMapping child : mapping.getChildren())
- {
- dump(child);
- }
- }
-}

Back to the top