@tragedy-labs/sprite
Version:
A TypeScript driver for ArcadeDB
31 lines (30 loc) • 1.3 kB
TypeScript
import { SpriteTransaction } from '../transaction/SpriteTransaction.js';
/**
* Static methods for validation of arguments in Sprite.
*/
declare class ArcadeValidation {
static transaction: (trx: SpriteTransaction) => boolean;
static bucketName: (variable: unknown) => boolean;
/**
* Test a string to validate it as a database name in ArcadeDB.
* @param value The string to be tested for existence and non-emptiness
* @returns {boolean} `true` or `false` depending on the presence of a non-empty string
*/
static databaseName: (variable: unknown) => boolean;
static simpleIdentifier: (variable: unknown) => boolean;
/**
* Test a string to validate it as a type name in ArcadeDB.
* @param value The string to be tested for existence and non-emptiness
* @returns {boolean} `true` or `false` depending on the presence of a non-empty string
*/
static typeName: (variable: unknown) => boolean;
/**
* Validate a URL (string).
* @param value The URL to be validated.
* @returns {boolean} `true` or `false` depending on the validity of the URL
*/
static url: (variable: unknown) => boolean;
private static getVariableDescription;
}
export { ArcadeValidation };
export declare const validation: ArcadeValidation;