Package cz.vutbr.fit.layout.segm.op
Class Separator
- java.lang.Object
-
- cz.vutbr.fit.layout.model.Rectangular
-
- cz.vutbr.fit.layout.segm.op.Separator
-
- All Implemented Interfaces:
Rect
,Comparable<Separator>
public class Separator extends Rectangular implements Comparable<Separator>
- Author:
- radek A horizontal or vertical visual separator.
-
-
Field Summary
Fields Modifier and Type Field Description protected Area
area1
Left (top) separated area node (if any)protected Area
area2
Bottom (right) separated area node (if any)static short
BOXH
static short
BOXV
static short
HORIZONTAL
protected short
type
Separator type -- either HORIZONTAL, VERTICAL or BOXstatic short
VERTICAL
-
Fields inherited from class cz.vutbr.fit.layout.model.Rectangular
x1, x2, y1, y2
-
-
Constructor Summary
Constructors Constructor Description Separator(short type, int x1, int y1, int x2, int y2)
Separator(short type, Rectangular rect)
Separator(Separator orig)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(Separator other)
Area
getArea1()
Area
getArea2()
short
getType()
int
getWeight()
Separator
hsplit(Separator other)
boolean
isBoxSep()
boolean
isHorizontal()
boolean
isVertical()
void
setArea1(Area area1)
void
setArea2(Area area2)
void
setType(short type)
String
toString()
Separator
vsplit(Separator other)
-
Methods inherited from class cz.vutbr.fit.layout.model.Rectangular
contains, copy, encloses, enclosesX, enclosesY, equals, expandToEnclose, getArea, getHeight, getWidth, getX1, getX2, getY1, getY2, hsplit, intersection, intersects, intersectsX, intersectsY, isEmpty, midX, midY, move, replaceX, replaceY, setX1, setX2, setY1, setY2, union, vsplit
-
-
-
-
Field Detail
-
HORIZONTAL
public static final short HORIZONTAL
- See Also:
- Constant Field Values
-
VERTICAL
public static final short VERTICAL
- See Also:
- Constant Field Values
-
BOXH
public static final short BOXH
- See Also:
- Constant Field Values
-
BOXV
public static final short BOXV
- See Also:
- Constant Field Values
-
type
protected short type
Separator type -- either HORIZONTAL, VERTICAL or BOX
-
area1
protected Area area1
Left (top) separated area node (if any)
-
area2
protected Area area2
Bottom (right) separated area node (if any)
-
-
Constructor Detail
-
Separator
public Separator(short type, int x1, int y1, int x2, int y2)
-
Separator
public Separator(Separator orig)
-
Separator
public Separator(short type, Rectangular rect)
-
-
Method Detail
-
getType
public short getType()
-
setType
public void setType(short type)
-
isBoxSep
public boolean isBoxSep()
-
getArea1
public Area getArea1()
-
setArea1
public void setArea1(Area area1)
-
getArea2
public Area getArea2()
-
setArea2
public void setArea2(Area area2)
-
toString
public String toString()
- Overrides:
toString
in classRectangular
-
compareTo
public int compareTo(Separator other)
- Specified by:
compareTo
in interfaceComparable<Separator>
-
isHorizontal
public boolean isHorizontal()
-
isVertical
public boolean isVertical()
-
getWeight
public int getWeight()
-
-