Copyright 2009,2010, Lapetus Systems Ltd. (All rights reserved)

com.lapetus_ltd.api.db.xml.types
Class TLptsDimensionType

java.lang.Object
  extended by com.lapetus_ltd._2009.xml.types.XLptsDimensionType
      extended by com.lapetus_ltd.api.db.xml.types.TLptsDimensionType

public class TLptsDimensionType
extends XLptsDimensionType

Class Description : This is used for the dimensions of the windows in the workspace.

This is the wrapper class for XLptsDimentionType.
The values in this class are used by the workspace for storing the screen and splitter information.

$LastChangedRevision: 1190 $
$LastChangedDate:: 2010-11-17 13:21:35#$


Field Summary
 
Fields inherited from class com.lapetus_ltd._2009.xml.types.XLptsDimensionType
height, maximized, minimized, width, x, y
 
Constructor Summary
TLptsDimensionType(java.lang.Integer x, java.lang.Integer y, java.lang.Integer w, java.lang.Integer h, boolean isMaximized, boolean isMinimized)
           Use this to construct the TLptsDimensionType.
TLptsDimensionType(XLptsDimensionType dimensionType)
           Use this to construct or duplicate an XLptsDimensionType from another (probably just read from a file).
 
Method Summary
 boolean equals(java.lang.Object obj)
           Check for equal TLptsDimensionType objects.
 
Methods inherited from class com.lapetus_ltd._2009.xml.types.XLptsDimensionType
getHeight, getWidth, getX, getY, isMaximized, isMinimized, setHeight, setMaximized, setMinimized, setWidth, setX, setY
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TLptsDimensionType

public TLptsDimensionType(java.lang.Integer x,
                          java.lang.Integer y,
                          java.lang.Integer w,
                          java.lang.Integer h,
                          boolean isMaximized,
                          boolean isMinimized)

Use this to construct the TLptsDimensionType.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : Use this Constructor to set main screen dimensions and if the application is maximized or minimized.

Example :

 

TLptsDBWorkspaceType workSpace,ws; ws = loadWorkSpace(); if(ws==null) { int x = 89; int y = 41; int width = 1102; int height = 943; boolean minimized = false; boolean maximized = true; TLptsDimensionType dt = new TLptsDimensionType(x,y,width,height,maximized,minimized); workSpace.workSpace.setMainScreenDimensions(dt); ... } else { workSpace.setMainScreenDimensions(new TLptsDimensionType(ws.getMainScreenDimensions())); }

Parameters:
x - the horizontal pixel where the main frame is set
y - the vertical pixel where the main frame is set
w - the width of the main frame
h - the height of the main frame
isMaximized - if the frame is maximized
isMinimized - if the frame is minimized

TLptsDimensionType

public TLptsDimensionType(XLptsDimensionType dimensionType)

Use this to construct or duplicate an XLptsDimensionType from another (probably just read from a file).

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : Use this function every time you need to copy or instantiate a type XLptsDimensionType class.

Example :

 

TLptsDBWorkspaceType workSpace,ws; ws = loadWorkSpace(); if(ws==null) { int x = 89; int y = 41; int width = 1102; int height = 943; boolean minimized = false; boolean maximized = true; TLptsDimensionType dt = new TLptsDimensionType(x,y,width,height,maximized,minimized); workSpace.workSpace.setMainScreenDimensions(dt); ... } else { workSpace.setMainScreenDimensions(new TLptsDimensionType(ws.getMainScreenDimensions())); }

Parameters:
dimensionType - The dimension type to use as a template for this creation.
Method Detail

equals

public boolean equals(java.lang.Object obj)

Check for equal TLptsDimensionType objects.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : n/a

Notes : Use this to compare two TLptsDimensionType objects by X, Y, Width, Height.

Example :

 

TLptsDimensionType dt1 = new TLptsDimensionType(85,46,1050,720); TLptsDimensionType dt2 = new TLptsDimensionType(85,46,1050,480); return dt1.equals(dt2);

Result : false

Overrides:
equals in class java.lang.Object
Parameters:
obj - the dimension type
Returns:
true if they are equal, else false.


Copyright 2009,2010, Lapetus Systems Ltd. (All rights reserved)