Package org.geotools.vsi
Class VSIUtils
Object
VSIUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
addAlphaToVRT
(Dataset dataset) Add an alpha band to a VRT dataset in-place based on the dataset's mask.static Dataset
datasetToVRT
(Dataset source, File destination) Generate and create a VRT file that links any given GDALDataset
, handling a null response as aIOException
static String
getFileName
(String input) Get a filename from a source locationstatic boolean
isVSILocation
(String input) Determine if an inputString
is a valid VSI-prefixed Virtual File System locationstatic Dataset
openDataset
(String input)
-
Constructor Details
-
VSIUtils
public VSIUtils()
-
-
Method Details
-
isVSILocation
Determine if an inputString
is a valid VSI-prefixed Virtual File System location- Parameters:
input
-String
representation of a virtual location- Returns:
- true if the input is a valid VSI-prefixed Virtual File System location
-
getFileName
Get a filename from a source location- Returns:
- of the filename with extension
-
openDataset
- Parameters:
input
-String
representation of a virtual location- Returns:
Dataset
object containing the layer data- Throws:
IOException
-
addAlphaToVRT
public static void addAlphaToVRT(Dataset dataset) Add an alpha band to a VRT dataset in-place based on the dataset's mask.- Parameters:
dataset
- The dataset object to add an alpha band to.
-
datasetToVRT
Generate and create a VRT file that links any given GDALDataset
, handling a null response as aIOException
- Parameters:
source
- input GDALDataset
destination
- output VRTFile
object- Returns:
- output VRT file as a
Dataset
- Throws:
IOException
-