@marketeer-intelligence/framework-device 0.1.0-alpha.4 → 0.1.0-alpha.5
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/data-source/MarketIndexTableParaser.d.ts +8 -0
- package/dist/data-source/MarketIndexTableParaser.d.ts.map +1 -0
- package/dist/data-source/MarketIndexTableParaser.js +62 -0
- package/dist/data-source/MarketIndexTableParaser.js.map +1 -0
- package/dist/data-source/SecurityTableParaser.d.ts +7 -7
- package/dist/data-source/SecurityTableParaser.js +71 -71
- package/dist/data-source/StaticWebpageScraper.d.ts +11 -11
- package/dist/data-source/StaticWebpageScraper.js +49 -49
- package/dist/data-source/Webpage.d.ts +10 -10
- package/dist/data-source/Webpage.js +21 -21
- package/dist/data-source/WebpageBody.d.ts +10 -10
- package/dist/data-source/WebpageBody.js +33 -33
- package/dist/data-source/WebpageUrl.d.ts +10 -10
- package/dist/data-source/WebpageUrl.js +38 -38
- package/dist/data-source/index.d.ts +7 -6
- package/dist/data-source/index.d.ts.map +1 -1
- package/dist/data-source/index.js +7 -6
- package/dist/data-source/index.js.map +1 -1
- package/dist/data-store/InstrumentMongoDbCollection.d.ts +11 -11
- package/dist/data-store/InstrumentMongoDbCollection.js +57 -57
- package/dist/data-store/SecurityMongoDbCollection.d.ts +11 -11
- package/dist/data-store/SecurityMongoDbCollection.js +66 -66
- package/dist/data-store/index.d.ts +3 -3
- package/dist/data-store/index.js +3 -3
- package/dist/index.d.ts +4 -4
- package/dist/index.js +4 -4
- package/dist/task/ConfigureEnvironmentVariables.d.ts +9 -9
- package/dist/task/ConfigureEnvironmentVariables.js +31 -31
- package/dist/task/ConnectToMongoDb.d.ts +8 -8
- package/dist/task/ConnectToMongoDb.js +28 -28
- package/dist/task/DisconnectFromMongoDb.d.ts +7 -7
- package/dist/task/DisconnectFromMongoDb.js +25 -25
- package/dist/task/MongoDbUri.d.ts +10 -10
- package/dist/task/MongoDbUri.js +38 -38
- package/dist/task/index.d.ts +5 -5
- package/dist/task/index.js +5 -5
- package/package.json +4 -4
package/dist/task/MongoDbUri.js
CHANGED
@@ -1,39 +1,39 @@
|
|
1
|
-
import { Failure, Result } from './index.js';
|
2
|
-
const testPattern = /^mongodb(?:\+srv)?:\/\/(?:(?:[^:\n\r]+:[^@\n\r]+)@)?(?:[^\/\n\r]+|\[[^\]]+\])(?::[0-9]+)?\/[^\/\n\r\?]+(?:\?[^\n\r]*)?$/;
|
3
|
-
export function isMongoDbUriValue(candidate) {
|
4
|
-
if (typeof candidate !== 'string')
|
5
|
-
return false;
|
6
|
-
if (!testPattern.test(candidate))
|
7
|
-
return false;
|
8
|
-
return true;
|
9
|
-
}
|
10
|
-
export class MongoDbUri {
|
11
|
-
_value;
|
12
|
-
constructor(_value) {
|
13
|
-
this._value = _value;
|
14
|
-
}
|
15
|
-
static create(candidate) {
|
16
|
-
try {
|
17
|
-
if (!isMongoDbUriValue(candidate)) {
|
18
|
-
const msg = 'invalid MongoDbUri creation value';
|
19
|
-
const error = new Error(msg);
|
20
|
-
return Failure.create(error);
|
21
|
-
}
|
22
|
-
const mongoDbUri = new MongoDbUri(candidate);
|
23
|
-
return Result.create(mongoDbUri);
|
24
|
-
}
|
25
|
-
catch (error) {
|
26
|
-
if (error instanceof Error) {
|
27
|
-
return Failure.create(error);
|
28
|
-
}
|
29
|
-
throw error;
|
30
|
-
}
|
31
|
-
}
|
32
|
-
get value() {
|
33
|
-
return this._value;
|
34
|
-
}
|
35
|
-
}
|
36
|
-
export function isMongoDbUri(candidate) {
|
37
|
-
return candidate instanceof MongoDbUri;
|
38
|
-
}
|
1
|
+
import { Failure, Result } from './index.js';
|
2
|
+
const testPattern = /^mongodb(?:\+srv)?:\/\/(?:(?:[^:\n\r]+:[^@\n\r]+)@)?(?:[^\/\n\r]+|\[[^\]]+\])(?::[0-9]+)?\/[^\/\n\r\?]+(?:\?[^\n\r]*)?$/;
|
3
|
+
export function isMongoDbUriValue(candidate) {
|
4
|
+
if (typeof candidate !== 'string')
|
5
|
+
return false;
|
6
|
+
if (!testPattern.test(candidate))
|
7
|
+
return false;
|
8
|
+
return true;
|
9
|
+
}
|
10
|
+
export class MongoDbUri {
|
11
|
+
_value;
|
12
|
+
constructor(_value) {
|
13
|
+
this._value = _value;
|
14
|
+
}
|
15
|
+
static create(candidate) {
|
16
|
+
try {
|
17
|
+
if (!isMongoDbUriValue(candidate)) {
|
18
|
+
const msg = 'invalid MongoDbUri creation value';
|
19
|
+
const error = new Error(msg);
|
20
|
+
return Failure.create(error);
|
21
|
+
}
|
22
|
+
const mongoDbUri = new MongoDbUri(candidate);
|
23
|
+
return Result.create(mongoDbUri);
|
24
|
+
}
|
25
|
+
catch (error) {
|
26
|
+
if (error instanceof Error) {
|
27
|
+
return Failure.create(error);
|
28
|
+
}
|
29
|
+
throw error;
|
30
|
+
}
|
31
|
+
}
|
32
|
+
get value() {
|
33
|
+
return this._value;
|
34
|
+
}
|
35
|
+
}
|
36
|
+
export function isMongoDbUri(candidate) {
|
37
|
+
return candidate instanceof MongoDbUri;
|
38
|
+
}
|
39
39
|
//# sourceMappingURL=MongoDbUri.js.map
|
package/dist/task/index.d.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
export * from '../index.js';
|
2
|
-
export { ConfigureEnvironmentVariables } from './ConfigureEnvironmentVariables.js';
|
3
|
-
export { ConnectToMongoDb } from './ConnectToMongoDb.js';
|
4
|
-
export { DisconnectFromMongoDb } from './DisconnectFromMongoDb.js';
|
5
|
-
export { MongoDbUriValue, isMongoDbUriValue, MongoDbUri, isMongoDbUri, } from './MongoDbUri.js';
|
1
|
+
export * from '../index.js';
|
2
|
+
export { ConfigureEnvironmentVariables } from './ConfigureEnvironmentVariables.js';
|
3
|
+
export { ConnectToMongoDb } from './ConnectToMongoDb.js';
|
4
|
+
export { DisconnectFromMongoDb } from './DisconnectFromMongoDb.js';
|
5
|
+
export { MongoDbUriValue, isMongoDbUriValue, MongoDbUri, isMongoDbUri, } from './MongoDbUri.js';
|
6
6
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/task/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
export * from '../index.js';
|
2
|
-
export { ConfigureEnvironmentVariables } from './ConfigureEnvironmentVariables.js';
|
3
|
-
export { ConnectToMongoDb } from './ConnectToMongoDb.js';
|
4
|
-
export { DisconnectFromMongoDb } from './DisconnectFromMongoDb.js';
|
5
|
-
export { isMongoDbUriValue, MongoDbUri, isMongoDbUri, } from './MongoDbUri.js';
|
1
|
+
export * from '../index.js';
|
2
|
+
export { ConfigureEnvironmentVariables } from './ConfigureEnvironmentVariables.js';
|
3
|
+
export { ConnectToMongoDb } from './ConnectToMongoDb.js';
|
4
|
+
export { DisconnectFromMongoDb } from './DisconnectFromMongoDb.js';
|
5
|
+
export { isMongoDbUriValue, MongoDbUri, isMongoDbUri, } from './MongoDbUri.js';
|
6
6
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@marketeer-intelligence/framework-device",
|
3
|
-
"version": "0.1.0-alpha.
|
3
|
+
"version": "0.1.0-alpha.5",
|
4
4
|
"description": "framework/device layer modules for marketeer-intelligence app",
|
5
5
|
"author": "juniorCitizen1978 <juniorCitizen1978@gmail.com>",
|
6
6
|
"private": false,
|
@@ -21,7 +21,7 @@
|
|
21
21
|
"README.md"
|
22
22
|
],
|
23
23
|
"dependencies": {
|
24
|
-
"@marketeer-intelligence/infrastructure": "^0.1.0-alpha.
|
24
|
+
"@marketeer-intelligence/infrastructure": "^0.1.0-alpha.14",
|
25
25
|
"dotenv-safe": "^8.2.0",
|
26
26
|
"got": "^12.6.0",
|
27
27
|
"iconv-lite": "^0.6.3",
|
@@ -40,11 +40,11 @@
|
|
40
40
|
"eslint-config-prettier": "^8.7.0",
|
41
41
|
"prettier": "^2.8.4",
|
42
42
|
"rimraf": "^4.4.0",
|
43
|
-
"typescript": "^
|
43
|
+
"typescript": "^5.0.2"
|
44
44
|
},
|
45
45
|
"scripts": {
|
46
46
|
"prebuild": "rimraf dist",
|
47
47
|
"build": "tsc",
|
48
|
-
"
|
48
|
+
"publish-new": "npm install && npm run build && git add . && git commit -m \"update\" && git push origin main && npm publish"
|
49
49
|
}
|
50
50
|
}
|