Struct postgis::Point [] [src]

pub struct Point<S: SRID = WGS84> {
    pub x: f64,
    pub y: f64,
    // some fields omitted
}

Fields

x: f64 y: f64

Methods

impl<S: SRID> Point<S>
[src]

fn new(x: f64, y: f64) -> Point<S>

impl Point<WGS84>
[src]

fn new_wgs84(x: f64, y: f64) -> Point<WGS84>

fn from_gcj02(x: f64, y: f64) -> Point<WGS84>

fn to_gcj02(&self) -> (f64, f64)

Trait Implementations

impl<S: Clone + SRID> Clone for Point<S>
[src]

fn clone(&self) -> Point<S>

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more

impl<S: Copy + SRID> Copy for Point<S>
[src]

impl<S: SRID> FromSql for Point<S>
[src]

fn accepts(ty: &Type) -> bool

Determines if a value of this type can be created from the specified Postgres Type. Read more

fn from_sql<R: Read>(ty: &Type, raw: &mut R, _ctx: &SessionInfo) -> Result<Point<S>>

Creates a new value of this type from a Reader of the binary format of the specified Postgres Type. Read more

fn from_sql_nullable<R>(ty: &Type, raw: Option<&mut R>, ctx: &SessionInfo) -> Result<Self, Error> where R: Read

Deprecated

fn from_sql_null(ty: &Type, ctx: &SessionInfo) -> Result<Self, Error>

Creates a new value of this type from a NULL SQL value. Read more

impl<S: SRID> ToSql for Point<S>
[src]

fn to_sql_checked(&self, ty: &Type, out: &mut Write, ctx: &SessionInfo) -> Result<IsNull>

An adaptor method used internally by Rust-Postgres. Read more

fn accepts(ty: &Type) -> bool

Determines if a value of this type can be converted to the specified Postgres Type. Read more

fn to_sql<W: Write + ?Sized>(&self, ty: &Type, out: &mut W, _ctx: &SessionInfo) -> Result<IsNull>

Converts the value of self into the binary format of the specified Postgres Type, writing it to out. Read more

impl<S: SRID> Display for Point<S>
[src]

fn fmt(&self, f: &mut Formatter) -> Result

Formats the value using the given formatter.

impl<S: SRID> Debug for Point<S>
[src]

fn fmt(&self, f: &mut Formatter) -> Result

Formats the value using the given formatter.