View Javadoc
1   /*****************************************************************************
2    * Copyright (c) 2015 CEA LIST and others.
3    * 
4    * All rights reserved. This program and the accompanying materials
5    * are made available under the terms of the Eclipse Public License v1.0
6    * which accompanies this distribution, and is available at
7    * http://www.eclipse.org/legal/epl-v10.html
8    *
9    * Contributors:
10   *   CEA LIST - Initial API and implementation
11   *   
12   *****************************************************************************/
13  
14  package org.eclipse.papyrus.sysml14.diagram.parametric.locator;
15  
16  import org.eclipse.draw2d.IFigure;
17  import org.eclipse.papyrus.infra.gmfdiag.common.utils.PortPositionEnum;
18  import org.eclipse.papyrus.uml.diagram.common.locator.PortPositionLocator;
19  
20  
21  /**
22   * This border locator do not take in account CSS, its always internal.
23   * So For this reason SertPortPosition() has been overloaded.
24   *
25   */
26  public class ParameterPositionLocator extends PortPositionLocator {
27  
28  	/**
29  	 * Constructor.
30  	 *
31  	 * @param parentFigure
32  	 * @param preferredSide
33  	 */
34  	public ParameterPositionLocator(IFigure parentFigure, int preferredSide) {
35  		super(parentFigure, preferredSide);
36  	}
37  
38  	/**
39  	 * @see org.eclipse.papyrus.uml.diagram.common.locator.PortPositionLocator#setPortPosition(java.lang.String)
40  	 *
41  	 * @param position
42  	 */
43  	@Override
44  	public void setPortPosition(String position) {
45  		// Always internal
46  		super.setPortPosition(PortPositionEnum.INSIDE.toString());
47  	}
48  }