Upgraded lints to 3.0.0
This commit is contained in:
parent
cfe1ef8189
commit
d4794dbbd1
48 changed files with 149 additions and 113 deletions
|
@ -1,5 +1,9 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
name: angel3_auth
|
name: angel3_auth
|
||||||
description: A complete authentication plugin for Angel3. Includes support for stateless JWT tokens, Basic Auth, and more.
|
description: A complete authentication plugin for Angel3. Includes support for stateless JWT tokens, Basic Auth, and more.
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/auth
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/auth
|
||||||
environment:
|
environment:
|
||||||
|
@ -19,7 +19,7 @@ dev_dependencies:
|
||||||
http: ^1.0.0
|
http: ^1.0.0
|
||||||
io: ^1.0.0
|
io: ^1.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_container:
|
# angel3_container:
|
||||||
# path: ../container/angel_container
|
# path: ../container/angel_container
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed linter warnings
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -48,8 +48,7 @@ class RestService<Id, Data> extends BaseAngelService<Id, Data> {
|
||||||
|
|
||||||
final Type? type;
|
final Type? type;
|
||||||
|
|
||||||
RestService(http.BaseClient client, BaseAngelClient app, url, this.type)
|
RestService(super.client, super.app, super.url, this.type);
|
||||||
: super(client, app, url);
|
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Data? deserialize(x) {
|
Data? deserialize(x) {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_client
|
name: angel3_client
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: A browser, mobile and command line based client that supports querying Angel3 servers
|
description: A browser, mobile and command line based client that supports querying Angel3 servers
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/client
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/client
|
||||||
|
@ -24,7 +24,7 @@ dev_dependencies:
|
||||||
build_runner: ^2.4.0
|
build_runner: ^2.4.0
|
||||||
build_web_compilers: ^4.0.0
|
build_web_compilers: ^4.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_container:
|
# angel3_container:
|
||||||
# path: ../container/angel_container
|
# path: ../container/angel_container
|
||||||
|
|
|
@ -1,5 +1,9 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_configuration
|
name: angel3_configuration
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: Automatic YAML application configuration loader for Angel 3, with .env support.
|
description: Automatic YAML application configuration loader for Angel 3, with .env support.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/configuration
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/configuration
|
||||||
|
@ -14,7 +14,7 @@ dependencies:
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
io: ^1.0.0
|
io: ^1.0.0
|
||||||
logging: ^1.2.0
|
logging: ^1.2.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
belatuk_pretty_logging: ^6.0.0
|
belatuk_pretty_logging: ^6.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed analyser warnings
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_container
|
name: angel3_container
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: Angel3 hierarchical DI container, and pluggable backends for reflection.
|
description: Angel3 hierarchical DI container, and pluggable backends for reflection.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/container/angel_container
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/container/angel_container
|
||||||
|
@ -10,4 +10,4 @@ dependencies:
|
||||||
quiver: ^3.2.0
|
quiver: ^3.2.0
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
|
@ -116,7 +116,7 @@ class Pokemon {
|
||||||
}
|
}
|
||||||
|
|
||||||
class KantoPokemon extends Pokemon {
|
class KantoPokemon extends Pokemon {
|
||||||
KantoPokemon(String name, PokemonType type) : super(name, type);
|
KantoPokemon(super.name, super.type);
|
||||||
}
|
}
|
||||||
|
|
||||||
enum PokemonType { water, fire, grass, ice, poison, flying }
|
enum PokemonType { water, fire, grass, ice, poison, flying }
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed analyser warnings
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
|
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
|
||||||
[![License](https://img.shields.io/github/license/dukefirehawk/angel)](https://github.com/dukefirehawk/angel/tree/master/packages/container/angel3_container_generator/LICENSE)
|
[![License](https://img.shields.io/github/license/dukefirehawk/angel)](https://github.com/dukefirehawk/angel/tree/master/packages/container/angel3_container_generator/LICENSE)
|
||||||
|
|
||||||
An alternative container for Angel3 that uses `reflectable` package instead of `dart:mirrors` for reflection. However, `reflectable` has much limited relfection capabilities when compared to `dart:mirrors`.
|
An alternative container for Angel3 that uses `reflectable` package instead of `dart:mirrors` for reflection. However, `reflectable` has more limited relfection capabilities when compared to `dart:mirrors`.
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
|
@ -26,6 +26,7 @@ An alternative container for Angel3 that uses `reflectable` package instead of `
|
||||||
|
|
||||||
## Known limitation
|
## Known limitation
|
||||||
|
|
||||||
|
* `analyser` 6.x is not supported due to `reflectable`
|
||||||
* Reflection on functions/closures is not supported
|
* Reflection on functions/closures is not supported
|
||||||
* Reflection on private declarations is not supported
|
* Reflection on private declarations is not supported
|
||||||
* Reflection on generic type is not supported
|
* Reflection on generic type is not supported
|
||||||
|
|
|
@ -426,7 +426,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
||||||
},
|
},
|
||||||
4,
|
4,
|
||||||
10,
|
10,
|
||||||
const <int>[],
|
const <int>[15],
|
||||||
const [],
|
const [],
|
||||||
null,
|
null,
|
||||||
(o) => false,
|
(o) => false,
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_container_generator
|
name: angel3_container_generator
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: Codegen support for using pkg:reflectable with pkg:angel3_container.
|
description: Codegen support for using pkg:reflectable with pkg:angel3_container.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/container/angel_container_generator
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/container/angel_container_generator
|
||||||
|
@ -12,7 +12,7 @@ dev_dependencies:
|
||||||
build_runner: ^2.4.0
|
build_runner: ^2.4.0
|
||||||
build_test: ^2.1.0
|
build_test: ^2.1.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_container:
|
# angel3_container:
|
||||||
# path: ../angel_container
|
# path: ../angel_container
|
||||||
|
|
|
@ -142,7 +142,7 @@ class Pokemon {
|
||||||
|
|
||||||
@contained
|
@contained
|
||||||
class KantoPokemon extends Pokemon {
|
class KantoPokemon extends Pokemon {
|
||||||
KantoPokemon(String name, PokemonType type) : super(name, type);
|
KantoPokemon(super.name, super.type);
|
||||||
}
|
}
|
||||||
|
|
||||||
@contained
|
@contained
|
||||||
|
|
|
@ -641,7 +641,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
||||||
},
|
},
|
||||||
2,
|
2,
|
||||||
18,
|
18,
|
||||||
const <int>[],
|
const <int>[23],
|
||||||
const [],
|
const [],
|
||||||
null,
|
null,
|
||||||
(o) => false,
|
(o) => false,
|
||||||
|
@ -3598,7 +3598,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
||||||
null),
|
null),
|
||||||
r.ParameterMirrorImpl(
|
r.ParameterMirrorImpl(
|
||||||
r'name',
|
r'name',
|
||||||
134348806,
|
134349830,
|
||||||
70,
|
70,
|
||||||
const prefix0.ContainedReflectable(),
|
const prefix0.ContainedReflectable(),
|
||||||
15,
|
15,
|
||||||
|
@ -3610,7 +3610,7 @@ final _data = <r.Reflectable, r.ReflectorData>{
|
||||||
null),
|
null),
|
||||||
r.ParameterMirrorImpl(
|
r.ParameterMirrorImpl(
|
||||||
r'type',
|
r'type',
|
||||||
134348806,
|
134349830,
|
||||||
70,
|
70,
|
||||||
const prefix0.ContainedReflectable(),
|
const prefix0.ContainedReflectable(),
|
||||||
6,
|
6,
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.3.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed linter warnings
|
||||||
|
|
||||||
## 8.2.0
|
## 8.2.0
|
||||||
|
|
||||||
* Add `addResponseHeader` to `AngelHttp` to add headers to HTTP default response
|
* Add `addResponseHeader` to `AngelHttp` to add headers to HTTP default response
|
||||||
|
|
|
@ -1,6 +1,4 @@
|
||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
import 'request_context.dart';
|
|
||||||
import 'response_context.dart';
|
|
||||||
import 'service.dart';
|
import 'service.dart';
|
||||||
|
|
||||||
/// An easy helper class to create one-off services without having to create an entire class.
|
/// An easy helper class to create one-off services without having to create an entire class.
|
||||||
|
@ -22,8 +20,7 @@ class AnonymousService<Id, Data> extends Service<Id, Data> {
|
||||||
FutureOr<Data> Function(Id id, Data data, [Map<String, dynamic>? params])?
|
FutureOr<Data> Function(Id id, Data data, [Map<String, dynamic>? params])?
|
||||||
update,
|
update,
|
||||||
FutureOr<Data> Function(Id id, [Map<String, dynamic>? params])? remove,
|
FutureOr<Data> Function(Id id, [Map<String, dynamic>? params])? remove,
|
||||||
FutureOr<Data> Function(RequestContext, ResponseContext)? readData})
|
super.readData}) {
|
||||||
: super(readData: readData) {
|
|
||||||
_index = index;
|
_index = index;
|
||||||
_read = read;
|
_read = read;
|
||||||
_create = create;
|
_create = create;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
part of angel_framework.http.request_context;
|
part of 'request_context.dart';
|
||||||
|
|
||||||
const List<Type> _primitiveTypes = [String, int, num, double, Null];
|
const List<Type> _primitiveTypes = [String, int, num, double, Null];
|
||||||
|
|
||||||
|
|
|
@ -141,40 +141,26 @@ class Parameter {
|
||||||
|
|
||||||
/// Shortcut for declaring a request header [Parameter].
|
/// Shortcut for declaring a request header [Parameter].
|
||||||
class Header extends Parameter {
|
class Header extends Parameter {
|
||||||
const Header(String header, {match, defaultValue, bool required = true})
|
const Header(String header, {super.match, super.defaultValue, super.required})
|
||||||
: super(
|
: super(header: header);
|
||||||
header: header,
|
|
||||||
match: match,
|
|
||||||
defaultValue: defaultValue,
|
|
||||||
required: required);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Shortcut for declaring a request session [Parameter].
|
/// Shortcut for declaring a request session [Parameter].
|
||||||
class Session extends Parameter {
|
class Session extends Parameter {
|
||||||
const Session(String session, {match, defaultValue, bool required = true})
|
const Session(String session,
|
||||||
: super(
|
{super.match, super.defaultValue, super.required})
|
||||||
session: session,
|
: super(session: session);
|
||||||
match: match,
|
|
||||||
defaultValue: defaultValue,
|
|
||||||
required: required);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Shortcut for declaring a request query [Parameter].
|
/// Shortcut for declaring a request query [Parameter].
|
||||||
class Query extends Parameter {
|
class Query extends Parameter {
|
||||||
const Query(String query, {match, defaultValue, bool required = true})
|
const Query(String query, {super.match, super.defaultValue, super.required})
|
||||||
: super(
|
: super(query: query);
|
||||||
query: query,
|
|
||||||
match: match,
|
|
||||||
defaultValue: defaultValue,
|
|
||||||
required: required);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Shortcut for declaring a request cookie [Parameter].
|
/// Shortcut for declaring a request cookie [Parameter].
|
||||||
class CookieValue extends Parameter {
|
class CookieValue extends Parameter {
|
||||||
const CookieValue(String cookie, {match, defaultValue, bool required = true})
|
const CookieValue(String cookie,
|
||||||
: super(
|
{super.match, super.defaultValue, super.required})
|
||||||
cookie: cookie,
|
: super(cookie: cookie);
|
||||||
match: match,
|
|
||||||
defaultValue: defaultValue,
|
|
||||||
required: required);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,8 +26,8 @@ class AngelHttp extends Driver<HttpRequest, HttpResponse, HttpServer,
|
||||||
scheme: 'http', host: server?.address.address, port: server?.port);
|
scheme: 'http', host: server?.address.address, port: server?.port);
|
||||||
}
|
}
|
||||||
|
|
||||||
AngelHttp._(Angel app, ServerGeneratorType serverGenerator, bool useZone)
|
AngelHttp._(super.app, super.serverGenerator, bool useZone)
|
||||||
: super(app, serverGenerator, useZone: useZone);
|
: super(useZone: useZone);
|
||||||
|
|
||||||
factory AngelHttp(Angel app, {bool useZone = true}) {
|
factory AngelHttp(Angel app, {bool useZone = true}) {
|
||||||
return AngelHttp._(app, HttpServer.bind, useZone);
|
return AngelHttp._(app, HttpServer.bind, useZone);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_framework
|
name: angel3_framework
|
||||||
version: 8.2.0
|
version: 8.3.0
|
||||||
description: A high-powered HTTP server extensible framework with dependency injection, routing and much more.
|
description: A high-powered HTTP server extensible framework with dependency injection, routing and much more.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/framework
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/framework
|
||||||
|
@ -11,9 +11,9 @@ dependencies:
|
||||||
angel3_model: ^8.0.0
|
angel3_model: ^8.0.0
|
||||||
angel3_route: ^8.0.0
|
angel3_route: ^8.0.0
|
||||||
angel3_mock_request: ^8.0.0
|
angel3_mock_request: ^8.0.0
|
||||||
belatuk_merge_map: ^5.0.0
|
belatuk_merge_map: ^5.1.0
|
||||||
belatuk_combinator: ^5.0.0
|
belatuk_combinator: ^5.1.0
|
||||||
belatuk_http_server: ^4.0.0
|
belatuk_http_server: ^4.1.0
|
||||||
charcode: ^1.3.0
|
charcode: ^1.3.0
|
||||||
file: ^7.0.0
|
file: ^7.0.0
|
||||||
http_parser: ^4.0.0
|
http_parser: ^4.0.0
|
||||||
|
@ -34,7 +34,7 @@ dev_dependencies:
|
||||||
http: ^1.0.0
|
http: ^1.0.0
|
||||||
io: ^1.0.0
|
io: ^1.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_container:
|
# angel3_container:
|
||||||
# path: ../container/angel_container
|
# path: ../container/angel_container
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
|
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
name: angel3_http_exception
|
name: angel3_http_exception
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: Exception class that can be serialized to JSON and serialized to clients.
|
description: Exception class that can be serialized to JSON and serialized to clients.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/http_exception
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/http_exception
|
||||||
environment:
|
environment:
|
||||||
sdk: '>=3.0.0 <4.0.0'
|
sdk: '>=3.0.0 <4.0.0'
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
|
@ -1,5 +1,9 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_mock_request
|
name: angel3_mock_request
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: Manufacture dart:io HttpRequests, HttpResponses, HttpHeaders, etc.
|
description: Manufacture dart:io HttpRequests, HttpResponses, HttpHeaders, etc.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/mock_request
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/mock_request
|
||||||
|
@ -11,7 +11,7 @@ dev_dependencies:
|
||||||
#angel3_framework: ^7.0.0
|
#angel3_framework: ^7.0.0
|
||||||
http: ^1.0.0
|
http: ^1.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_framework:
|
# angel3_framework:
|
||||||
# path: ../framework
|
# path: ../framework
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed analyser warnings
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -11,10 +11,9 @@ class Todo extends Model {
|
||||||
bool isComplete;
|
bool isComplete;
|
||||||
|
|
||||||
Todo(
|
Todo(
|
||||||
{required String id,
|
{required String super.id,
|
||||||
this.text,
|
this.text,
|
||||||
this.isComplete = false,
|
this.isComplete = false,
|
||||||
DateTime? createdAt,
|
super.createdAt,
|
||||||
DateTime? updatedAt})
|
super.updatedAt});
|
||||||
: super(id: id, createdAt: createdAt, updatedAt: updatedAt);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
name: angel3_model
|
name: angel3_model
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: Angel3 basic data model class, no longer with the added weight of the whole framework.
|
description: Angel3 basic data model class, no longer with the added weight of the whole framework.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/model
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/model
|
||||||
environment:
|
environment:
|
||||||
sdk: '>=3.0.0 <4.0.0'
|
sdk: '>=3.0.0 <4.0.0'
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
|
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
|
||||||
[![License](https://img.shields.io/github/license/dukefirehawk/angel)](https://github.com/dukefirehawk/angel/tree/master/packages/orm/angel_orm_mysql/LICENSE)
|
[![License](https://img.shields.io/github/license/dukefirehawk/angel)](https://github.com/dukefirehawk/angel/tree/master/packages/orm/angel_orm_mysql/LICENSE)
|
||||||
|
|
||||||
This package contains the SQL executor required by Angel3 ORM to work with MySQL and MariaDB respectively. In order to better support both MySQL and MariaDB, two different flavors of drives have been included; `mysql_client` and `mysql1`. They are implmented as `MySqlExecutor` and `MariaDbExecutor` respectively.
|
This package contains the SQL executor required by Angel3 ORM to work with MySQL or MariaDB. In order to better support both MySQL and MariaDB, two different flavors of drives have been included; `mysql_client` and `mysql1`. They are implmented as `MySqlExecutor` and `MariaDbExecutor` respectively.
|
||||||
|
|
||||||
## Supported databases
|
## Supported databases
|
||||||
|
|
||||||
|
@ -73,13 +73,13 @@ This SQL executor is implemented using [`mysql1`](https://pub.dev/packages?q=mys
|
||||||
|
|
||||||
1. Login to MariaDB/MySQL database console with the following command.
|
1. Login to MariaDB/MySQL database console with the following command.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
mysql -u root -p
|
mysql -u root -p
|
||||||
```
|
```
|
||||||
|
|
||||||
1. Run the following commands to create a new database, `orm_test` and grant both local and remote access to user, `test`. Replace `orm_test`, `test` and `test123` with your own database name, username and password respectively.
|
2. Run the following commands to create a new database, `orm_test`, and grant both local and remote access to user, `test`. Replace `orm_test`, `test` and `test123` with your own database name, username and password.
|
||||||
|
|
||||||
```mysql
|
```mysql
|
||||||
create database orm_test;
|
create database orm_test;
|
||||||
|
|
||||||
-- Granting localhost access only
|
-- Granting localhost access only
|
||||||
|
@ -89,7 +89,7 @@ This SQL executor is implemented using [`mysql1`](https://pub.dev/packages?q=mys
|
||||||
-- Granting localhost and remote access
|
-- Granting localhost and remote access
|
||||||
create user 'test'@'%' identified by 'test123';
|
create user 'test'@'%' identified by 'test123';
|
||||||
grant all privileges on orm_test.* to 'test'@'%';
|
grant all privileges on orm_test.* to 'test'@'%';
|
||||||
```
|
```
|
||||||
|
|
||||||
## Compatibility Matrix
|
## Compatibility Matrix
|
||||||
|
|
||||||
|
|
|
@ -114,7 +114,6 @@ class Runner {
|
||||||
onError: onError.sendPort,
|
onError: onError.sendPort,
|
||||||
errorsAreFatal: true && false)
|
errorsAreFatal: true && false)
|
||||||
.then((isolate) {})
|
.then((isolate) {})
|
||||||
//.catchError(c.completeError);
|
|
||||||
.catchError((e) {
|
.catchError((e) {
|
||||||
c.completeError(e as Object);
|
c.completeError(e as Object);
|
||||||
return null;
|
return null;
|
||||||
|
@ -192,7 +191,8 @@ class Runner {
|
||||||
server = Server([adapter]);
|
server = Server([adapter]);
|
||||||
|
|
||||||
// Register clients
|
// Register clients
|
||||||
for (var i = 0; i < Platform.numberOfProcessors; i++) {
|
// for (var i = 0; i < Platform.numberOfProcessors; i++) {
|
||||||
|
for (var i = 0; i < options.concurrency; i++) {
|
||||||
server.registerClient(ClientInfo('client$i'));
|
server.registerClient(ClientInfo('client$i'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -248,13 +248,15 @@ class Runner {
|
||||||
|
|
||||||
if (args.options.ssl || args.options.http2) {
|
if (args.options.ssl || args.options.http2) {
|
||||||
securityContext = SecurityContext();
|
securityContext = SecurityContext();
|
||||||
if (args.options.certificateFile != null) {
|
var certificateFile = args.options.certificateFile;
|
||||||
securityContext.useCertificateChain(args.options.certificateFile!,
|
if (certificateFile != null) {
|
||||||
|
securityContext.useCertificateChain(certificateFile,
|
||||||
password: args.options.certificatePassword);
|
password: args.options.certificatePassword);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (args.options.keyFile != null) {
|
var keyFile = args.options.keyFile;
|
||||||
securityContext.usePrivateKey(args.options.keyFile!,
|
if (keyFile != null) {
|
||||||
|
securityContext.usePrivateKey(keyFile,
|
||||||
password: args.options.keyPassword);
|
password: args.options.keyPassword);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed analyser warnings
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
part of angel3_route.src.router;
|
part of 'router.dart';
|
||||||
|
|
||||||
class RouteGrammar {
|
class RouteGrammar {
|
||||||
static const String notSlashRgx = r'([^/]+)';
|
static const String notSlashRgx = r'([^/]+)';
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
part of angel3_route.src.router;
|
part of 'router.dart';
|
||||||
|
|
||||||
/// Represents a virtual location within an application.
|
/// Represents a virtual location within an application.
|
||||||
class Route<T> {
|
class Route<T> {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
part of angel3_route.src.router;
|
part of 'router.dart';
|
||||||
|
|
||||||
/// Represents a complex result of navigating to a path.
|
/// Represents a complex result of navigating to a path.
|
||||||
class RoutingResult<T> {
|
class RoutingResult<T> {
|
||||||
|
|
|
@ -1,9 +1,8 @@
|
||||||
part of angel3_route.src.router;
|
part of 'router.dart';
|
||||||
|
|
||||||
/// Placeholder [Route] to serve as a symbolic link
|
/// Placeholder [Route] to serve as a symbolic link
|
||||||
/// to a mounted [Router].
|
/// to a mounted [Router].
|
||||||
class SymlinkRoute<T> extends Route<T> {
|
class SymlinkRoute<T> extends Route<T> {
|
||||||
final Router<T> router;
|
final Router<T> router;
|
||||||
SymlinkRoute(String path, this.router)
|
SymlinkRoute(super.path, this.router) : super(method: 'GET', handlers: <T>[]);
|
||||||
: super(path, method: 'GET', handlers: <T>[]);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
name: angel3_route
|
name: angel3_route
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: A powerful, isomorphic routing library for Dart. It is mainly used in the Angel3 framework, but can be used in Flutter and on the Web.
|
description: A powerful, isomorphic routing library for Dart. It is mainly used in the Angel3 framework, but can be used in Flutter and on the Web.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/route
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/route
|
||||||
environment:
|
environment:
|
||||||
sdk: '>=3.0.0 <4.0.0'
|
sdk: '>=3.0.0 <4.0.0'
|
||||||
dependencies:
|
dependencies:
|
||||||
belatuk_combinator: ^5.0.0
|
belatuk_combinator: ^5.1.0
|
||||||
string_scanner: ^1.2.0
|
string_scanner: ^1.2.0
|
||||||
path: ^1.8.0
|
path: ^1.8.0
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
|
@ -14,4 +14,4 @@ dev_dependencies:
|
||||||
build_web_compilers: ^4.0.0
|
build_web_compilers: ^4.0.0
|
||||||
http: ^1.0.0
|
http: ^1.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
|
|
|
@ -1,5 +1,9 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
|
||||||
## 8.0.2
|
## 8.0.2
|
||||||
|
|
||||||
* Fixed incorrect mismatch message handling
|
* Fixed incorrect mismatch message handling
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
name: angel3_validate
|
name: angel3_validate
|
||||||
description: Cross-platform HTTP request body validator library based on `matcher`.
|
description: Cross-platform HTTP request body validator library based on `matcher`.
|
||||||
version: 8.0.2
|
version: 8.1.0
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/validate
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/validate
|
||||||
environment:
|
environment:
|
||||||
|
@ -14,7 +14,7 @@ dev_dependencies:
|
||||||
build_runner: ^2.4.0
|
build_runner: ^2.4.0
|
||||||
build_web_compilers: ^4.0.0
|
build_web_compilers: ^4.0.0
|
||||||
logging: ^1.2.0
|
logging: ^1.2.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_container:
|
# angel3_container:
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 8.1.0
|
||||||
|
|
||||||
|
* Updated `lints` to 3.0.0
|
||||||
|
* Fixed linter warnings
|
||||||
|
* Locked `web_socket_channel` to 2.4.0 temporarily. Starting with 2.4.1, its dependency on `dart:html` has been changed to `package:web` which is still highly experimental.
|
||||||
|
|
||||||
## 8.0.0
|
## 8.0.0
|
||||||
|
|
||||||
* Require Dart >= 3.0
|
* Require Dart >= 3.0
|
||||||
|
|
|
@ -3,7 +3,6 @@ import 'dart:collection';
|
||||||
import 'dart:convert';
|
import 'dart:convert';
|
||||||
import 'package:angel3_client/angel3_client.dart';
|
import 'package:angel3_client/angel3_client.dart';
|
||||||
import 'package:angel3_client/base_angel_client.dart';
|
import 'package:angel3_client/base_angel_client.dart';
|
||||||
import 'package:http/http.dart';
|
|
||||||
import 'package:web_socket_channel/web_socket_channel.dart';
|
import 'package:web_socket_channel/web_socket_channel.dart';
|
||||||
import 'package:web_socket_channel/status.dart' as status;
|
import 'package:web_socket_channel/status.dart' as status;
|
||||||
import 'angel3_websocket.dart';
|
import 'angel3_websocket.dart';
|
||||||
|
@ -85,9 +84,8 @@ abstract class BaseWebSocketClient extends BaseAngelClient {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
BaseWebSocketClient(BaseClient client, baseUrl,
|
BaseWebSocketClient(super.client, super.baseUrl,
|
||||||
{this.reconnectOnClose = true, Duration? reconnectInterval})
|
{this.reconnectOnClose = true, Duration? reconnectInterval}) {
|
||||||
: super(client, baseUrl) {
|
|
||||||
_reconnectInterval = reconnectInterval ?? Duration(seconds: 10);
|
_reconnectInterval = reconnectInterval ?? Duration(seconds: 10);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -106,7 +106,6 @@ class WebSockets extends BaseWebSocketClient {
|
||||||
class BrowserWebSocketsService<Id, Data> extends WebSocketsService<Id, Data> {
|
class BrowserWebSocketsService<Id, Data> extends WebSocketsService<Id, Data> {
|
||||||
final Type? type;
|
final Type? type;
|
||||||
|
|
||||||
BrowserWebSocketsService(WebSocketChannel? socket, WebSockets app, String uri,
|
BrowserWebSocketsService(super.socket, WebSockets super.app, super.uri,
|
||||||
{this.type, AngelDeserializer<Data>? deserializer})
|
{this.type, super.deserializer});
|
||||||
: super(socket, app, uri, deserializer: deserializer);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,7 +60,5 @@ class WebSockets extends BaseWebSocketClient {
|
||||||
class IoWebSocketsService<Id, Data> extends WebSocketsService<Id, Data> {
|
class IoWebSocketsService<Id, Data> extends WebSocketsService<Id, Data> {
|
||||||
final Type? type;
|
final Type? type;
|
||||||
|
|
||||||
IoWebSocketsService(
|
IoWebSocketsService(super.socket, WebSockets super.app, super.uri, this.type);
|
||||||
WebSocketChannel? socket, WebSockets app, String uri, this.type)
|
|
||||||
: super(socket, app, uri);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
part of angel3_websocket.server;
|
part of 'server.dart';
|
||||||
|
|
||||||
/// Represents a WebSocket session, with the original
|
/// Represents a WebSocket session, with the original
|
||||||
/// [RequestContext] and [ResponseContext] attached.
|
/// [RequestContext] and [ResponseContext] attached.
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
part of angel3_websocket.server;
|
part of 'server.dart';
|
||||||
|
|
||||||
/// Marks a method as available to WebSockets.
|
/// Marks a method as available to WebSockets.
|
||||||
class ExposeWs {
|
class ExposeWs {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel3_websocket
|
name: angel3_websocket
|
||||||
version: 8.0.0
|
version: 8.1.0
|
||||||
description: This library provides WebSockets support for Angel3 framework.
|
description: This library provides WebSockets support for Angel3 framework.
|
||||||
homepage: https://angel3-framework.web.app/
|
homepage: https://angel3-framework.web.app/
|
||||||
repository: https://github.com/dukefirehawk/angel/tree/master/packages/websocket
|
repository: https://github.com/dukefirehawk/angel/tree/master/packages/websocket
|
||||||
|
@ -14,7 +14,7 @@ dependencies:
|
||||||
http: ^1.0.0
|
http: ^1.0.0
|
||||||
meta: ^1.8.0
|
meta: ^1.8.0
|
||||||
stream_channel: ^2.1.0
|
stream_channel: ^2.1.0
|
||||||
web_socket_channel: ^2.1.0
|
web_socket_channel: 2.4.0
|
||||||
collection: ^1.17.0
|
collection: ^1.17.0
|
||||||
logging: ^1.1.0
|
logging: ^1.1.0
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
|
@ -22,7 +22,8 @@ dev_dependencies:
|
||||||
angel3_model: ^8.0.0
|
angel3_model: ^8.0.0
|
||||||
quiver: ^3.2.0
|
quiver: ^3.2.0
|
||||||
test: ^1.24.0
|
test: ^1.24.0
|
||||||
lints: ^2.1.0
|
lints: ^3.0.0
|
||||||
|
file: ^7.0.0
|
||||||
# dependency_overrides:
|
# dependency_overrides:
|
||||||
# angel3_container:
|
# angel3_container:
|
||||||
# path: ../container/angel_container
|
# path: ../container/angel_container
|
||||||
|
|
|
@ -29,7 +29,7 @@ const Game johnVsBob = Game(playerOne: 'John', playerTwo: 'Bob');
|
||||||
|
|
||||||
@Expose('/game')
|
@Expose('/game')
|
||||||
class GameController extends WebSocketController {
|
class GameController extends WebSocketController {
|
||||||
GameController(AngelWebSocket ws) : super(ws);
|
GameController(super.ws);
|
||||||
|
|
||||||
@ExposeWs('search')
|
@ExposeWs('search')
|
||||||
dynamic search(WebSocketContext socket) async {
|
dynamic search(WebSocketContext socket) async {
|
||||||
|
|
|
@ -6,6 +6,7 @@ void main() {
|
||||||
var app = WebSockets(window.location.origin);
|
var app = WebSockets(window.location.origin);
|
||||||
window.alert(app.baseUrl.toString());
|
window.alert(app.baseUrl.toString());
|
||||||
|
|
||||||
|
// ignore: body_might_complete_normally_catch_error
|
||||||
app.connect().catchError((_) {
|
app.connect().catchError((_) {
|
||||||
window.alert('no websocket');
|
window.alert('no websocket');
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue