FlenxApi class

Runtime do alvo Dart: transforma a lista declarativa de ApiEndpoint em rotas shelf, já com os middlewares padrão (JSON, CORS, validação, tratamento de erro) e o envelope/paginação padronizados.

Constructors

FlenxApi(List<ApiEndpoint> endpoints, DbExecutor db, {ApiConfig config = const ApiConfig(), EmailSender? onEmail, TokenVerifier? tokenVerifier})

Properties

config ApiConfig
final
db DbExecutor
final
endpoints List<ApiEndpoint>
final
hashCode int
The hash code for this object.
no setterinherited
onEmail EmailSender?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
tokenVerifier TokenVerifier?
Verificador de token (JWT próprio ou Firebase) para endpoints com auth.
final

Methods

mountOn(Router router) → void
Registra todos os endpoints no router.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited