Class PLRuby::Point
In: plruby.rb
Parent: Object

The class PLRuby::Point implement the PostgreSQL type point

Methods

*   +   -   /   ==   []   []=   above?   below?   contained?   from_string   horizontal?   in?   left?   new   on?   right?   vertical?   x   x=   y   y=  

Included Modules

Comparable

Public Class methods

Convert a String (PostgreSQL representation) to a Point

create a Point with the 2 Float object (x, y)

Public Instance methods

scale and rotate self

translate (right, up) self

translate (left, down) self

scale and rotate self

return true if self and other are the same, i.e. self.x == other.x && self.y == other.y

return the coordinate

indice can have the value 0 or 1

set the coordinate

indice can have the value 0 or 1

return true if self is above other, i.e. self.y > other.y

return true if self is below other, i.e. self.y < other.y

return true if self is contained in other

other can be Point, Polygon or a Circle object

return true if self and other are horizontal, i.e. self.y == other.y

return true if self is contained in other

other can be Point, Polygon or a Circle object

return true if self is at the left of other, i.e. self.x < other.x

return true if self is on other

other can be Point, Segment, Box or Path object

return true if self is at the right of other, i.e. self.x > other.x

return true if self and other are vertical, i.e. self.x == other.x

return x for self

set the x value for self

return y for self

set the y value for self

[Validate]