UNPKG

@minimaltech/node-infra

Version:

Minimal Technology NodeJS Infrastructure - Loopback 4 Framework

99 lines (98 loc) 3.28 kB
export declare class App { static readonly APPLICATION_NAME: string; static readonly APPLICATION_SECRET: string; static readonly DEFAULT_LOCALE = "en.UTF-8"; static readonly DEFAULT_EXPLORER_PATH = "/explorer"; static readonly DEFAULT_QUERY_LIMIT = 50; } export declare class ConstantValidator<T> { private schemeSet; private constructor(); static fromValues<T>(opts: { values: Array<T> | Set<T>; }): ConstantValidator<T>; isValid(input: T): boolean; } export declare class Formatters { static readonly DATE_TIME_1 = "YYYY-MM-DD HH:mm:ss"; static readonly DATE_TIME_2 = "YYYYMMDDHHmmss"; static readonly DATE_TIME_3 = "YYYY-MM-DD HH:mm:ss.SSS"; static readonly DATE_TIME_4 = "YYYYMMDDHHmmssSSS"; static readonly DATE_1 = "YYYY-MM-DD"; static readonly DATE_2 = "YYYYMMDD"; static readonly TIME_1 = "HH:mm:ss"; static readonly TIME_2 = "HHmmssSSS"; static readonly YEAR_MONTH_1 = "YYYY-MM"; static readonly YEAR_MONTH_2 = "YYYYMM"; } export declare class ApplicationRoles { static readonly API = "api"; } export declare class ResultCodes { static readonly RS_FAIL = 0; static readonly RS_SUCCESS = 1; static readonly RS_UNKNOWN_ERROR = -199; static readonly RS_2: { Ok: number; Created: number; Accepted: number; NonAuthoritativeInformation: number; NoContent: number; ResetContent: number; PartialContent: number; }; static readonly RS_4: { BadRequest: number; Unauthorized: number; PaymentRequired: number; Forbidden: number; NotFound: number; MethodNotAllowed: number; RequestTimeout: number; UnsupportedMediaType: number; UnprocessableEntity: number; }; static readonly RS_5: { InternalServerError: number; NotImplemented: number; }; } export declare class Sorts { static readonly DESC = "desc"; static readonly ASC = "asc"; } export declare class ApplicationRunModes { static readonly MODE_START_UP = "startup"; static readonly MODE_MIGRATE = "migrate"; static readonly MODE_SEED = "seed"; } export declare class EntityRelations { static readonly BELONGS_TO = "belongsTo"; static readonly HAS_ONE = "hasOne"; static readonly HAS_MANY = "hasMany"; static readonly HAS_MANY_THROUGH = "hasManyThrough"; static readonly HAS_MANY_POLYMORPHIC = "hasManyPolymorphic"; static readonly SCHEME_SET: Set<string>; static isValid(type: string): boolean; } export declare class ConfigurationDataTypes { static readonly NUMBER = "NUMBER"; static readonly TEXT = "TEXT"; static readonly BYTE = "BYTE"; static readonly JSON = "JSON"; static readonly BOOLEAN = "BOOLEAN"; static readonly SCHEME_SET: Set<string>; static isValid(orgType: string): boolean; } export declare class UserTypes { static readonly SYSTEM = "SYSTEM"; static readonly LINKED = "LINKED"; static readonly SCHEME_SET: Set<string>; static isValid(orgType: string): boolean; } export declare class MimeTypes { static readonly UNKNOWN = "unknown"; static readonly IMAGE = "image"; static readonly VIDEO = "video"; static readonly TEXT = "text"; }