com.supermap.data
类 Toolkit
- java.lang.Object
-
- com.supermap.data.Toolkit
-
- 直接已知子类:
- InternalToolkitChart
public class Toolkit extends Object
工具包类。提供一些辅助计算功能。例如:判断给定值是否为零的重载方法等。
-
-
字段概要
字段 限定符和类型 字段和说明 static double
DBL_MAX_VALUE
static double
DBL_MIN_VALUE
static float
FLT_MAX_VALUE
static float
FLT_MIN_VALUE
-
方法概要
所有方法 静态方法 具体方法 已过时的方法 限定符和类型 方法和说明 static void
clearErrors()
清空错误日志。static boolean
CombineBand(String strName, Datasource datasource, Dataset RedDR, Dataset GreenDR, Dataset BlueDR)
三个单波段数据集合成RGB数据集。static boolean
compactDatasource(Datasource datasource)
对指定的数据源进行紧缩处理,通过紧缩可以使 UDB、UDBX 数据源占用的存储空间变小。static boolean
compress(String[] fileNames, String targetFileName, String pwd, PackageType type)
对目标文件进行压缩。static boolean
convertDatasetCAD2Model(DatasetVector datasetVectorCAD, Datasource datasourceDes, String name)
CAD数据集转换为模型数据集。static String
ConvertDateTimeToString(Date dateValue, EngineType engineType)
static Date
ConvertStringToDate(String strDateTime)
将指定的字符串对象转换为Date。static byte[]
decodeStream(byte[] stream, String pwd)
static boolean
degraRaster(DatasourceConnectionInfo connectionInfo, String strDtName)
对指定的数据源中指定的数据集降级,使得低版本能够打开710创建的栅格数据集。static boolean
deleteDatabase(String strServer, EngineType engineType, String strAdminDB, String strAdminUser, String strAdminPassword, String strDeleteDB)
删除指定数据库static boolean
deleteDataSource(DatasourceConnectionInfo connectionInfo)
删除指定数据源static boolean
draw(Geometry geometry, Resources resources, BufferedImage image)
static boolean
draw(Geometry geometry, Resources resources, Graphics graphics)
已过时。static boolean
drawToPNG(Geometry geometry, Resources resources, String fileName, Dimension size)
根据给定的资源库、将给定的几何对象绘制到 PNG 图像文件中。static byte[]
encodeStream(byte[] stream, String pwd)
static byte[]
extractAttributeValue(String attributeFile, ArrayList<FieldDefine> fieldDefine, String[] fieldsName, String pwd)
用于提取属性文件中指定的属性。static boolean
extractCache2DFile(String sourceFileName, String targetFolderName)
static boolean
extractCacheFile(String sourceFileName, String targetFolderName)
static boolean
extractCacheFile(String sourceFileName, String targetFolderName, String pwd)
static byte[]
extractCacheFile2(String sourceFileName, String pwd)
提取缓存文件,返回原始缓存文件的数据流static byte[]
extractCacheFiles(String[] sourceFileName, String pwd)
提取缓存文件,返回原始缓存文件的数据流static byte[]
extractCacheFiles2(String sourceFileName, String pwd)
static String
FormatWKT(String wkt)
static void
freeMemory()
用于linux释放malloc申请的内存static PrjCoordSys
FromWKT(String str)
static String
GemetryToGeoJson(Geometry geometry)
已过时。static byte[]
GemetryToWKB(Geometry geometry)
已过时。static String
GemetryToWKT(Geometry geometry)
已过时。static Geometry
GeoJsonToGemetry(String strGeoJson)
已过时。static Geometry
GeoJsonToGeometry(String strGeoJson)
GeoJson字符串转换为Geometry,支持点、线、面、多点、多线、多面。static String
GeometryToGeoJson(Geometry geometry)
Geometry转换为GeoJson字符串,支持点、线、面、多点、多线、多面。static byte[]
GeometryToWKB(Geometry geometry)
Geometry转换为WKB二进制流,仅支持点、线、面。static String
GeometryToWKT(Geometry geometry)
Geometry转换为WKT字符串,仅支持点、线、面。static boolean
geoMode3DsToKMZ(ArrayList<GeoModel3D> listGeo, String kmlFullPath)
三维模型对象导出为KMZ文件。static ErrorInfo[]
getAllErrors()
返回所有错误日志。static String
GetCachePath(Dataset dt)
static boolean
getCalcAreaLength()
static byte[]
getData(String path)
根据文件路径获取文件数据。static ArrayList<com.supermap.ProductType>
getDesktopProductTypes()
已过时。static boolean
getDSAutoVacuum()
static boolean
getDtNameAsTableName()
获取数据集名与表名是否一致.static EncodeType[]
getEncodeType(DatasetType type)
传入数据集类型来返回该数据集类型支持的编码类型数组。static String[]
getExtendAttributeList(EngineType engineType)
根据引擎类型获取数据源链接扩展信息列表static ArrayList<ProductType>
GetiServerProducts()
已过时。static ArrayList<com.supermap.ProductType>
GetiServerProductTypes()
已过时。static String
getLastError()
已过时。static ErrorInfo
getLastError2()
返回当前线程最近一条错误信息。static ErrorInfo[]
getLastErrors(int count)
返回从最后一条向前制定条数的的错误日志。static String[]
GetMongoDBNames(String strServer, String strAdminUser, String strAdminPwd)
获取Mongo数据库数据库名列表。static ArrayList<ProductType>
GetSpecifiedProducts()
已过时。static ArrayList<com.supermap.ProductType>
GetSpecifiedProductTypes()
static String[]
getSQLServerDrivers()
获取SQL Server当前机器对应的ODBC管理中所支持的驱动列表。static ArrayList<ProductType>
getTrialProducts()
已过时。static ArrayList<com.supermap.ProductType>
getTrialProductTypes()
static String[]
GetUserTable(Datasource datasource)
获取可作外挂表的用户表名(已作为外挂表的用户表不返回)。static ExtendAttributeInfo[]
getVectorExtendAttributeList(FileFormat filetype)
获取指定文件类型的矢量数据的扩展属性信息列表。static String[]
getWarnings()
返回警告信息。static boolean
Grid2Image(Dataset dt)
Grid转Imagestatic boolean
IdxTileSplitCell(DatasetVector datasetVector, int totalCount)
矢量数据集图幅索引中单个格子记录个数超过指定个数时进行分裂,平均分为4个格子。static boolean
Image2Grid(Dataset dt)
Image转Gridstatic DatasetGrid
image2Grid(DatasetImage image)
影像数据集转换为栅格数据集static boolean
isEscape(int action, boolean isCursorInMapcontrol)
static boolean
isEscape(int action, boolean isCursorInMapcontrol, boolean isCancelMapDrawingByEscKey)
static boolean
isMouseWheelOrKeyPress(boolean isCancelMapDrawingByEscKey)
static boolean
isOldDatasetGroup(Datasource datasource)
判断是否是老版本分组数据。static boolean
isPathExists(String path)
判断路径(文件或目录)是否存在。static boolean
isValidFieldName(String fieldName)
判断一个字段名称是否合法。static boolean
isZero(double value)
判断 value 是否为零值, 使用Environment
里设定的容限。static boolean
isZero(double value, double precision)
判断给定的 value 值是否为零值, 使用 precision 作为判断精度。static boolean
isZero(double value, double minPrecision, double maxPrecision)
判断 value 是否为零值, 使用最小判断精度(minPrecision)和最大判断精度(maxPrecision)作为判断容限。static void
setCalcAreaLength(boolean value)
static void
SetCloudLicenseText(String value)
static void
setDesktopProductTypes(ArrayList<com.supermap.ProductType> pros)
已过时。static void
setDSAutoVacuum(boolean value)
static void
setDtNameAsTableName(boolean value)
设置数据集名与表名是否一致。static void
SetiServerProducts(ArrayList<ProductType> pros)
已过时。static void
SetiServerProductTypes(ArrayList<com.supermap.ProductType> pros)
已过时。static void
SetIsUseCloudLicense(boolean value)
static void
SetSpecifiedProducts(ArrayList<ProductType> pros)
已过时。static void
SetSpecifiedProductTypes(ArrayList<com.supermap.ProductType> pros)
static void
setUserTrademark(String value)
static void
setWatermarkMode(int value)
static String
ToWKT(PrjCoordSys prjCoordSys)
static boolean
unCompress(String srcFileName, String targetFolder, String pwd)
对目标文件进行解压缩。static boolean
vectorReSample(Dataset dataset, QueryParameter queryParameter, Datasource datasource, String[] datasetNames, double[] resolutions, boolean value)
static Geometry
WKBToGemetry(byte[] value)
已过时。static Geometry
WKBToGeometry(byte[] value)
WKB二进制流转换为Geometry,仅支持点、线、面。static Geometry
WKTToGemetry(String strWKT)
已过时。static Geometry
WKTToGeometry(String strWKT)
WKT字符串转换为Geometry,仅支持点、线、面。
-
-
-
字段详细资料
-
DBL_MAX_VALUE
public static final double DBL_MAX_VALUE
- 另请参阅:
- 常量字段值
-
DBL_MIN_VALUE
public static final double DBL_MIN_VALUE
- 另请参阅:
- 常量字段值
-
FLT_MAX_VALUE
public static final float FLT_MAX_VALUE
- 另请参阅:
- 常量字段值
-
FLT_MIN_VALUE
public static final float FLT_MIN_VALUE
- 另请参阅:
- 常量字段值
-
-
方法详细资料
-
SetiServerProductTypes
@Deprecated public static void SetiServerProductTypes(ArrayList<com.supermap.ProductType> pros)
已过时。
-
GetiServerProductTypes
@Deprecated public static ArrayList<com.supermap.ProductType> GetiServerProductTypes()
已过时。
-
setDesktopProductTypes
@Deprecated public static void setDesktopProductTypes(ArrayList<com.supermap.ProductType> pros)
已过时。
-
getDesktopProductTypes
@Deprecated public static ArrayList<com.supermap.ProductType> getDesktopProductTypes()
已过时。
-
SetSpecifiedProductTypes
public static void SetSpecifiedProductTypes(ArrayList<com.supermap.ProductType> pros)
-
GetSpecifiedProductTypes
public static ArrayList<com.supermap.ProductType> GetSpecifiedProductTypes()
-
getTrialProductTypes
public static ArrayList<com.supermap.ProductType> getTrialProductTypes()
-
freeMemory
public static void freeMemory()
用于linux释放malloc申请的内存
-
isZero
public static boolean isZero(double value)
判断 value 是否为零值, 使用Environment
里设定的容限。其中,Environment
类中定义的判断精度有零值判断精度和默认零值判断精度,这里使用的是默认零值判断精度,就是系统给定的零值判断精度。详细信息请参见Environment
类型。- 参数:
value
- 要测试的值。- 返回:
- 如果 value 为零值,返回 true; 否则返回 false。
- 另请参阅:
Environment
-
isZero
public static boolean isZero(double value, double precision)
判断给定的 value 值是否为零值, 使用 precision 作为判断精度。- 参数:
value
- 要测试的值。precision
- 用户给定的零值判断精度。- 返回:
- 一个布尔值,true表示 value 值为零值,false 表示为非零值。
- 另请参阅:
Environment
-
isZero
public static boolean isZero(double value, double minPrecision, double maxPrecision)
判断 value 是否为零值, 使用最小判断精度(minPrecision)和最大判断精度(maxPrecision)作为判断容限。- 参数:
value
- 要测试的值。maxPrecision
- 指定的最大判断精度,即右判断精度,为判断容限的上限。minPrecision
- 指定的最小判断精度,即左判断精度,为判断容限的下限。- 返回:
- 一个布尔值,true表示 value 值为零值,false 表示为非零值。
- 另请参阅:
Environment
-
drawToPNG
public static boolean drawToPNG(Geometry geometry, Resources resources, String fileName, Dimension size)
根据给定的资源库、将给定的几何对象绘制到 PNG 图像文件中。- 参数:
geometry
- 要绘制的几何对象。resources
- 绘制采用的资源库对象。fileName
- PNG 图像文件全路径。size
- 指定绘制图片的大小。- 返回:
- 一个布尔值,表示是否绘制成功。true 表示绘制成功;false 表示失败。
-
draw
public static boolean draw(Geometry geometry, Resources resources, BufferedImage image)
-
draw
@Deprecated public static boolean draw(Geometry geometry, Resources resources, Graphics graphics)
已过时。
-
compactDatasource
public static boolean compactDatasource(Datasource datasource)
对指定的数据源进行紧缩处理,通过紧缩可以使 UDB、UDBX 数据源占用的存储空间变小。注意,紧缩之后几何对象的 SMID 会发生变化,若您使用 SMID 作为其他表的外键的话,需要在紧缩前处理一下,以免对应关系发生变化。
- 参数:
datasource
- 需要进行紧缩的数据源对象,只对 UDB、UDBX 引擎有效,其他引擎返回 false,内存数据源返回 false。- 返回:
- 一个布尔值,表示是否成功完成数据源的紧缩。true 表示压缩成功;false 表示失败。
-
degraRaster
public static boolean degraRaster(DatasourceConnectionInfo connectionInfo, String strDtName)
对指定的数据源中指定的数据集降级,使得低版本能够打开710创建的栅格数据集。- 参数:
connectionInfo
- 数据源连接信息。strDtName
- 指定的数据集名称。- 返回:
- 降级是否成功,true成功,否则失败。
-
getEncodeType
public static EncodeType[] getEncodeType(DatasetType type)
传入数据集类型来返回该数据集类型支持的编码类型数组。- 参数:
type
- 传入的数据集类型。- 返回:
- 该数据集类型支持的编码类型数组。
-
getLastError2
public static ErrorInfo getLastError2()
返回当前线程最近一条错误信息。- 返回:
- 返回当前线程最近一条错误信息。
-
getLastErrors
public static ErrorInfo[] getLastErrors(int count)
返回从最后一条向前制定条数的的错误日志。- 参数:
count
- 指定的从日志的最后一条向前倒数条数。- 返回:
- 从最后一条向前制定条数的的错误日志。
-
clearErrors
public static void clearErrors()
清空错误日志。
-
getAllErrors
public static ErrorInfo[] getAllErrors()
返回所有错误日志。这个方法一般会与
clearErrors()
一起使用,例如在Workspace.open()
操作之前, 先clearErrors()
,执行完Workspace.open()
方法后再getAllErrors()
,这样就能返回所有在Workspace.open()
过程中产生的错误日志了。- 返回:
- 所有错误日志。
-
getWarnings
public static String[] getWarnings()
返回警告信息。- 返回:
- 返回警告信息。
-
getLastError
@Deprecated public static String getLastError()
已过时。
-
extractCache2DFile
public static boolean extractCache2DFile(String sourceFileName, String targetFolderName)
-
extractCacheFile
public static boolean extractCacheFile(String sourceFileName, String targetFolderName)
-
extractCacheFile
public static boolean extractCacheFile(String sourceFileName, String targetFolderName, String pwd)
-
extractCacheFile2
public static byte[] extractCacheFile2(String sourceFileName, String pwd)
提取缓存文件,返回原始缓存文件的数据流- 参数:
sourceFileName
- 原始文件的名称pwd
- 缓存数据的密码- 返回:
- 原始缓存文件的数据流
-
extractCacheFiles
public static byte[] extractCacheFiles(String[] sourceFileName, String pwd)
提取缓存文件,返回原始缓存文件的数据流- 参数:
sourceFileName
- 原始文件的名称pwd
- 缓存数据的密码- 返回:
- 原始缓存文件的数据流
-
compress
public static boolean compress(String[] fileNames, String targetFileName, String pwd, PackageType type)
对目标文件进行压缩。- 参数:
fileNames
- 源文件的全路径名。targetFileName
- 目标文件全路径名。该全路径名为压缩之后新生成的文件名字。pwd
- 指定的密码type
- 指定的压缩类型- 返回:
- 压缩成功返回true,否则返回false。
-
unCompress
public static boolean unCompress(String srcFileName, String targetFolder, String pwd)
对目标文件进行解压缩。- 参数:
srcFileName
- 源文件的全路径名。targetFolder
- 目标文件全路径名。该全路径名为解压缩之后新生成的文件名字。pwd
- 指定的密码- 返回:
- 解压缩成功返回true,否则返回false。
-
isEscape
public static boolean isEscape(int action, boolean isCursorInMapcontrol)
-
isEscape
public static boolean isEscape(int action, boolean isCursorInMapcontrol, boolean isCancelMapDrawingByEscKey)
-
isMouseWheelOrKeyPress
public static boolean isMouseWheelOrKeyPress(boolean isCancelMapDrawingByEscKey)
-
ConvertDateTimeToString
public static String ConvertDateTimeToString(Date dateValue, EngineType engineType)
-
ConvertStringToDate
public static Date ConvertStringToDate(String strDateTime)
将指定的字符串对象转换为Date。- 参数:
strDateTime
- 指定的字符串对象。- 返回:
- 转换成功后的Date。
-
CombineBand
public static boolean CombineBand(String strName, Datasource datasource, Dataset RedDR, Dataset GreenDR, Dataset BlueDR)
三个单波段数据集合成RGB数据集。- 参数:
strName
- 合成RGB数据集的名称。datasource
- 目标数据源。RedDR
- 单波段数据集R。GreenDR
- 单波段数据集G。BlueDR
- 单波段数据集B。- 返回:
- 合成是否成功,成功返回true,否则返回false。
-
GetMongoDBNames
public static String[] GetMongoDBNames(String strServer, String strAdminUser, String strAdminPwd)
获取Mongo数据库数据库名列表。- 参数:
strServer
- 数据库服务名。strAdminUser
- 数据库用户名。strAdminPwd
- 数据库密码。- 返回:
- 数据库列表数组。
-
getSQLServerDrivers
public static String[] getSQLServerDrivers()
获取SQL Server当前机器对应的ODBC管理中所支持的驱动列表。- 返回:
- SQL Server驱动列表。
-
deleteDataSource
public static boolean deleteDataSource(DatasourceConnectionInfo connectionInfo)
删除指定数据源- 参数:
connectionInfo
- 数据源连接参数- 返回:
- 删除是否成功
-
deleteDatabase
public static boolean deleteDatabase(String strServer, EngineType engineType, String strAdminDB, String strAdminUser, String strAdminPassword, String strDeleteDB)
删除指定数据库- 参数:
strServer
- 数据库服务名engineType
- 引擎类型strAdminDB
- 具有管理待删除数据库操作的数据库名strAdminUser
- 管理数据库的用户名strAdminPassword
- 管理数据库的密码strDeleteDB
- 待删除的数据库名- 返回:
- 删除是否成功
-
GetUserTable
public static String[] GetUserTable(Datasource datasource)
获取可作外挂表的用户表名(已作为外挂表的用户表不返回)。- 参数:
datasource
- 目标数据源。- 返回:
- 可作外挂表的用户表名数组。
-
WKTToGemetry
@Deprecated public static Geometry WKTToGemetry(String strWKT)
已过时。
-
WKTToGeometry
public static Geometry WKTToGeometry(String strWKT)
WKT字符串转换为Geometry,仅支持点、线、面。- 参数:
strWKT
- WKT字符串。- 返回:
- Geometry对象。
-
GemetryToWKT
@Deprecated public static String GemetryToWKT(Geometry geometry)
已过时。
-
GeometryToWKT
public static String GeometryToWKT(Geometry geometry)
Geometry转换为WKT字符串,仅支持点、线、面。- 参数:
geometry
- Geometry对象。- 返回:
- WKT字符串。
-
GeoJsonToGemetry
@Deprecated public static Geometry GeoJsonToGemetry(String strGeoJson)
已过时。
-
GeoJsonToGeometry
public static Geometry GeoJsonToGeometry(String strGeoJson)
GeoJson字符串转换为Geometry,支持点、线、面、多点、多线、多面。- 参数:
strGeoJson
- GeoJson字符串。- 返回:
- Geometry对象。
-
GemetryToGeoJson
@Deprecated public static String GemetryToGeoJson(Geometry geometry)
已过时。
-
GeometryToGeoJson
public static String GeometryToGeoJson(Geometry geometry)
Geometry转换为GeoJson字符串,支持点、线、面、多点、多线、多面。- 参数:
geometry
- Geometry对象。- 返回:
- GeoJson字符串。
-
WKBToGemetry
@Deprecated public static Geometry WKBToGemetry(byte[] value)
已过时。
-
WKBToGeometry
public static Geometry WKBToGeometry(byte[] value)
WKB二进制流转换为Geometry,仅支持点、线、面。- 参数:
value
- WKB二进制流。- 返回:
- Geometry对象。
-
GemetryToWKB
@Deprecated public static byte[] GemetryToWKB(Geometry geometry)
已过时。
-
GeometryToWKB
public static byte[] GeometryToWKB(Geometry geometry)
Geometry转换为WKB二进制流,仅支持点、线、面。- 参数:
geometry
- Geometry对象。- 返回:
- WKB二进制流。
-
SetIsUseCloudLicense
public static void SetIsUseCloudLicense(boolean value)
-
SetCloudLicenseText
public static void SetCloudLicenseText(String value)
-
setWatermarkMode
public static void setWatermarkMode(int value)
-
setUserTrademark
public static void setUserTrademark(String value)
-
FromWKT
public static PrjCoordSys FromWKT(String str)
-
ToWKT
public static String ToWKT(PrjCoordSys prjCoordSys)
-
IdxTileSplitCell
public static boolean IdxTileSplitCell(DatasetVector datasetVector, int totalCount)
矢量数据集图幅索引中单个格子记录个数超过指定个数时进行分裂,平均分为4个格子。- 参数:
datasetVector
- 指定的带有图幅索引的矢量数据集。totalCount
- 指定的个数。- 返回:
- 分裂是否成功,成功返回true,失败返回false。
-
isValidFieldName
public static boolean isValidFieldName(String fieldName)
判断一个字段名称是否合法。判断一个字段名称是否含有非法字符,以及是否是关键字。- 参数:
fieldName
- 字段名称- 返回:
- 合法的字段名称返回 true,否则返回 false。
-
Grid2Image
public static boolean Grid2Image(Dataset dt)
Grid转Image- 参数:
- -
- 返回:
-
Image2Grid
public static boolean Image2Grid(Dataset dt)
Image转Grid- 参数:
dt
- 数据集- 返回:
- 布尔值
-
image2Grid
public static DatasetGrid image2Grid(DatasetImage image)
影像数据集转换为栅格数据集- 参数:
image
- DatasetImage- 返回:
- DatasetGrid or throw not supported
-
geoMode3DsToKMZ
public static boolean geoMode3DsToKMZ(ArrayList<GeoModel3D> listGeo, String kmlFullPath)
三维模型对象导出为KMZ文件。- 参数:
listGeo
- 指定的三维模型对象列表。kmlFullPath
- 指定KMZ文件的保存路径。- 返回:
- 一个布尔值,true表示导出成功,false表示导出失败。
-
convertDatasetCAD2Model
public static boolean convertDatasetCAD2Model(DatasetVector datasetVectorCAD, Datasource datasourceDes, String name)
CAD数据集转换为模型数据集。- 参数:
datasetVectorCAD
- 待转换的CAD数据集。datasourceDes
- 结果数据源。name
- 结果数据集的名称。- 返回:
- 一个布尔值,true表示转换成功,false表示转换失败。
-
encodeStream
public static byte[] encodeStream(byte[] stream, String pwd)
-
decodeStream
public static byte[] decodeStream(byte[] stream, String pwd)
-
setDtNameAsTableName
public static void setDtNameAsTableName(boolean value)
设置数据集名与表名是否一致。- 参数:
value
- 一个布尔值,true表示设置数据集名与表名一致,false表示设置数据集名与表名不一致。
-
getDtNameAsTableName
public static boolean getDtNameAsTableName()
获取数据集名与表名是否一致.- 返回:
- 一个布尔值,true表示数据集名与表名一致,false表示数据集名与表名不一致。
-
setDSAutoVacuum
public static void setDSAutoVacuum(boolean value)
-
getDSAutoVacuum
public static boolean getDSAutoVacuum()
-
setCalcAreaLength
public static void setCalcAreaLength(boolean value)
-
getCalcAreaLength
public static boolean getCalcAreaLength()
-
vectorReSample
public static boolean vectorReSample(Dataset dataset, QueryParameter queryParameter, Datasource datasource, String[] datasetNames, double[] resolutions, boolean value)
-
extractAttributeValue
public static byte[] extractAttributeValue(String attributeFile, ArrayList<FieldDefine> fieldDefine, String[] fieldsName, String pwd)
用于提取属性文件中指定的属性。- 参数:
attributeFile
- 属性文件fieldDefine
- 对属性文件进行定义fieldsName
- 文件名称pwd
- 密码- 返回:
- 字节
-
getExtendAttributeList
public static String[] getExtendAttributeList(EngineType engineType)
根据引擎类型获取数据源链接扩展信息列表- 参数:
engineType
- 引擎类型- 返回:
- 扩展信息列表
-
getVectorExtendAttributeList
public static ExtendAttributeInfo[] getVectorExtendAttributeList(FileFormat filetype)
获取指定文件类型的矢量数据的扩展属性信息列表。扩展属性信息列表
ExtendAttributeInfo
中包含读取矢量文件的一些转换参数,可以在数据源连接信息DatasourceConnectionInfo
中设置这些参数。- 参数:
filetype
- 文件类型。- 返回:
- 扩展属性信息对象列表。
- 另请参阅:
ExtendAttributeInfo
,FileFormat
,DatasourceConnectionInfo.setExtendAttribute(Map)
- 示范代码:
- 以下示范获取矢量文件的扩展属性信息列表,并设置这些参数后连接矢量文件。
-
isPathExists
public static boolean isPathExists(String path)
判断路径(文件或目录)是否存在。 使用底层C++判断,可以用于判断GDAL虚拟文件系统支持的路径(/vis开头),例如对象存储的/vsis3的路径。- 参数:
path
- 路径- 返回:
- 是否存在
-
getData
public static byte[] getData(String path)
根据文件路径获取文件数据。- 参数:
path
- 路径- 返回:
- byte[]
-
isOldDatasetGroup
public static boolean isOldDatasetGroup(Datasource datasource)
判断是否是老版本分组数据。 使用底层C++判断, 用于海图区分新老版本。- 参数:
datasource
- 数据源- 返回:
- 是否是老版本
-
SetiServerProducts
@Deprecated public static void SetiServerProducts(ArrayList<ProductType> pros)
已过时。
-
GetiServerProducts
@Deprecated public static ArrayList<ProductType> GetiServerProducts()
已过时。
-
SetSpecifiedProducts
@Deprecated public static void SetSpecifiedProducts(ArrayList<ProductType> pros)
已过时。
-
GetSpecifiedProducts
@Deprecated public static ArrayList<ProductType> GetSpecifiedProducts()
已过时。
-
getTrialProducts
@Deprecated public static ArrayList<ProductType> getTrialProducts()
已过时。
-
-
Copyright © 2021–2024 SuperMap. All rights reserved.