Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: 4f6c5ed4e0d2839bf40a851650d9bab060e01580 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/*****************************************************************************
 * Copyright (c) 2013 CEA LIST.
 *
 *    
 * 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:
 *  Patrick Tessier (CEA LIST) patrick.tessier@cea.fr - Initial API and implementation
 *
 *****************************************************************************/
package org.eclipse.papyrus.adltool.command;

import java.util.ArrayList;

import org.eclipse.emf.transaction.RecordingCommand;
import org.eclipse.emf.transaction.TransactionalEditingDomain;
import org.eclipse.papyrus.adltool.designer.SimpleArchitectureSnapshotDesigner;
import org.eclipse.uml2.uml.Package;


/**
 * this purpose of this comment is to import all the architecture from the currentworkspace
 *
 */
public class SimpleArchitectureSnapshotCommand extends RecordingCommand {

	protected Package rootPackage;
	protected ArrayList<Object> bundleList=null;

	public SimpleArchitectureSnapshotCommand(TransactionalEditingDomain domain,Package rootPackage, ArrayList<Object> bundleList) {
		super(domain,"Import Bundles", "Model architecture from current workspace");
		this.rootPackage=rootPackage; 
		this.bundleList=bundleList;
	}


	
	@Override
	protected void doExecute() {
		SimpleArchitectureSnapshotDesigner snapshotDesigner= new SimpleArchitectureSnapshotDesigner(rootPackage, bundleList);
		snapshotDesigner.runImportBundles();
	}
	

}

Back to the top