You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
101 lines
2.0 KiB
101 lines
2.0 KiB
import { |
|
Connection, |
|
ConnectionLicInfo, |
|
TestRequest, |
|
ConnectionPoolType, |
|
SocketResult, |
|
ResultType, |
|
} from './crud.typings'; |
|
|
|
export interface Api { |
|
/** |
|
* 是否是平台 |
|
*/ |
|
isDec: boolean; |
|
|
|
/** |
|
* 获取已添加的数据连接 |
|
*/ |
|
getConnectionList(): Promise<{ data?: Connection[] }>; |
|
|
|
/** |
|
* 获取数据连接lic限制信息 |
|
*/ |
|
getConnectionLicInfo(): Promise<{ data?: ConnectionLicInfo }>; |
|
|
|
/** |
|
* 删除数据连接 |
|
* @param connectionName 数据连接名称 |
|
*/ |
|
deleteConnection(connectionName: string): Promise<ResultType>; |
|
|
|
/** |
|
* 添加数据连接 |
|
* @param data |
|
*/ |
|
addConnection(data: Connection): Promise<ResultType>; |
|
|
|
/** |
|
* 更新数据连接 |
|
*/ |
|
updateConnection(data: Connection): Promise<ResultType>; |
|
|
|
/** |
|
* 测试数据连接 |
|
* @param data |
|
*/ |
|
testConnection(data: Connection): Promise<TestRequest>; |
|
|
|
/** |
|
* 获取连接池数据 |
|
* @param name |
|
*/ |
|
getConnectionPool(name: string): Promise<{ data?: ConnectionPoolType }>; |
|
|
|
/** |
|
* 获取自定义驱动列表 |
|
*/ |
|
getSimpleDriverList(): Promise<{ data?: any[] }>; |
|
|
|
/** |
|
* 获取连接状态 |
|
* @param name |
|
*/ |
|
getConnectionStatus(name: string): Promise<SocketResult>; |
|
|
|
/** |
|
* 关闭连接 |
|
* @param name |
|
*/ |
|
shutdownConnectionStatus(name: string): Promise<SocketResult>; |
|
|
|
/** |
|
* 获取socket连接状态 |
|
*/ |
|
getSocketStatus(): boolean; |
|
|
|
/** |
|
* 判断是否是驱动的错误 |
|
*/ |
|
isDriverError(errorCode: string): boolean; |
|
|
|
/** |
|
* 获取加密后文本 |
|
*/ |
|
getCipher(password: string): string; |
|
|
|
/** |
|
* 获取解密后文本 |
|
*/ |
|
getPlain(cipher: string): string; |
|
|
|
/** |
|
* 获取外链 |
|
*/ |
|
getHyperlink(name: string): string; |
|
|
|
/** |
|
* 获取JNDI数据库类型可用状态 |
|
*/ |
|
getJNDIDatabaseStatus(): Promise<{ data?: boolean }>; |
|
}
|
|
|