类 Extent

  • 所有已实现的接口:
    java.lang.Cloneable
    直接已知子类:
    Extent3D

    public class Extent
    extends java.lang.Object
    implements java.lang.Cloneable
    Template
    作者:
    Yaqiang Wang
    • 字段概要

      字段 
      修饰符和类型 字段 说明
      double maxX  
      double maxY  
      double minX  
      double minY  
    • 构造器概要

      构造器 
      构造器 说明
      Extent()
      Constructor
      Extent​(double xMin, double xMax, double yMin, double yMax)
      Constructor
      Extent​(Extent aExtent)
      Constructor
    • 字段详细资料

      • minX

        public double minX
      • maxX

        public double maxX
      • minY

        public double minY
      • maxY

        public double maxY
    • 构造器详细资料

      • Extent

        public Extent()
        Constructor
      • Extent

        public Extent​(double xMin,
                      double xMax,
                      double yMin,
                      double yMax)
        Constructor
        参数:
        xMin - Minimum X
        xMax - Maximum X
        yMin - Minimum Y
        yMax - Maximum Y
      • Extent

        public Extent​(Extent aExtent)
        Constructor
        参数:
        aExtent - The extent
    • 方法详细资料

      • getWidth

        public double getWidth()
      • getHeight

        public double getHeight()
      • include

        public boolean include​(Extent bExtent)
        Judge if this extent include another extent
        参数:
        bExtent - extent
        返回:
        is included
      • intersects

        public boolean intersects​(Extent bET)
        Tests whether this extent intersects the second extent.
        参数:
        bET - The second extent
        返回:
        Boolean
      • convertToRectangle

        public java.awt.Rectangle convertToRectangle()
        Convert to rectangle
        返回:
        rectangel
      • getCenterPoint

        public PointD getCenterPoint()
        Get center point
        返回:
        Center point
      • shift

        public Extent shift​(double dx,
                            double dy)
        Shift extent
        参数:
        dx - X shift value
        dy - Y shift value
        返回:
        Shifted extent
      • extend

        public Extent extend​(double ratio)
        Extends extent by ratio
        参数:
        ratio - The ratio
        返回:
        Extended extent
      • extend

        public Extent extend​(double dx,
                             double dy)
        Extends extent
        参数:
        dx - X delta
        dy - Y delta
        返回:
        Extended extent
      • isNaN

        public boolean isNaN()
        Get is NaN or not
        返回:
        Boolean
      • is3D

        public boolean is3D()
        Get is 3D or not
        返回:
        false
      • to3D

        public Extent3D to3D()
        Convert to Extent3D
        返回:
        Extent3D
      • union

        public Extent union​(Extent ex)
        Return union extent
        参数:
        ex - Other extent
        返回:
        Union extent
      • clone

        public java.lang.Object clone()
        Clone
        覆盖:
        clone 在类中 java.lang.Object
        返回:
        Extent object