public enum ShpFileType extends Enum<ShpFileType>
Enum Constant and Description |
---|
DBF
the .dbf file, it contains the attribute information of the shapefile
|
FIX
the .fix file, it contains all the Feature IDs for constant time lookup by fid also so that
the fids stay consistent across deletes and adds
|
PRJ
the .prj file, it contains the projection information of the shapefile
|
QIX
the .qix file, A quad tree spatial index of the shapefile.
|
SHP
The .shp file.
|
SHP_XML
the .shp.xml file, it contains the metadata about the shapefile
|
SHX
the .shx file, it contains index information of the existing features
|
Modifier and Type | Field and Description |
---|---|
String |
extension |
String |
extensionWithPeriod |
Modifier and Type | Method and Description |
---|---|
String |
toBase(File file)
Returns the base of the file or null if the file passed in is not of the correct type (has
the correct extension.)
|
String |
toBase(String path)
Returns the base of the file or null if the file passed in is not of the correct type (has
the correct extension.)
|
String |
toBase(URL url)
Returns the base of the file or null if the file passed in is not of the correct type (has
the correct extension.)
|
static ShpFileType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ShpFileType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ShpFileType SHP
public static final ShpFileType DBF
public static final ShpFileType SHX
public static final ShpFileType PRJ
public static final ShpFileType QIX
public static final ShpFileType FIX
public static final ShpFileType SHP_XML
public final String extension
public final String extensionWithPeriod
public static ShpFileType[] values()
for (ShpFileType c : ShpFileType.values()) System.out.println(c);
public static ShpFileType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic String toBase(File file)
For example if the file is c:\shapefiles\file1.dbf. The DBF type will return c:\shapefiles\file1 but all other will return null.
public String toBase(String path)
For example if the file is c:\shapefiles\file1.dbf. The DBF type will return c:\shapefiles\file1 but all other will return null.
Copyright © 1996–2019 Geotools. All rights reserved.