mirror of
https://github.com/arthur-pbty/portfolio2023.git
synced 2026-06-04 07:46:21 +02:00
63 lines
1.4 KiB
TypeScript
63 lines
1.4 KiB
TypeScript
/// <reference types="@adonisjs/application/build/adonis-typings" />
|
|
import { ApplicationContract } from '@ioc:Adonis/Core/Application';
|
|
/**
|
|
* Database service provider
|
|
*/
|
|
export default class DatabaseServiceProvider {
|
|
protected app: ApplicationContract;
|
|
constructor(app: ApplicationContract);
|
|
static needsApplication: boolean;
|
|
/**
|
|
* Register the database binding
|
|
*/
|
|
private registerDatabase;
|
|
/**
|
|
* Registers ORM
|
|
*/
|
|
private registerOrm;
|
|
/**
|
|
* Registers schema class
|
|
*/
|
|
private registerSchema;
|
|
/**
|
|
* Registers schema class
|
|
*/
|
|
private registerFactory;
|
|
/**
|
|
* Registers schema class
|
|
*/
|
|
private registerBaseSeeder;
|
|
/**
|
|
* Registers the health checker
|
|
*/
|
|
private registerHealthChecker;
|
|
/**
|
|
* Register the migrator used for database migration
|
|
*/
|
|
private registerMigrator;
|
|
/**
|
|
* Extends the validator by defining validation rules
|
|
*/
|
|
private defineValidationRules;
|
|
/**
|
|
* Defines REPL bindings
|
|
*/
|
|
private defineReplBindings;
|
|
/**
|
|
* Define test utilities for database
|
|
*/
|
|
private defineTestUtils;
|
|
/**
|
|
* Called when registering providers
|
|
*/
|
|
register(): void;
|
|
/**
|
|
* Called when all bindings are in place
|
|
*/
|
|
boot(): void;
|
|
/**
|
|
* Gracefully close connections during shutdown
|
|
*/
|
|
shutdown(): Promise<void>;
|
|
}
|