Skip to main content

GeoOperations

Trait GeoOperations 

Source
pub trait GeoOperations {
    // Required methods
    fn get_gps<P: AsRef<Path>>(&self, path: P) -> Result<Option<GpsCoordinate>>;
    fn set_gps<P: AsRef<Path>>(
        &self,
        path: P,
        coord: &GpsCoordinate,
    ) -> Result<()>;
    fn remove_gps<P: AsRef<Path>>(&self, path: P) -> Result<()>;
    fn geotag_from_track<P: AsRef<Path>, Q: AsRef<Path>>(
        &self,
        image: P,
        track_file: Q,
    ) -> Result<()>;
    fn generate_tracklog<P: AsRef<Path>, Q: AsRef<Path>>(
        &self,
        images: &[P],
        output: Q,
    ) -> Result<()>;
    fn reverse_geocode<P: AsRef<Path>>(
        &self,
        coord: &GpsCoordinate,
    ) -> Result<GeocodeResult>;
}
Expand description

地理信息操作 trait

Required Methods§

Source

fn get_gps<P: AsRef<Path>>(&self, path: P) -> Result<Option<GpsCoordinate>>

获取文件的 GPS 坐标

Source

fn set_gps<P: AsRef<Path>>(&self, path: P, coord: &GpsCoordinate) -> Result<()>

设置文件的 GPS 坐标

Source

fn remove_gps<P: AsRef<Path>>(&self, path: P) -> Result<()>

删除 GPS 信息

Source

fn geotag_from_track<P: AsRef<Path>, Q: AsRef<Path>>( &self, image: P, track_file: Q, ) -> Result<()>

从 GPS 轨迹文件地理标记

Source

fn generate_tracklog<P: AsRef<Path>, Q: AsRef<Path>>( &self, images: &[P], output: Q, ) -> Result<()>

生成 GPS 轨迹文件

Source

fn reverse_geocode<P: AsRef<Path>>( &self, coord: &GpsCoordinate, ) -> Result<GeocodeResult>

反向地理编码

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§