@valkyrjaio/sindri 26.5.1 → 26.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +1 -1
- package/dist/bin/sindri.cjs +574 -268
- package/package.json +2 -2
- package/src/Sindri/Ast/Abstract/AstReader.ts +187 -5
- package/src/Sindri/Ast/Abstract/RouteAttributeReader.ts +2 -3
- package/src/Sindri/Ast/CliRouteAttributeReader.ts +102 -17
- package/src/Sindri/Ast/CliRouteParameterReader.ts +44 -26
- package/src/Sindri/Ast/ComponentProviderReader.ts +2 -3
- package/src/Sindri/Ast/ConfigReader.ts +2 -3
- package/src/Sindri/Ast/ConfigSourceReader.ts +2 -3
- package/src/Sindri/Ast/Contract/CliRouteAttributeReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/CliRouteParameterReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/ComponentProviderReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/ConfigReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/ConfigSourceReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/HttpRouteAttributeReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/HttpRouteMiddlewareReaderContract.ts +5 -10
- package/src/Sindri/Ast/Contract/HttpRouteParameterReaderContract.ts +3 -7
- package/src/Sindri/Ast/Contract/ListenerAttributeReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/ListenerProviderReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/RouteProviderReaderContract.ts +2 -3
- package/src/Sindri/Ast/Contract/ServiceProviderReaderContract.ts +2 -3
- package/src/Sindri/Ast/Data/CliArgumentParameterData.ts +2 -3
- package/src/Sindri/Ast/Data/CliOptionParameterData.ts +2 -3
- package/src/Sindri/Ast/Data/CliRouteData.ts +2 -3
- package/src/Sindri/Ast/Data/ConfigData.ts +2 -3
- package/src/Sindri/Ast/Data/ConfigImport.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/CliArgumentParameterDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/CliOptionParameterDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/CliRouteDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/ConfigDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/HandlerDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/HttpParameterDataContract.ts +4 -3
- package/src/Sindri/Ast/Data/Contract/HttpRouteDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/Contract/ListenerDataContract.ts +2 -3
- package/src/Sindri/Ast/Data/HandlerData.ts +2 -3
- package/src/Sindri/Ast/Data/HttpParameterData.ts +3 -3
- package/src/Sindri/Ast/Data/HttpRouteData.ts +2 -3
- package/src/Sindri/Ast/Data/ListenerData.ts +2 -3
- package/src/Sindri/Ast/Data/Result/CliRouteAttributeResult.ts +7 -4
- package/src/Sindri/Ast/Data/Result/ComponentProviderResult.ts +2 -3
- package/src/Sindri/Ast/Data/Result/ConfigResult.ts +2 -3
- package/src/Sindri/Ast/Data/Result/ConfigSourceResult.ts +2 -3
- package/src/Sindri/Ast/Data/Result/HttpRouteAttributeResult.ts +4 -3
- package/src/Sindri/Ast/Data/Result/ListenerAttributeResult.ts +2 -3
- package/src/Sindri/Ast/Data/Result/ListenerProviderResult.ts +2 -3
- package/src/Sindri/Ast/Data/Result/RouteProviderResult.ts +2 -3
- package/src/Sindri/Ast/Data/Result/ServiceProviderResult.ts +2 -3
- package/src/Sindri/Ast/HttpRouteAttributeReader.ts +180 -51
- package/src/Sindri/Ast/HttpRouteMiddlewareReader.ts +38 -18
- package/src/Sindri/Ast/HttpRouteParameterReader.ts +50 -109
- package/src/Sindri/Ast/ListenerAttributeReader.ts +2 -3
- package/src/Sindri/Ast/ListenerProviderReader.ts +2 -3
- package/src/Sindri/Ast/RouteProviderReader.ts +2 -3
- package/src/Sindri/Ast/ServiceProviderReader.ts +2 -3
- package/src/Sindri/Ast/Throwable/Contract/AstThrowable.ts +2 -3
- package/src/Sindri/Ast/Throwable/Exception/Abstract/AstInvalidArgumentException.ts +2 -3
- package/src/Sindri/Ast/Throwable/Exception/Abstract/AstRuntimeException.ts +2 -3
- package/src/Sindri/Ast/Throwable/Exception/AstFileReadException.ts +2 -3
- package/src/Sindri/Cli/Command/GenerateCachedConfigCommand.ts +2 -3
- package/src/Sindri/Cli/Command/GenerateDataFromConfigCommand.ts +2 -3
- package/src/Sindri/Constant/CommandName.ts +2 -3
- package/src/Sindri/Constant/SindriInfo.ts +4 -5
- package/src/Sindri/Constant/SindriServiceId.ts +2 -3
- package/src/Sindri/Generate/Abstract/GenerateCachedConfigFromAst.ts +2 -3
- package/src/Sindri/Generate/Abstract/GenerateDataFromAst.ts +39 -27
- package/src/Sindri/Generate/Abstract/GenerateFromAst.ts +2 -3
- package/src/Sindri/Generator/Abstract/AstFileGenerator.ts +2 -3
- package/src/Sindri/Generator/Abstract/FileGenerator.ts +2 -3
- package/src/Sindri/Generator/Ast/Cli/AstCliDataFileGenerator.ts +21 -6
- package/src/Sindri/Generator/Ast/Config/AstCachedConfigFileGenerator.ts +2 -3
- package/src/Sindri/Generator/Ast/Container/AstContainerDataFileGenerator.ts +2 -3
- package/src/Sindri/Generator/Ast/Event/AstEventDataFileGenerator.ts +2 -3
- package/src/Sindri/Generator/Ast/Http/AstHttpDataFileGenerator.ts +83 -45
- package/src/Sindri/Generator/Cli/Contract/CliDataFileGeneratorContract.ts +10 -3
- package/src/Sindri/Generator/Config/Contract/CachedConfigFileGeneratorContract.ts +2 -3
- package/src/Sindri/Generator/Container/Contract/ContainerDataFileGeneratorContract.ts +2 -3
- package/src/Sindri/Generator/Contract/FileGeneratorContract.ts +2 -3
- package/src/Sindri/Generator/Enum/GenerateStatus.ts +2 -3
- package/src/Sindri/Generator/Event/Contract/EventDataFileGeneratorContract.ts +2 -3
- package/src/Sindri/Generator/Http/Contract/HttpDataFileGeneratorContract.ts +11 -3
- package/src/Sindri/Generator/Throwable/Contract/GeneratorThrowable.ts +2 -3
- package/src/Sindri/Generator/Throwable/Exception/Abstract/GeneratorInvalidArgumentException.ts +2 -3
- package/src/Sindri/Generator/Throwable/Exception/Abstract/GeneratorRuntimeException.ts +2 -3
- package/src/Sindri/Generator/Throwable/Exception/GeneratorUnreachableException.ts +2 -3
- package/src/Sindri/Provider/SindriAstServiceProvider.ts +2 -3
- package/src/Sindri/Provider/SindriCliRouteProvider.ts +2 -3
- package/src/Sindri/Provider/SindriCommandServiceProvider.ts +2 -3
- package/src/Sindri/Provider/SindriComponentProvider.ts +2 -3
- package/src/Sindri/Throwable/Contract/SindriThrowable.ts +2 -3
- package/src/Sindri/Throwable/Exception/Abstract/SindriInvalidArgumentException.ts +2 -3
- package/src/Sindri/Throwable/Exception/Abstract/SindriRuntimeException.ts +2 -3
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ConfigSourceResult } from '../Data/Result/ConfigSourceResult.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { HttpRouteAttributeResult } from '../Data/Result/HttpRouteAttributeResult.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
@@ -14,8 +13,8 @@ import type { MethodDeclaration } from 'ts-morph';
|
|
|
14
13
|
import type { HttpRouteData } from '../Data/HttpRouteData.ts';
|
|
15
14
|
|
|
16
15
|
export interface HttpRouteMiddlewareReaderContract {
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
extractObjectRequestMethods(
|
|
17
|
+
obj: ts.ObjectLiteralExpression,
|
|
19
18
|
useMap: Record<string, string>,
|
|
20
19
|
namespace: string,
|
|
21
20
|
currentClass: string,
|
|
@@ -34,11 +33,7 @@ export interface HttpRouteMiddlewareReaderContract {
|
|
|
34
33
|
useMap: Record<string, string>,
|
|
35
34
|
namespace: string,
|
|
36
35
|
currentClass: string,
|
|
37
|
-
|
|
38
|
-
routeDispatchedMiddleware: string[],
|
|
39
|
-
throwableCaughtMiddleware: string[],
|
|
40
|
-
sendingResponseMiddleware: string[],
|
|
41
|
-
responseSentMiddleware: string[],
|
|
36
|
+
middleware: string[],
|
|
42
37
|
): [string[], string[], string[], string[], string[]];
|
|
43
38
|
|
|
44
39
|
updateRequestStruct(
|
|
@@ -1,22 +1,18 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
11
10
|
|
|
12
|
-
import type { MethodDeclaration } from 'ts-morph';
|
|
13
|
-
|
|
14
11
|
import type { HttpParameterData } from '../Data/HttpParameterData.ts';
|
|
15
12
|
|
|
16
13
|
export interface HttpRouteParameterReaderContract {
|
|
17
14
|
updateParameters(
|
|
18
|
-
|
|
19
|
-
method: MethodDeclaration,
|
|
15
|
+
obj: ts.ObjectLiteralExpression,
|
|
20
16
|
useMap: Record<string, string>,
|
|
21
17
|
namespace: string,
|
|
22
18
|
currentClass: string,
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ListenerAttributeResult } from '../Data/Result/ListenerAttributeResult.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ListenerProviderResult } from '../Data/Result/ListenerProviderResult.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { RouteProviderResult } from '../Data/Result/RouteProviderResult.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ServiceProviderResult } from '../Data/Result/ServiceProviderResult.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { CliArgumentParameterDataContract } from './Contract/CliArgumentParameterDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { CliOptionParameterDataContract } from './Contract/CliOptionParameterDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { CliArgumentParameterData } from './CliArgumentParameterData.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ConfigDataContract } from './Contract/ConfigDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
/**
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export interface CliArgumentParameterDataContract {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export interface CliOptionParameterDataContract {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { CliArgumentParameterDataContract } from './CliArgumentParameterDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export interface ConfigDataContract {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export interface HandlerDataContract {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export interface HttpParameterDataContract {
|
|
@@ -14,4 +13,6 @@ export interface HttpParameterDataContract {
|
|
|
14
13
|
readonly cast: string | null;
|
|
15
14
|
readonly isOptional: boolean;
|
|
16
15
|
readonly shouldCapture: boolean;
|
|
16
|
+
/** The default value for the parameter, or null when none was declared. */
|
|
17
|
+
readonly defaultValue: string | number | boolean | null;
|
|
17
18
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { HandlerDataContract } from './HandlerDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { HandlerDataContract } from './HandlerDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { HandlerDataContract } from './Contract/HandlerDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { HttpParameterDataContract } from './Contract/HttpParameterDataContract.ts';
|
|
@@ -16,5 +15,6 @@ export class HttpParameterData implements HttpParameterDataContract {
|
|
|
16
15
|
readonly cast: string | null = null,
|
|
17
16
|
readonly isOptional: boolean = false,
|
|
18
17
|
readonly shouldCapture: boolean = true,
|
|
18
|
+
readonly defaultValue: string | number | boolean | null = null,
|
|
19
19
|
) {}
|
|
20
20
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { HttpRouteDataContract } from './Contract/HttpRouteDataContract.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ListenerDataContract } from './Contract/ListenerDataContract.ts';
|
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
11
10
|
|
|
12
11
|
export class CliRouteAttributeResult {
|
|
13
|
-
constructor(
|
|
12
|
+
constructor(
|
|
13
|
+
readonly routes: Record<string, ts.Expression> = {},
|
|
14
|
+
/** Class short name → absolute file path for handler/help-text imports. */
|
|
15
|
+
readonly importMap: Record<string, string> = {},
|
|
16
|
+
) {}
|
|
14
17
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export class ComponentProviderResult {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export class ConfigResult {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ConfigImport } from '../ConfigImport.ts';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
@@ -15,5 +14,7 @@ export class HttpRouteAttributeResult {
|
|
|
15
14
|
constructor(
|
|
16
15
|
readonly routes: Record<string, ts.Expression> = {},
|
|
17
16
|
readonly routeData: Record<string, HttpRouteData> = {},
|
|
17
|
+
/** Class short name → absolute file path for handler/middleware imports. */
|
|
18
|
+
readonly importMap: Record<string, string> = {},
|
|
18
19
|
) {}
|
|
19
20
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
import type { ts } from 'ts-morph';
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* This file is part of the Sindri package.
|
|
3
3
|
*
|
|
4
|
-
* (c) Melech Mizrachi
|
|
4
|
+
* Copyright (c) 2016-present Melech Mizrachi
|
|
5
5
|
*
|
|
6
|
-
*
|
|
7
|
-
* file that was distributed with this source code.
|
|
6
|
+
* Released under the MIT License. See LICENSE.md for details.
|
|
8
7
|
*/
|
|
9
8
|
|
|
10
9
|
export class ServiceProviderResult {
|