rs.sol.soloist.server.guiconfiguration.layout
Class XYLayoutData

java.lang.Object
  extended by rs.sol.soloist.server.uml.commonimplementation.runtime._ClassifierInstance
      extended by rs.sol.soloist.server.uml.commonimplementation.runtime._ClassInstance
          extended by rs.sol.soloist.server.javaimpl.runtime.SOLoistClassInstance
              extended by rs.sol.soloist.server.builtindomains.common.ObjectOfClass
                  extended by rs.sol.soloist.server.guiconfiguration.layout.LayoutData
                      extended by rs.sol.soloist.server.guiconfiguration.layout.XYLayoutData
All Implemented Interfaces:
rs.sol.soloist.server.uml.concepts.IElement, IClassifierInstance, IClassInstance, IRTElement

public class XYLayoutData
extends LayoutData

An object meant to be assigned to a widget within a panel with XYLayout, to specify widget's absolute coordinates and size.

For a panel and a label defined like this:

 GUIPanelComponent absolute = GUIPanelComponent.createAbsolute(parent);
 GUILabelComponent label = GUILabelComponent.create(absolute, "Hello");
 
 
an xy layout data information can be specified like this:
 XYLayoutData xyLayoutData = new XYLayoutData();
 xyLayoutData.setX(175);
 xyLayoutData.setY(234);
 xyLayoutData.setSize("100px", "25px");
 label.setLayoutData(xyLayoutData);
 
 
Or shortly:
 XYLayoutData xyLayoutData = XYLayoutData.create(175, 234, "100px", "25px");
 label.setLayoutData(xyLayoutData);
 
 
The same can be achieved with the code bellow, however, in general, attention should be paid when using setXY method and setSize method to ensure that widget is within the absolute panel (that is, a panel with XYLayout):
 label.setXY(175, 234);
 label.setSize("100px", "25px");
 
 

Author:
SOL Expert Group
See Also:
LayoutData

Nested Class Summary
static class XYLayoutData.FQPropertyNames
          Deprecated. Not for public use.
static class XYLayoutData.PROPERTIES
          Deprecated. Not for public use.
 
Nested classes/interfaces inherited from class rs.sol.soloist.server.guiconfiguration.layout.LayoutData
LayoutData.Comparator<T extends LayoutData>, LayoutData.HashFunction<T extends LayoutData>, LayoutData.Unit
 
Field Summary
static IClass CLASSIFIER
          UML class reference
static java.lang.String FQ_TYPE_NAME
          Fully qualified UML class name
 IAttributeValue<Integer> x
          Deprecated. Not for public use.
 IAttributeValue<Integer> y
          Deprecated. Not for public use.
 
Fields inherited from class rs.sol.soloist.server.guiconfiguration.layout.LayoutData
allowedUnits, height, width
 
Constructor Summary
XYLayoutData()
           
XYLayoutData(int x, int y, int width, int height)
          Deprecated. Not for public use.
 
Method Summary
 void constructor()
          The domain-specific constructor of the Classifier.
 void constructor(int x, int y, int width, int height)
          Performs an initialization for this object.
static XYLayoutData create(int x, int y)
          Returns new XYLayoutData object that specifies absolute position of the widget that will have that object assigned to.
static XYLayoutData create(int x, int y, java.lang.String width, java.lang.String height)
          Returns new XYLayoutData object that specifies absolute position and size of the widget that will have that object assigned to.
 rs.sol.soloist.client.common.info.layout.XYLayoutDataInfo createSpecificInfo()
          Creates and returns an empty serializable object of the appropriate LayoutDataInfo sub-class.
 void fillInfo(rs.sol.soloist.client.common.info.layout.LayoutDataInfo info_)
          Fills-in already created LayoutDataInfo object with values of properties of this object.
 int getX()
          Returns the x coordinate of the widget that has this object assigned to.
 int getY()
          Returns the y coordinate of the widget that has this object assigned to.
 void setX(int x)
          Sets the x coordinate of the widget that has this object assigned to.
static void setXY(GUIComponent component, int x, int y)
          Deprecated. Not for public use.
 void setY(int y)
          Sets the y coordinate of the widget that has this object assigned to.
 
Methods inherited from class rs.sol.soloist.server.guiconfiguration.layout.LayoutData
create, create, createInfo, getHeight, getWidth, setHeight, setSize, setSize, setWidth, validate, validateMeasureString, validateUnitString
 
Methods inherited from class rs.sol.soloist.server.builtindomains.common.ObjectOfClass
handle
 
Methods inherited from class rs.sol.soloist.server.javaimpl.runtime.SOLoistClassInstance
destroy, equals, getAssociationEndInstance, getAssociationEndInstances, getAttributeValue, getAttributeValues, getMyClass, getMyID, getSlot, getSlot, getSlots, getUMLClass, hashCode, isMarkedAsDeleted, toString
 
Methods inherited from class rs.sol.soloist.server.uml.commonimplementation.runtime._ClassInstance
accept, accept, exists, getAssociationEndInstance, getAssociationEndInstance, getAssociationEndInstance, getClassifier, hasIdentity, isClassInstance, isDataTypeInstance, isEqualTo, makeClone, markAsDeleted
 
Methods inherited from class rs.sol.soloist.server.uml.commonimplementation.runtime._ClassifierInstance
conformsTo, copySlots, copySlots, destructor, getAttributeValue, getAttributeValue, getAttributeValue, getClassifierFQName, getClassifierUQName, getFirstCommonGeneralizer, getFirstCommonGeneralizerFQName, getFirstCommonGeneralizerUQName, getMElement, getSlot, getSlot, isDirectInstanceOf, isDirectInstanceOf, isInstanceOf, isInstanceOf, isKindOf, isModelElement, isRTElement
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface rs.sol.soloist.server.uml.concepts.runtime.IClassifierInstance
conformsTo, copySlots, copySlots, destructor, getAttributeValue, getAttributeValue, getClassifierFQName, getClassifierUQName, getFirstCommonGeneralizer, getFirstCommonGeneralizerFQName, getFirstCommonGeneralizerUQName, getSlot, getSlot, isDirectInstanceOf, isDirectInstanceOf, isInstanceOf, isInstanceOf
 
Methods inherited from interface rs.sol.soloist.server.uml.concepts.runtime.IRTElement
getMElement
 
Methods inherited from interface rs.sol.soloist.server.uml.concepts.IElement
isKindOf, isModelElement, isRTElement
 

Field Detail

x

@Deprecated
public IAttributeValue<Integer> x
Deprecated. Not for public use.

y

@Deprecated
public IAttributeValue<Integer> y
Deprecated. Not for public use.

FQ_TYPE_NAME

public static final java.lang.String FQ_TYPE_NAME
Fully qualified UML class name

See Also:
Constant Field Values

CLASSIFIER

public static final IClass CLASSIFIER
UML class reference

Constructor Detail

XYLayoutData

@Deprecated
public XYLayoutData(int x,
                               int y,
                               int width,
                               int height)
Deprecated. Not for public use.


XYLayoutData

public XYLayoutData()
Method Detail

constructor

public void constructor(int x,
                        int y,
                        int width,
                        int height)
Performs an initialization for this object. It is internally called during the construction.

Parameters:
x - the x coordinate of the corresponding widget
y - the y coordinate of the corresponding widget
width - the width of the corresponding widget
height - the height of the corresponding widget

constructor

public void constructor()
Description copied from interface: IClassifierInstance
The domain-specific constructor of the Classifier.

Specified by:
constructor in interface IClassifierInstance
Overrides:
constructor in class LayoutData

createSpecificInfo

public rs.sol.soloist.client.common.info.layout.XYLayoutDataInfo createSpecificInfo()
Description copied from class: LayoutData
Creates and returns an empty serializable object of the appropriate LayoutDataInfo sub-class. The returned object must be able to transmit every property of objects of this class from server to clients (browsers).

Overrides:
createSpecificInfo in class LayoutData
Returns:
a LayoutDataInfo sub-class instance

fillInfo

public void fillInfo(rs.sol.soloist.client.common.info.layout.LayoutDataInfo info_)
Description copied from class: LayoutData
Fills-in already created LayoutDataInfo object with values of properties of this object.

Overrides:
fillInfo in class LayoutData
Parameters:
info_ - a LayoutDataInfo sub-class object to be filled-in
See Also:
LayoutData.createSpecificInfo()

create

public static XYLayoutData create(int x,
                                  int y)
Returns new XYLayoutData object that specifies absolute position of the widget that will have that object assigned to.

Parameters:
x - the x coordinate of the widget
y - the y coordinate of the widget
Returns:
new XYLayoutData object that specifies absolute position of the widget

create

public static XYLayoutData create(int x,
                                  int y,
                                  java.lang.String width,
                                  java.lang.String height)
Returns new XYLayoutData object that specifies absolute position and size of the widget that will have that object assigned to.

Parameters:
x - the x coordinate of the widget
y - the y coordinate of the widget
width - the width of the widget
height - the height of the widget
Returns:
new XYLayoutData object that specifies absolute position and size of the widget

setX

public void setX(int x)
Sets the x coordinate of the widget that has this object assigned to.

Parameters:
x - the x coordinate of the widget

setY

public void setY(int y)
Sets the y coordinate of the widget that has this object assigned to.

Parameters:
y - the y coordinate of the widget

getX

public int getX()
Returns the x coordinate of the widget that has this object assigned to.

Returns:
the x coordinate of the widget

getY

public int getY()
Returns the y coordinate of the widget that has this object assigned to.

Returns:
the y coordinate of the widget

setXY

@Deprecated
public static void setXY(GUIComponent component,
                                    int x,
                                    int y)
Deprecated. Not for public use.