Example #1
0
 ////////////////////////////////////////////////////////////////////////////
 //--------------------------------- REVISIONS ------------------------------
 // Date       Name                 Tracking #         Description
 // ---------  -------------------  -------------      ----------------------
 // 18JUN2009  James Shen                 	          Initial Creation
 ////////////////////////////////////////////////////////////////////////////
 /**
  * check if this rectangle Intersects given rectangle.
  * @param r the rectangle to be checked.
  * @return true, it Intersects given rectangle.
  */
 public bool Intersects(GeoBounds r)
 {
     return Intersects(r.GetX(), r.GetY(), r.GetWidth(), r.GetHeight());
 }
Example #2
0
 ////////////////////////////////////////////////////////////////////////////
 //--------------------------------- REVISIONS ------------------------------
 // Date       Name                 Tracking #         Description
 // ---------  -------------------  -------------      ----------------------
 // 18JUN2009  James Shen                 	          Initial Creation
 ////////////////////////////////////////////////////////////////////////////
 /**
  * Reset the geo bound with same position and size with given geo bound.
  * @param r the geo bound to copy from.
  */
 public void SetRect(GeoBounds r)
 {
     X = r.GetX();
     Y = r.GetY();
     Width = r.GetWidth();
     Height = r.GetHeight();
 }
Example #3
0
 ////////////////////////////////////////////////////////////////////////////
 //--------------------------------- REVISIONS ------------------------------
 // Date       Name                 Tracking #         Description
 // ---------  -------------------  -------------      ----------------------
 // 18JUN2009  James Shen                 	          Initial Creation
 ////////////////////////////////////////////////////////////////////////////
 /**
  * check if this rectangle Contains given rectangle.
  * @param r the rectangle to be checked.
  * @return true, it totally Contains given rectangle.
  */
 public bool Contains(GeoBounds r)
 {
     return Contains(r.GetX(), r.GetY(), r.GetWidth(), r.GetHeight());
 }
Example #4
0
 ////////////////////////////////////////////////////////////////////////////
 //--------------------------------- REVISIONS ------------------------------
 // Date       Name                 Tracking #         Description
 // ---------  -------------------  -------------      ----------------------
 // 18JUN2009  James Shen                 	          Initial Creation
 ////////////////////////////////////////////////////////////////////////////
 /**
  * Sets the framing rectangle of this <code>IShape</code> to
  * be the specified <code>GeoBounds</code>.  The framing rectangle is
  * used by the subclasses of <code>RectangularShape</code> to define
  * their geometry.
  * @param r the specified <code>GeoBounds</code>
  */
 public void SetFrame(GeoBounds r)
 {
     SetFrame(r.GetX(), r.GetY(), r.GetWidth(), r.GetHeight());
 }