|
|||||||||
上一个类 下一个类 | 框架 无框架 | ||||||||
摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 |
java.lang.Object com.supermap.data.Geometry com.supermap.data.GeoRectangle
public class GeoRectangle
二维矩形几何对象类。
该类主要用于 CAD 图层,是 Geometry
对象的子对象。
构造方法摘要 | |
---|---|
GeoRectangle()
构造一个新的 GeoRectangle 对象。 |
|
GeoRectangle(GeoRectangle geoRectangle)
根据给定的 GeoRectangle 对象构造一个与其完全相同的新对象。 |
|
GeoRectangle(Point2D center,
double width,
double height,
double rotation)
根据指定的参数来构造一个 GeoRectangle 的新对象。 |
|
GeoRectangle(Rectangle2D rectangle,
double rotation)
根据指定的参数来构造一个 GeoRectangle 的新对象。 |
方法摘要 | |
---|---|
GeoRectangle |
clone()
返回当前 GeoRectangle 对象的一个拷贝。 |
GeoLine |
convertToLine()
将二维矩形几何对象转换为线几何对象。 |
GeoRegion |
convertToRegion()
将二维矩形几何对象转换为面几何对象。 |
void |
dispose()
释放该对象所占用的资源。 |
double |
getArea()
返回二维矩形几何对象的面积。 |
Point2D |
getCenter()
返回二维矩形几何对象的中心点。 |
double |
getHeight()
返回二维矩形几何对象的高度,是指矩形对象旋转前的高度。 |
double |
getPerimeter()
返回二维矩形几何对象的周长。 |
double |
getRotation()
返回二维矩形几何对象的旋转角度。 |
double |
getWidth()
返回二维矩形几何对象的宽度,是指矩形对象旋转前的宽度。 |
void |
setCenter(Point2D point2D)
设置二维矩形几何对象的中心点。 |
void |
setEmpty()
此类不支持该接口。 |
void |
setHeight(double value)
设置二维矩形几何对象的高度,是指矩形对象旋转前的高度。 |
void |
setRotation(double value)
设置二维矩形几何对象的旋转角度。 |
void |
setWidth(double value)
设置二维矩形几何对象的宽度,是指矩形对象旋转前的宽度。 |
从类 com.supermap.data.Geometry 继承的方法 |
---|
addCustomGeometryCreatedListener, fromXML, getBounds, getID, getInnerPoint, getStyle, getType, getVariantID, hitTest, isEmpty, mirror, offset, removeCustomGeometryCreatedListener, resize, rotate, setID, setStyle, toXML |
从类 java.lang.Object 继承的方法 |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
构造方法详细信息 |
---|
public GeoRectangle()
public GeoRectangle(GeoRectangle geoRectangle)
geoRectangle
- 给定的 GeoRectangle 对象。public GeoRectangle(Point2D center, double width, double height, double rotation)
center
- 中心点。width
- 旋转前二维矩形几何对象的宽度。height
- 旋转前二维矩形几何对象的高度。rotation
- 二维矩形几何对象的旋转角度。旋转基点为二维矩形几何对象的中心点。public GeoRectangle(Rectangle2D rectangle, double rotation)
rectangle
- 矩形对象。rotation
- 二维矩形几何对象的旋转角度。旋转基点为二维矩形几何对象的中心点。方法详细信息 |
---|
public Point2D getCenter()
public void setCenter(Point2D point2D)
point2D
- 二维矩形几何对象的中心点。public double getWidth()
public void setWidth(double value)
value
- 二维矩形几何对象的宽度。public double getHeight()
public void setHeight(double value)
value
- 二维矩形几何对象的高度。public double getRotation()
二维矩形几何对象通过数据引擎存储后返回的旋转角度,精度为 0.1 度;通过构造函数直接构造的二维矩形几何对象,返回的旋转角度精度不变。
public void setRotation(double value)
value
- 二维矩形几何对象的旋转角度。public double getArea()
public double getPerimeter()
public GeoLine convertToLine()
public GeoRegion convertToRegion()
public void dispose()
Geometry
中的 dispose
public GeoRectangle clone()
java.lang.Object
中的 clone
public void setEmpty()
Geometry
中的 setEmpty
|
|||||||||
上一个类 下一个类 | 框架 无框架 | ||||||||
摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 |