Fishnet 2.0.1
Framework for Graph-Based Analysis of GIS Vector Data
Loading...
Searching...
No Matches
fishnet::GISFactory Class Reference

#include <GISFactory.hpp>

Static Public Member Functions

static fishnet::Either< Shapefile, std::string > asShapefile (const std::filesystem::path &path)
 Tries to construct ShapeFile handle from path. If path does not point to .shp file, the function tries to convert it to a shapefile.
 
static std::vector< std::filesystem::path > getGISFiles (const std::filesystem::path &path)
 Get all GIS files in a directory/ or a single file from a path.
 

Member Function Documentation

◆ asShapefile()

static fishnet::Either< Shapefile, std::string > fishnet::GISFactory::asShapefile ( const std::filesystem::path &  path)
inlinestatic

Tries to construct ShapeFile handle from path. If path does not point to .shp file, the function tries to convert it to a shapefile.

Parameters
pathpath to the file
Returns
std::expected<Shapefile,std::string>: Containing a shapefile on success or the error as a string

◆ getGISFiles()

static std::vector< std::filesystem::path > fishnet::GISFactory::getGISFiles ( const std::filesystem::path &  path)
inlinestatic

Get all GIS files in a directory/ or a single file from a path.

Parameters
directorysearch directory
Returns
std::vector<std::filesystem::path> list of gis files in that directory

The documentation for this class was generated from the following file: