1 /*******************************************************************************
2 * Copyright (c) 2013 Pascal Hirmer.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * and the Apache License 2.0 which both accompany this distribution,
6 * and are available at http://www.eclipse.org/legal/epl-v10.html
7 * and http://www.apache.org/licenses/LICENSE-2.0
10 * Pascal Hirmer - initial API and implementation
11 *******************************************************************************/
13 package org.eclipse.winery.topologymodeler.addons.topologycompleter.helper;
15 import javax.xml.namespace.QName;
17 import org.eclipse.winery.topologymodeler.addons.topologycompleter.topologycompletion.CompletionInterface;
20 * This class contains several constants used by the completion add-on.
22 public class Constants {
25 * Constant for the QName of the "deferred" type.
27 public static final QName DEFERRED_QNAME = new QName("http://www.opentosca.org", "deferred");
30 * Constant for the QName of the "PlaceHolder" type.
32 public static final QName PLACE_HOLDER_QNAME = new QName("http://www.opentosca.org", "PlaceHolder");
35 * Contains possible types of expandable place holders.
37 public enum PlaceHolders {
38 WEBSERVER, DATABASE, OPERATINGSYSTEM, CLOUDPROVIDER;
41 * Overwritten toString() method to return formatted strings.
43 public String toString() {
51 return "OperatingSystem";
53 return "CloudProvider";
61 * The messages returned by the {@link CompletionInterface}
63 public enum CompletionMessages {
64 TOPOLOGYCOMPLETE, USERINTERACTION, STEPBYSTEP, SUCCESS, USERTOPOLOGYSELECTION, FAILURE;
67 * Overwritten toString() method to return formatted strings.
69 public String toString() {
72 case TOPOLOGYCOMPLETE:
73 return "topologyComplete";
75 return "userInteraction";
80 case USERTOPOLOGYSELECTION:
81 return "userTopologySelection";