[][src]Struct geos::ConstGeometry

pub struct ConstGeometry<'a, 'b> { /* fields omitted */ }

only not mutable operations are implemented on it.

Example

use geos::{Geom, Geometry};

let geom = Geometry::new_from_wkt("POLYGON((0 0, 10 0, 10 6, 0 6, 0 0),\
                                           (1 1, 2 1, 2 5, 1 5, 1 1),\
                                           (8 5, 8 4, 9 4, 9 5, 8 5))")
                   .expect("Invalid geometry");
let point_geom = geom
    .get_interior_ring_n(0)
    .expect("failed to get const geometry");

Implementations

impl<'a, 'b> ConstGeometry<'a, 'b>[src]

pub fn get_context_handle(&self) -> &ContextHandle<'a>[src]

Get the context handle of the geometry.

use geos::{ContextInteractions, Geometry};

let point_geom = Geometry::new_from_wkt("POINT (2.5 2.5)").expect("Invalid geometry");
let context = point_geom.get_context_handle();
context.set_notice_message_handler(Some(Box::new(|s| println!("new message: {}", s))));

Trait Implementations

impl<'a, 'd> ContextHandling for ConstGeometry<'a, 'd>[src]

impl<'a, 'd> Geom<'a> for ConstGeometry<'a, 'd>[src]

impl<'a, 'b, 'd, G: Geom<'b>> PartialEq<G> for ConstGeometry<'a, 'd>[src]

impl<'a, 'd> Send for ConstGeometry<'a, 'd>[src]

impl<'a, 'd> Sync for ConstGeometry<'a, 'd>[src]

impl<'a, 'b, 'c> TryFrom<&'b ConstGeometry<'a, 'c>> for Geometry<f64>[src]

type Error = Error

The type returned in the event of a conversion error.

impl<'a, 'c> TryFrom<ConstGeometry<'a, 'c>> for Geometry<f64>[src]

type Error = Error

The type returned in the event of a conversion error.

impl<'a, 'c> TryFrom<ConstGeometry<'a, 'c>> for Geometry[src]

type Error = Error

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<'a, 'b> RefUnwindSafe for ConstGeometry<'a, 'b>

impl<'a, 'b> Unpin for ConstGeometry<'a, 'b> where
    'a: 'b, 

impl<'a, 'b> UnwindSafe for ConstGeometry<'a, 'b>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.