@lad-tech/nsc-toolkit 1.10.1 → 1.11.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.
Files changed (31) hide show
  1. package/CHANGELOG.md +2 -2
  2. package/README.md +1 -1
  3. package/coverage/clover.xml +120 -116
  4. package/coverage/coverage-final.json +4 -4
  5. package/coverage/lcov-report/examples/LogicService/adapters/Configurator.ts.html +1 -1
  6. package/coverage/lcov-report/examples/LogicService/adapters/Repository.ts.html +1 -1
  7. package/coverage/lcov-report/examples/LogicService/adapters/index.html +1 -1
  8. package/coverage/lcov-report/examples/LogicService/adapters/index.ts.html +1 -1
  9. package/coverage/lcov-report/examples/LogicService/index.html +1 -1
  10. package/coverage/lcov-report/examples/LogicService/index.ts.html +1 -1
  11. package/coverage/lcov-report/examples/LogicService/inversion.types.ts.html +1 -1
  12. package/coverage/lcov-report/examples/LogicService/methods/GetUser.ts.html +1 -1
  13. package/coverage/lcov-report/examples/LogicService/methods/GetUserV2.ts.html +1 -1
  14. package/coverage/lcov-report/examples/LogicService/methods/WeirdSum.ts.html +1 -1
  15. package/coverage/lcov-report/examples/LogicService/methods/index.html +1 -1
  16. package/coverage/lcov-report/examples/LogicService/service.ts.html +1 -1
  17. package/coverage/lcov-report/examples/MathService/index.html +1 -1
  18. package/coverage/lcov-report/examples/MathService/index.ts.html +10 -13
  19. package/coverage/lcov-report/examples/MathService/methods/Fibonacci.ts.html +1 -1
  20. package/coverage/lcov-report/examples/MathService/methods/Sum.ts.html +1 -1
  21. package/coverage/lcov-report/examples/MathService/methods/SumStream.ts.html +1 -1
  22. package/coverage/lcov-report/examples/MathService/methods/index.html +1 -1
  23. package/coverage/lcov-report/examples/MathService/service.ts.html +6 -6
  24. package/coverage/lcov-report/index.html +14 -14
  25. package/coverage/lcov.info +236 -231
  26. package/dist/Client.js +8 -3
  27. package/dist/Client.js.map +1 -1
  28. package/dist/interfaces.js.map +1 -1
  29. package/dist/types/Client.d.ts +3 -2
  30. package/dist/types/interfaces.d.ts +2 -1
  31. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
- ## [1.10.1](https://github.com/lad-tech/nsc-toolkit/compare/v1.10.0...v1.10.1) (2023-06-27)
1
+ ## [1.11.1](https://github.com/lad-tech/nsc-toolkit/compare/v1.11.0...v1.11.1) (2023-06-28)
2
2
 
3
3
 
4
4
  ### Bug Fixes
5
5
 
6
- * Update inject arguments types ([f1c3b69](https://github.com/lad-tech/nsc-toolkit/commit/f1c3b694f18b6ad44ceeaee4cc3855f077a382f8))
6
+ * Исправление грамматических ошибок в README.md ([#56](https://github.com/lad-tech/nsc-toolkit/issues/56)) ([9eec736](https://github.com/lad-tech/nsc-toolkit/commit/9eec7368a0e58912812eed220acace01ce67db5b))
package/README.md CHANGED
@@ -449,7 +449,7 @@ Service/
449
449
 
450
450
  ## Инверсия зависимостей и DI-контейнер
451
451
 
452
- Библиотека реализует возможности по инверсии зависимостей через DI-контейнер. Экземпляр контейнера можно получить импортировав его из библиотеки. Для описания существующих ключей зависимостей рекомендуется использовать отдеьный файл `inversion.types.ts` в корне сервиса. [Пример файла](./examples/LogicService/inversion.types.ts). Для внедрения зависимостей используются свойства класса метода или параметры конструктора. Для описания зависимости используется декоратор `inject`, который можно испортировать из библиотеки. В декоратор необходимо передать символьный ключ из файла `inversion.types.ts`. Саму привязку реализаций к DI-контейнеру рекомендуется осуществлять в основном файле сервиса `service.ts`. Пример с глубоковложенными зависимостями разных типов можно [посмотреть в методе](./examples/LogicService/methods/GetUser.ts). Цепочка внедряемых зависимостей.
452
+ Библиотека реализует возможности по инверсии зависимостей через DI-контейнер. Экземпляр контейнера можно получить импортировав его из библиотеки. Для описания существующих ключей зависимостей рекомендуется использовать отдельный файл `inversion.types.ts` в корне сервиса. [Пример файла](./examples/LogicService/inversion.types.ts). Для внедрения зависимостей используются свойства класса метода или параметры конструктора. Для описания зависимости используется декоратор `inject`, который можно импортировать из библиотеки. В декоратор необходимо передать символьный ключ из файла `inversion.types.ts`. Саму привязку реализаций к DI-контейнеру рекомендуется осуществлять в основном файле сервиса `service.ts`. Пример с глубоко вложенными зависимостями разных типов можно [посмотреть в методе](./examples/LogicService/methods/GetUser.ts). Цепочка внедряемых зависимостей.
453
453
 
454
454
  ```
455
455
  ┌---------┐ ┌───────────-┐ ┌───────────---┐ ┌---------┐
@@ -1,7 +1,7 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
- <coverage generated="1687871100620" clover="3.2.0">
3
- <project timestamp="1687871100620" name="All files">
4
- <metrics statements="845" coveredstatements="724" conditionals="328" coveredconditionals="258" methods="193" coveredmethods="143" elements="1366" coveredelements="1125" complexity="0" loc="845" ncloc="845" packages="9" files="33" classes="33"/>
2
+ <coverage generated="1687964542190" clover="3.2.0">
3
+ <project timestamp="1687964542190" name="All files">
4
+ <metrics statements="849" coveredstatements="727" conditionals="329" coveredconditionals="258" methods="193" coveredmethods="143" elements="1371" coveredelements="1128" complexity="0" loc="849" ncloc="849" packages="9" files="33" classes="33"/>
5
5
  <package name="examples.LogicService">
6
6
  <metrics statements="28" coveredstatements="28" conditionals="2" coveredconditionals="1" methods="5" coveredmethods="5"/>
7
7
  <file name="index.ts" path="/home/runner/work/nsc-toolkit/nsc-toolkit/examples/LogicService/index.ts">
@@ -122,18 +122,18 @@
122
122
  <metrics statements="18" coveredstatements="18" conditionals="2" coveredconditionals="1" methods="5" coveredmethods="5"/>
123
123
  <file name="index.ts" path="/home/runner/work/nsc-toolkit/nsc-toolkit/examples/MathService/index.ts">
124
124
  <metrics statements="7" coveredstatements="7" conditionals="0" coveredconditionals="0" methods="4" coveredmethods="4"/>
125
- <line num="1" count="2" type="stmt"/>
126
- <line num="2" count="2" type="stmt"/>
127
- <line num="9" count="2" type="stmt"/>
128
- <line num="11" count="1" type="stmt"/>
129
- <line num="14" count="1" type="stmt"/>
130
- <line num="17" count="1" type="stmt"/>
131
- <line num="20" count="1" type="stmt"/>
125
+ <line num="3" count="2" type="stmt"/>
126
+ <line num="6" count="2" type="stmt"/>
127
+ <line num="8" count="2" type="stmt"/>
128
+ <line num="10" count="1" type="stmt"/>
129
+ <line num="13" count="1" type="stmt"/>
130
+ <line num="16" count="1" type="stmt"/>
131
+ <line num="19" count="1" type="stmt"/>
132
132
  </file>
133
133
  <file name="service.ts" path="/home/runner/work/nsc-toolkit/nsc-toolkit/examples/MathService/service.ts">
134
134
  <metrics statements="11" coveredstatements="11" conditionals="2" coveredconditionals="1" methods="1" coveredmethods="1"/>
135
135
  <line num="1" count="1" type="stmt"/>
136
- <line num="3" count="1" type="stmt"/>
136
+ <line num="2" count="1" type="stmt"/>
137
137
  <line num="4" count="1" type="stmt"/>
138
138
  <line num="6" count="1" type="stmt"/>
139
139
  <line num="7" count="1" type="stmt"/>
@@ -204,9 +204,9 @@
204
204
  </file>
205
205
  </package>
206
206
  <package name="src">
207
- <metrics statements="587" coveredstatements="514" conditionals="314" coveredconditionals="250" methods="104" coveredmethods="97"/>
207
+ <metrics statements="591" coveredstatements="517" conditionals="315" coveredconditionals="250" methods="104" coveredmethods="97"/>
208
208
  <file name="Client.ts" path="/home/runner/work/nsc-toolkit/nsc-toolkit/src/Client.ts">
209
- <metrics statements="132" coveredstatements="123" conditionals="100" coveredconditionals="90" methods="18" coveredmethods="17"/>
209
+ <metrics statements="136" coveredstatements="126" conditionals="101" coveredconditionals="90" methods="18" coveredmethods="17"/>
210
210
  <line num="1" count="4" type="stmt"/>
211
211
  <line num="2" count="4" type="stmt"/>
212
212
  <line num="3" count="4" type="stmt"/>
@@ -217,128 +217,132 @@
217
217
  <line num="23" count="4" type="stmt"/>
218
218
  <line num="24" count="4" type="stmt"/>
219
219
  <line num="27" count="4" type="stmt"/>
220
- <line num="33" count="8" type="stmt"/>
221
220
  <line num="34" count="8" type="stmt"/>
222
- <line num="37" count="8" type="stmt"/>
221
+ <line num="35" count="8" type="stmt"/>
223
222
  <line num="38" count="8" type="stmt"/>
223
+ <line num="39" count="8" type="stmt"/>
224
224
  <line num="40" count="8" type="stmt"/>
225
225
  <line num="41" count="8" type="stmt"/>
226
226
  <line num="42" count="8" type="stmt"/>
227
227
  <line num="43" count="8" type="stmt"/>
228
- <line num="51" count="3" type="stmt"/>
229
- <line num="52" count="2" type="stmt"/>
228
+ <line num="44" count="8" type="stmt"/>
229
+ <line num="52" count="3" type="stmt"/>
230
230
  <line num="53" count="2" type="stmt"/>
231
- <line num="55" count="2" type="cond" truecount="1" falsecount="0"/>
232
- <line num="56" count="1" type="stmt"/>
231
+ <line num="54" count="2" type="stmt"/>
232
+ <line num="56" count="2" type="cond" truecount="1" falsecount="0"/>
233
233
  <line num="57" count="1" type="stmt"/>
234
- <line num="60" count="2" type="stmt"/>
235
- <line num="68" count="4" type="cond" truecount="0" falsecount="1"/>
236
- <line num="69" count="0" type="stmt"/>
237
- <line num="72" count="4" type="stmt"/>
238
- <line num="74" count="4" type="stmt"/>
239
- <line num="76" count="10" type="stmt"/>
240
- <line num="78" count="10" type="cond" truecount="1" falsecount="0"/>
241
- <line num="79" count="3" type="stmt"/>
234
+ <line num="58" count="1" type="stmt"/>
235
+ <line num="61" count="2" type="stmt"/>
236
+ <line num="69" count="4" type="cond" truecount="0" falsecount="1"/>
237
+ <line num="70" count="0" type="stmt"/>
238
+ <line num="73" count="4" type="stmt"/>
239
+ <line num="75" count="4" type="stmt"/>
240
+ <line num="77" count="10" type="stmt"/>
241
+ <line num="79" count="10" type="cond" truecount="1" falsecount="0"/>
242
242
  <line num="80" count="3" type="stmt"/>
243
243
  <line num="81" count="3" type="stmt"/>
244
- <line num="83" count="3" type="cond" truecount="3" falsecount="1"/>
245
- <line num="85" count="3" type="cond" truecount="0" falsecount="1"/>
246
- <line num="86" count="0" type="stmt"/>
247
- <line num="89" count="3" type="cond" truecount="4" falsecount="0"/>
248
- <line num="93" count="3" type="cond" truecount="2" falsecount="0"/>
249
- <line num="94" count="1" type="stmt"/>
250
- <line num="100" count="2" type="cond" truecount="4" falsecount="2"/>
251
- <line num="101" count="2" type="stmt"/>
252
- <line num="104" count="3" type="stmt"/>
244
+ <line num="82" count="3" type="stmt"/>
245
+ <line num="84" count="3" type="cond" truecount="3" falsecount="1"/>
246
+ <line num="86" count="3" type="cond" truecount="0" falsecount="1"/>
247
+ <line num="87" count="0" type="stmt"/>
248
+ <line num="90" count="3" type="cond" truecount="4" falsecount="0"/>
249
+ <line num="94" count="3" type="cond" truecount="2" falsecount="0"/>
250
+ <line num="95" count="1" type="stmt"/>
251
+ <line num="101" count="2" type="cond" truecount="4" falsecount="2"/>
252
+ <line num="102" count="2" type="stmt"/>
253
253
  <line num="105" count="3" type="stmt"/>
254
254
  <line num="106" count="3" type="stmt"/>
255
- <line num="108" count="0" type="stmt"/>
256
- <line num="113" count="7" type="cond" truecount="1" falsecount="0"/>
257
- <line num="114" count="1" type="stmt"/>
255
+ <line num="107" count="3" type="stmt"/>
256
+ <line num="109" count="0" type="stmt"/>
257
+ <line num="114" count="7" type="cond" truecount="1" falsecount="0"/>
258
258
  <line num="115" count="1" type="stmt"/>
259
259
  <line num="116" count="1" type="stmt"/>
260
- <line num="117" count="1" type="cond" truecount="3" falsecount="1"/>
261
- <line num="118" count="1" type="stmt"/>
260
+ <line num="117" count="1" type="stmt"/>
261
+ <line num="118" count="1" type="cond" truecount="3" falsecount="1"/>
262
262
  <line num="119" count="1" type="stmt"/>
263
- <line num="122" count="6" type="stmt"/>
264
- <line num="128" count="2" type="stmt"/>
263
+ <line num="120" count="1" type="stmt"/>
264
+ <line num="123" count="6" type="stmt"/>
265
265
  <line num="129" count="2" type="stmt"/>
266
- <line num="133" count="11" type="stmt"/>
266
+ <line num="130" count="2" type="stmt"/>
267
267
  <line num="134" count="11" type="stmt"/>
268
- <line num="135" count="11" type="cond" truecount="1" falsecount="0"/>
269
- <line num="136" count="2" type="stmt"/>
270
- <line num="145" count="16" type="stmt"/>
271
- <line num="146" count="16" type="stmt"/>
272
- <line num="147" count="16" type="stmt"/>
273
- <line num="148" count="16" type="cond" truecount="11" falsecount="0"/>
274
- <line num="149" count="8" type="stmt"/>
275
- <line num="152" count="15" type="stmt"/>
276
- <line num="153" count="15" type="cond" truecount="8" falsecount="0"/>
277
- <line num="154" count="15" type="stmt"/>
278
- <line num="155" count="15" type="stmt"/>
279
- <line num="157" count="15" type="cond" truecount="1" falsecount="0"/>
280
- <line num="158" count="1" type="stmt"/>
281
- <line num="161" count="14" type="stmt"/>
282
- <line num="163" count="14" type="cond" truecount="8" falsecount="0"/>
283
- <line num="164" count="2" type="stmt"/>
284
- <line num="165" count="2" type="stmt"/>
285
- <line num="166" count="2" type="stmt"/>
286
- <line num="167" count="2" type="cond" truecount="1" falsecount="0"/>
287
- <line num="168" count="1" type="stmt"/>
288
- <line num="171" count="0" type="stmt"/>
289
- <line num="174" count="13" type="cond" truecount="6" falsecount="0"/>
290
- <line num="178" count="13" type="cond" truecount="1" falsecount="0"/>
291
- <line num="179" count="1" type="stmt"/>
292
- <line num="182" count="12" type="cond" truecount="11" falsecount="0"/>
293
- <line num="183" count="3" type="stmt"/>
294
- <line num="185" count="11" type="cond" truecount="8" falsecount="0"/>
295
- <line num="186" count="1" type="stmt"/>
296
- <line num="189" count="11" type="stmt"/>
297
- <line num="191" count="4" type="stmt"/>
298
- <line num="192" count="4" type="stmt"/>
299
- <line num="193" count="4" type="stmt"/>
300
- <line num="194" count="4" type="stmt"/>
301
- <line num="196" count="16" type="stmt"/>
302
- <line num="201" count="5" type="stmt"/>
303
- <line num="202" count="5" type="stmt"/>
304
- <line num="205" count="5" type="stmt"/>
305
- <line num="206" count="5" type="cond" truecount="2" falsecount="1"/>
306
- <line num="207" count="0" type="stmt"/>
307
- <line num="209" count="5" type="stmt"/>
308
- <line num="213" count="24" type="stmt"/>
309
- <line num="217" count="8" type="stmt"/>
310
- <line num="218" count="8" type="stmt"/>
311
- <line num="219" count="8" type="stmt"/>
312
- <line num="221" count="0" type="stmt"/>
313
- <line num="231" count="5" type="stmt"/>
314
- <line num="232" count="5" type="stmt"/>
315
- <line num="233" count="5" type="stmt"/>
316
- <line num="234" count="5" type="stmt"/>
317
- <line num="236" count="5" type="stmt"/>
318
- <line num="240" count="5" type="cond" truecount="1" falsecount="0"/>
319
- <line num="241" count="2" type="stmt"/>
320
- <line num="243" count="5" type="stmt"/>
321
- <line num="253" count="5" type="cond" truecount="7" falsecount="2"/>
322
- <line num="254" count="3" type="stmt"/>
323
- <line num="255" count="3" type="stmt"/>
324
- <line num="258" count="2" type="stmt"/>
325
- <line num="259" count="2" type="stmt"/>
326
- <line num="260" count="2" type="stmt"/>
327
- <line num="263" count="2" type="stmt"/>
268
+ <line num="135" count="11" type="cond" truecount="0" falsecount="1"/>
269
+ <line num="136" count="0" type="stmt"/>
270
+ <line num="139" count="11" type="stmt"/>
271
+ <line num="140" count="11" type="stmt"/>
272
+ <line num="141" count="11" type="cond" truecount="1" falsecount="0"/>
273
+ <line num="142" count="2" type="stmt"/>
274
+ <line num="151" count="16" type="stmt"/>
275
+ <line num="152" count="16" type="stmt"/>
276
+ <line num="153" count="16" type="stmt"/>
277
+ <line num="154" count="16" type="cond" truecount="11" falsecount="0"/>
278
+ <line num="155" count="8" type="stmt"/>
279
+ <line num="158" count="15" type="stmt"/>
280
+ <line num="159" count="15" type="cond" truecount="8" falsecount="0"/>
281
+ <line num="160" count="15" type="stmt"/>
282
+ <line num="161" count="15" type="stmt"/>
283
+ <line num="163" count="15" type="cond" truecount="1" falsecount="0"/>
284
+ <line num="164" count="1" type="stmt"/>
285
+ <line num="167" count="14" type="stmt"/>
286
+ <line num="169" count="14" type="cond" truecount="8" falsecount="0"/>
287
+ <line num="170" count="2" type="stmt"/>
288
+ <line num="171" count="2" type="stmt"/>
289
+ <line num="172" count="2" type="stmt"/>
290
+ <line num="173" count="2" type="cond" truecount="1" falsecount="0"/>
291
+ <line num="174" count="1" type="stmt"/>
292
+ <line num="177" count="0" type="stmt"/>
293
+ <line num="180" count="13" type="cond" truecount="6" falsecount="0"/>
294
+ <line num="184" count="13" type="cond" truecount="1" falsecount="0"/>
295
+ <line num="185" count="1" type="stmt"/>
296
+ <line num="188" count="12" type="cond" truecount="11" falsecount="0"/>
297
+ <line num="189" count="3" type="stmt"/>
298
+ <line num="191" count="11" type="cond" truecount="8" falsecount="0"/>
299
+ <line num="192" count="1" type="stmt"/>
300
+ <line num="195" count="11" type="stmt"/>
301
+ <line num="197" count="4" type="stmt"/>
302
+ <line num="198" count="4" type="stmt"/>
303
+ <line num="199" count="4" type="stmt"/>
304
+ <line num="200" count="4" type="stmt"/>
305
+ <line num="202" count="16" type="stmt"/>
306
+ <line num="207" count="5" type="stmt"/>
307
+ <line num="208" count="5" type="stmt"/>
308
+ <line num="211" count="5" type="stmt"/>
309
+ <line num="212" count="5" type="cond" truecount="2" falsecount="1"/>
310
+ <line num="213" count="0" type="stmt"/>
311
+ <line num="215" count="5" type="stmt"/>
312
+ <line num="219" count="24" type="stmt"/>
313
+ <line num="223" count="8" type="stmt"/>
314
+ <line num="224" count="8" type="stmt"/>
315
+ <line num="225" count="8" type="stmt"/>
316
+ <line num="227" count="0" type="stmt"/>
317
+ <line num="237" count="5" type="stmt"/>
318
+ <line num="238" count="5" type="stmt"/>
319
+ <line num="239" count="5" type="stmt"/>
320
+ <line num="240" count="5" type="stmt"/>
321
+ <line num="242" count="5" type="stmt"/>
322
+ <line num="246" count="5" type="cond" truecount="1" falsecount="0"/>
323
+ <line num="247" count="2" type="stmt"/>
324
+ <line num="249" count="5" type="stmt"/>
325
+ <line num="259" count="5" type="cond" truecount="7" falsecount="2"/>
326
+ <line num="260" count="3" type="stmt"/>
327
+ <line num="261" count="3" type="stmt"/>
328
328
  <line num="264" count="2" type="stmt"/>
329
329
  <line num="265" count="2" type="stmt"/>
330
- <line num="267" count="0" type="stmt"/>
331
- <line num="272" count="5" type="stmt"/>
330
+ <line num="266" count="2" type="stmt"/>
331
+ <line num="269" count="2" type="stmt"/>
332
+ <line num="270" count="2" type="stmt"/>
333
+ <line num="271" count="2" type="stmt"/>
332
334
  <line num="273" count="0" type="stmt"/>
333
- <line num="276" count="5" type="cond" truecount="1" falsecount="0"/>
334
- <line num="277" count="3" type="stmt"/>
335
- <line num="278" count="3" type="stmt"/>
336
- <line num="281" count="2" type="stmt"/>
337
- <line num="282" count="2" type="stmt"/>
338
- <line num="287" count="5" type="cond" truecount="0" falsecount="1"/>
339
- <line num="288" count="0" type="stmt"/>
340
- <line num="290" count="5" type="stmt"/>
341
- <line num="299" count="2" type="cond" truecount="2" falsecount="0"/>
335
+ <line num="278" count="5" type="stmt"/>
336
+ <line num="279" count="0" type="stmt"/>
337
+ <line num="282" count="5" type="cond" truecount="1" falsecount="0"/>
338
+ <line num="283" count="3" type="stmt"/>
339
+ <line num="284" count="3" type="stmt"/>
340
+ <line num="287" count="2" type="stmt"/>
341
+ <line num="288" count="2" type="stmt"/>
342
+ <line num="293" count="5" type="cond" truecount="0" falsecount="1"/>
343
+ <line num="294" count="0" type="stmt"/>
344
+ <line num="296" count="5" type="stmt"/>
345
+ <line num="305" count="2" type="cond" truecount="2" falsecount="0"/>
342
346
  </file>
343
347
  <file name="Container.ts" path="/home/runner/work/nsc-toolkit/nsc-toolkit/src/Container.ts">
344
348
  <metrics statements="37" coveredstatements="34" conditionals="12" coveredconditionals="11" methods="12" coveredmethods="11"/>
@@ -817,7 +821,7 @@
817
821
  </file>
818
822
  <file name="interfaces.ts" path="/home/runner/work/nsc-toolkit/nsc-toolkit/src/interfaces.ts">
819
823
  <metrics statements="1" coveredstatements="1" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
820
- <line num="167" count="4" type="stmt"/>
824
+ <line num="168" count="4" type="stmt"/>
821
825
  </file>
822
826
  </package>
823
827
  <package name="src.Union">