From 9ea2660321bd171f5aaccc3c1c4e069439e4b61e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 28 Mar 2024 16:27:01 +0000 Subject: [PATCH] chore: bump version and generate documentation --- .../rita/develop_2023-11-14-10-01.json | 10 ------ .../rita/develop_2024-02-23-11-07.json | 10 ------ .../rita/develop_2024-03-28-16-19.json | 10 ------ common/config/rush/pnpm-lock.yaml | 8 ++--- .../DatabaseConnectionClosedError.html | 4 +-- .../docs/classes/DatabaseError.html | 4 +-- docs/persistent-rita/docs/classes/MySQL.html | 12 +++---- .../docs/classes/PersistentRitaLogger.html | 4 +-- .../docs/classes/Postgres.html | 12 +++---- .../docs/classes/RuleNotFoundError.html | 4 +-- .../persistent-rita/docs/classes/Ruleset.html | 12 +++---- docs/persistent-rita/docs/classes/SQLite.html | 12 +++---- .../persistent-rita/docs/classes/default.html | 16 ++++----- .../docs/interfaces/DatabaseInterface.html | 14 ++++---- .../docs/types/DatabaseConfig.html | 2 +- .../docs/implementation/classes/And.html | 12 +++---- .../docs/implementation/classes/Atom.html | 14 ++++---- .../implementation/classes/Calculation.html | 14 ++++---- .../implementation/classes/Comparison.html | 16 ++++----- .../classes/DateCalculation.html | 20 +++++------ .../classes/DefaultConsoleLogger.html | 4 +-- .../docs/implementation/classes/Formula.html | 8 ++--- .../implementation/classes/InternalError.html | 4 +-- .../docs/implementation/classes/Macro.html | 14 ++++---- .../docs/implementation/classes/Not.html | 12 +++---- .../docs/implementation/classes/Operator.html | 12 +++---- .../docs/implementation/classes/Or.html | 12 +++---- .../docs/implementation/classes/Parser.html | 34 +++++++++---------- .../docs/implementation/classes/Plugin.html | 20 +++++------ .../implementation/classes/Quantifier.html | 18 +++++----- .../docs/implementation/classes/Rule.html | 10 +++--- .../implementation/classes/RulesetError.html | 4 +-- .../classes/UndefinedPathError.html | 4 +-- .../classes/UnimplementedError.html | 4 +-- .../implementation/classes/UsageError.html | 4 +-- .../implementation/enums/comparisons.html | 4 +-- .../implementation/enums/dateOperations.html | 4 +-- .../docs/implementation/enums/operations.html | 4 +-- .../implementation/functions/evaluateAll.html | 2 +- .../functions/mapArgumentsToJSONReady.html | 2 +- .../implementation/functions/parseDate.html | 2 +- .../implementation/functions/setLogger.html | 2 +- .../implementation/interfaces/Logger.html | 4 +-- .../types/EvaluationDetails.html | 2 +- .../types/EvaluationResult.html | 2 +- .../implementation/types/FormulaResults.html | 2 +- .../implementation/types/PluginClass.html | 2 +- .../implementation/variables/logger-1.html | 2 +- .../implementation/variables/version.html | 2 +- .../DatabaseConnectionClosedError.html | 4 +-- .../docs/classes/DatabaseError.html | 4 +-- persistent-rita/docs/classes/MySQL.html | 12 +++---- .../docs/classes/PersistentRitaLogger.html | 4 +-- persistent-rita/docs/classes/Postgres.html | 12 +++---- .../docs/classes/RuleNotFoundError.html | 4 +-- persistent-rita/docs/classes/Ruleset.html | 12 +++---- persistent-rita/docs/classes/SQLite.html | 12 +++---- persistent-rita/docs/classes/default.html | 16 ++++----- .../docs/interfaces/DatabaseInterface.html | 14 ++++---- .../docs/types/DatabaseConfig.html | 2 +- persistent-rita/package.json | 4 +-- plugins/http/package.json | 4 +-- rita-core/CHANGELOG.json | 17 ++++++++++ rita-core/CHANGELOG.md | 10 +++++- .../docs/implementation/classes/And.html | 12 +++---- .../docs/implementation/classes/Atom.html | 14 ++++---- .../implementation/classes/Calculation.html | 14 ++++---- .../implementation/classes/Comparison.html | 16 ++++----- .../classes/DateCalculation.html | 20 +++++------ .../classes/DefaultConsoleLogger.html | 4 +-- .../docs/implementation/classes/Formula.html | 8 ++--- .../implementation/classes/InternalError.html | 4 +-- .../docs/implementation/classes/Macro.html | 14 ++++---- .../docs/implementation/classes/Not.html | 12 +++---- .../docs/implementation/classes/Operator.html | 12 +++---- rita-core/docs/implementation/classes/Or.html | 12 +++---- .../docs/implementation/classes/Parser.html | 34 +++++++++---------- .../docs/implementation/classes/Plugin.html | 20 +++++------ .../implementation/classes/Quantifier.html | 18 +++++----- .../docs/implementation/classes/Rule.html | 10 +++--- .../implementation/classes/RulesetError.html | 4 +-- .../classes/UndefinedPathError.html | 4 +-- .../classes/UnimplementedError.html | 4 +-- .../implementation/classes/UsageError.html | 4 +-- .../implementation/enums/comparisons.html | 4 +-- .../implementation/enums/dateOperations.html | 4 +-- .../docs/implementation/enums/operations.html | 4 +-- .../implementation/functions/evaluateAll.html | 2 +- .../functions/mapArgumentsToJSONReady.html | 2 +- .../implementation/functions/parseDate.html | 2 +- .../implementation/functions/setLogger.html | 2 +- .../implementation/interfaces/Logger.html | 4 +-- .../types/EvaluationDetails.html | 2 +- .../types/EvaluationResult.html | 2 +- .../implementation/types/FormulaResults.html | 2 +- .../implementation/types/PluginClass.html | 2 +- .../implementation/variables/logger-1.html | 2 +- .../implementation/variables/version.html | 2 +- rita-core/package.json | 2 +- rita-http/package.json | 2 +- rita-smt/main/package.json | 4 +-- 101 files changed, 410 insertions(+), 415 deletions(-) delete mode 100644 common/changes/@educorvi/rita/develop_2023-11-14-10-01.json delete mode 100644 common/changes/@educorvi/rita/develop_2024-02-23-11-07.json delete mode 100644 common/changes/@educorvi/rita/develop_2024-03-28-16-19.json diff --git a/common/changes/@educorvi/rita/develop_2023-11-14-10-01.json b/common/changes/@educorvi/rita/develop_2023-11-14-10-01.json deleted file mode 100644 index 0eac953..0000000 --- a/common/changes/@educorvi/rita/develop_2023-11-14-10-01.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "changes": [ - { - "packageName": "@educorvi/rita", - "comment": "", - "type": "none" - } - ], - "packageName": "@educorvi/rita" -} \ No newline at end of file diff --git a/common/changes/@educorvi/rita/develop_2024-02-23-11-07.json b/common/changes/@educorvi/rita/develop_2024-02-23-11-07.json deleted file mode 100644 index de01738..0000000 --- a/common/changes/@educorvi/rita/develop_2024-02-23-11-07.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "changes": [ - { - "packageName": "@educorvi/rita", - "comment": "Update dependencies", - "type": "none" - } - ], - "packageName": "@educorvi/rita" -} \ No newline at end of file diff --git a/common/changes/@educorvi/rita/develop_2024-03-28-16-19.json b/common/changes/@educorvi/rita/develop_2024-03-28-16-19.json deleted file mode 100644 index d4cf4b9..0000000 --- a/common/changes/@educorvi/rita/develop_2024-03-28-16-19.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "changes": [ - { - "packageName": "@educorvi/rita", - "comment": "Add tslib to dependencies", - "type": "patch" - } - ], - "packageName": "@educorvi/rita" -} \ No newline at end of file diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index 1e9701f..448b59d 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -24,7 +24,7 @@ importers: version: 5.1.5 devDependencies: '@educorvi/rita': - specifier: workspace:^5.0.0 + specifier: workspace:^5.0.1 version: link:../rita-core '@types/jest': specifier: ^27.0.3 @@ -73,7 +73,7 @@ importers: version: 1.6.7 devDependencies: '@educorvi/rita': - specifier: workspace:^5.0.0 + specifier: workspace:^5.0.1 version: link:../../rita-core '@types/jest': specifier: ^27.0.3 @@ -191,7 +191,7 @@ importers: specifier: workspace:^6.0.0 version: link:../persistent-rita '@educorvi/rita': - specifier: workspace:^5.0.0 + specifier: workspace:^5.0.1 version: link:../rita-core '@educorvi/rita-plugin-http': specifier: workspace:* @@ -325,7 +325,7 @@ importers: version: 9.2.0 devDependencies: '@educorvi/rita': - specifier: workspace:^5.0.0 + specifier: workspace:^5.0.1 version: link:../../rita-core '@rollup/plugin-commonjs': specifier: ^21.1.0 diff --git a/docs/persistent-rita/docs/classes/DatabaseConnectionClosedError.html b/docs/persistent-rita/docs/classes/DatabaseConnectionClosedError.html index c20395c..4015406 100644 --- a/docs/persistent-rita/docs/classes/DatabaseConnectionClosedError.html +++ b/docs/persistent-rita/docs/classes/DatabaseConnectionClosedError.html @@ -1,6 +1,6 @@ DatabaseConnectionClosedError | Persistent Rita - v6.0.0

Class DatabaseConnectionClosedError

Is thrown when a closed database connection is tried to be accessed

-

Hierarchy (view full)

Constructors

Hierarchy (view full)

Constructors

Properties

Constructors

Properties

message: string
name: string
stack?: string

Generated using TypeDoc

\ No newline at end of file +

Constructors

Properties

message: string
name: string
stack?: string

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/DatabaseError.html b/docs/persistent-rita/docs/classes/DatabaseError.html index 3df7f5b..a9cd8bf 100644 --- a/docs/persistent-rita/docs/classes/DatabaseError.html +++ b/docs/persistent-rita/docs/classes/DatabaseError.html @@ -1,6 +1,6 @@ DatabaseError | Persistent Rita - v6.0.0

Class DatabaseError

Indicates a error in the database

-

Hierarchy (view full)

Constructors

Hierarchy (view full)

Constructors

Properties

Constructors

Properties

message: string
name: string
stack?: string

Generated using TypeDoc

\ No newline at end of file +

Constructors

Properties

message: string
name: string
stack?: string

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/MySQL.html b/docs/persistent-rita/docs/classes/MySQL.html index 5a6a5e7..a6cfb7c 100644 --- a/docs/persistent-rita/docs/classes/MySQL.html +++ b/docs/persistent-rita/docs/classes/MySQL.html @@ -1,5 +1,5 @@ MySQL | Persistent Rita - v6.0.0

MySQL Adapter

-

Hierarchy

  • default
    • MySQL

Constructors

Hierarchy

  • default
    • MySQL

Constructors

Properties

Constructors

Properties

dataSource: DataSource

The connection to the database

-
repository: Repository<SQLModel>

The repository

-
db: undefined | default

The database instance (singleton pattern)

-

Methods

  • Gets the singleton database.

    +

Constructors

Properties

dataSource: DataSource

The connection to the database

+
repository: Repository<SQLModel>

The repository

+
db: undefined | default

The database instance (singleton pattern)

+

Methods

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<MySQL>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/PersistentRitaLogger.html b/docs/persistent-rita/docs/classes/PersistentRitaLogger.html index 9771a6b..7824253 100644 --- a/docs/persistent-rita/docs/classes/PersistentRitaLogger.html +++ b/docs/persistent-rita/docs/classes/PersistentRitaLogger.html @@ -1,9 +1,9 @@ PersistentRitaLogger | Persistent Rita - v6.0.0

Class PersistentRitaLoggerAbstract

A logger for Persistant Rita

-

Implements

  • Logger

Constructors

Implements

  • Logger

Constructors

Methods

Generated using TypeDoc

\ No newline at end of file +

Constructors

Methods

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/Postgres.html b/docs/persistent-rita/docs/classes/Postgres.html index 49677e2..787a5ed 100644 --- a/docs/persistent-rita/docs/classes/Postgres.html +++ b/docs/persistent-rita/docs/classes/Postgres.html @@ -1,5 +1,5 @@ Postgres | Persistent Rita - v6.0.0

Postgres Adapter

-

Hierarchy

  • default
    • Postgres

Constructors

Hierarchy

  • default
    • Postgres

Constructors

Properties

Constructors

Properties

dataSource: DataSource

The connection to the database

-
repository: Repository<SQLModel>

The repository

-
db: undefined | default

The database instance (singleton pattern)

-

Methods

  • Gets the singleton database.

    +

Constructors

Properties

dataSource: DataSource

The connection to the database

+
repository: Repository<SQLModel>

The repository

+
db: undefined | default

The database instance (singleton pattern)

+

Methods

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<Postgres>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/RuleNotFoundError.html b/docs/persistent-rita/docs/classes/RuleNotFoundError.html index 23c3d1a..760e4d2 100644 --- a/docs/persistent-rita/docs/classes/RuleNotFoundError.html +++ b/docs/persistent-rita/docs/classes/RuleNotFoundError.html @@ -1,6 +1,6 @@ RuleNotFoundError | Persistent Rita - v6.0.0

Class RuleNotFoundError

Indicates that no matching rule was found

-

Hierarchy

  • Error
    • RuleNotFoundError

Constructors

Hierarchy

  • Error
    • RuleNotFoundError

Constructors

Properties

Constructors

Properties

message: string
name: string
stack?: string

Generated using TypeDoc

\ No newline at end of file +

Constructors

Properties

message: string
name: string
stack?: string

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/Ruleset.html b/docs/persistent-rita/docs/classes/Ruleset.html index 543fe44..b7e6dc0 100644 --- a/docs/persistent-rita/docs/classes/Ruleset.html +++ b/docs/persistent-rita/docs/classes/Ruleset.html @@ -1,4 +1,4 @@ -Ruleset | Persistent Rita - v6.0.0

Constructors

constructor +Ruleset | Persistent Rita - v6.0.0

Constructors

Properties

Constructors

Properties

description: string
id: string
name: string
rules: Rule[]

Methods

  • Adds a rule to the ruleset.

    +

Constructors

Properties

description: string
id: string
name: string
rules: Rule[]

Methods

  • Deletes a rule from the ruleset.

    +

Returns void

  • Evaluates the ruleset.

    +

Returns void

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<EvaluationResult>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/SQLite.html b/docs/persistent-rita/docs/classes/SQLite.html index 7ab05d7..d9f2fe0 100644 --- a/docs/persistent-rita/docs/classes/SQLite.html +++ b/docs/persistent-rita/docs/classes/SQLite.html @@ -1,5 +1,5 @@ SQLite | Persistent Rita - v6.0.0

SQLite Adapter

-

Hierarchy

  • default
    • SQLite

Constructors

Hierarchy

  • default
    • SQLite

Constructors

Properties

Constructors

Properties

dataSource: DataSource

The connection to the database

-
repository: Repository<SQLModel>

The repository

-
db: undefined | default

The database instance (singleton pattern)

-

Methods

  • Gets the singleton database.

    +

Constructors

Properties

dataSource: DataSource

The connection to the database

+
repository: Repository<SQLModel>

The repository

+
db: undefined | default

The database instance (singleton pattern)

+

Methods

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<SQLite>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/classes/default.html b/docs/persistent-rita/docs/classes/default.html index b620e32..9fe9931 100644 --- a/docs/persistent-rita/docs/classes/default.html +++ b/docs/persistent-rita/docs/classes/default.html @@ -1,5 +1,5 @@ default | Persistent Rita - v6.0.0

Persistent Rita

-

Constructors

Constructors

Properties

Constructors

Properties

parser: default = ...
plugins: PluginClass[] = []

Methods

  • Deletes a ruleset.

    +

Constructors

Properties

parser: default = ...
plugins: PluginClass[] = []

Methods

  • Gets the ruleset with the given ID

    +

Returns Promise<void>

  • Saves a ruleset.

    +

Returns Promise<undefined | Ruleset>

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/interfaces/DatabaseInterface.html b/docs/persistent-rita/docs/interfaces/DatabaseInterface.html index 2867df9..e20dd4b 100644 --- a/docs/persistent-rita/docs/interfaces/DatabaseInterface.html +++ b/docs/persistent-rita/docs/interfaces/DatabaseInterface.html @@ -1,17 +1,17 @@ -DatabaseInterface | Persistent Rita - v6.0.0

Interface DatabaseInterface

interface DatabaseInterface {
    close(): Promise<void>;
    deleteAllRulesets(): Promise<void>;
    deleteRuleset(id): Promise<void>;
    getRuleset(id): Promise<undefined | Ruleset>;
    listRulesets(): Promise<Ruleset[]>;
    saveRuleset(id, data): Promise<void>;
}

Methods

close +DatabaseInterface | Persistent Rita - v6.0.0

Interface DatabaseInterface

interface DatabaseInterface {
    close(): Promise<void>;
    deleteAllRulesets(): Promise<void>;
    deleteRuleset(id): Promise<void>;
    getRuleset(id): Promise<undefined | Ruleset>;
    listRulesets(): Promise<Ruleset[]>;
    saveRuleset(id, data): Promise<void>;
}

Methods

  • Gets a specific ruleset by it ID. If there is no ruleset with this ID, undefined will be returned.

    +

Returns Promise<void>

  • Saves a ruleset with the given ID. If it already exists it will be updated, otherwise it will be created.

    +

Returns Promise<undefined | Ruleset>

  • Saves a ruleset with the given ID. If it already exists it will be updated, otherwise it will be created.

    Parameters

    • id: string

      The ID of the ruleset

    • data: Ruleset

      The actual ruleset

      -

    Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/persistent-rita/docs/types/DatabaseConfig.html b/docs/persistent-rita/docs/types/DatabaseConfig.html index 2e6338d..f4d6691 100644 --- a/docs/persistent-rita/docs/types/DatabaseConfig.html +++ b/docs/persistent-rita/docs/types/DatabaseConfig.html @@ -1 +1 @@ -DatabaseConfig | Persistent Rita - v6.0.0

Type alias DatabaseConfig

DatabaseConfig: {
    database: string;
    host: string;
    password?: string;
    port?: number;
    username?: string;
}

Type declaration

  • database: string
  • host: string
  • Optional password?: string
  • Optional port?: number
  • Optional username?: string

Generated using TypeDoc

\ No newline at end of file +DatabaseConfig | Persistent Rita - v6.0.0

Type alias DatabaseConfig

DatabaseConfig: {
    database: string;
    host: string;
    password?: string;
    port?: number;
    username?: string;
}

Type declaration

  • database: string
  • host: string
  • Optional password?: string
  • Optional port?: number
  • Optional username?: string

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/And.html b/docs/rita-core/docs/implementation/classes/And.html index c6c392e..e5f393c 100644 --- a/docs/rita-core/docs/implementation/classes/And.html +++ b/docs/rita-core/docs/implementation/classes/And.html @@ -1,15 +1,15 @@ And | @educorvi/rita

"And" Operator Behaves like "&&" in JavaScript when evaluated

-

Hierarchy (view full)

Constructors

Hierarchy (view full)

Constructors

Properties

arguments: Formula[]

The arguments of the operator

-

Methods

  • Evaluates the formula with the given data

    +

Returns And

Properties

arguments: Formula[]

The arguments of the operator

+

Methods

  • Parameters

    • data: Record<string, any>
    • func: ((x1, x2) => boolean)
        • (x1, x2): boolean
        • Parameters

          • x1: boolean
          • x2: boolean

          Returns boolean

    • defaultValue: Promise<boolean> = ...

    Returns Promise<boolean>

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<boolean>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Atom.html b/docs/rita-core/docs/implementation/classes/Atom.html index 0c0cdb4..d2d7a66 100644 --- a/docs/rita-core/docs/implementation/classes/Atom.html +++ b/docs/rita-core/docs/implementation/classes/Atom.html @@ -1,17 +1,17 @@ Atom | @educorvi/rita

An atom that gets it value from the data

-

Hierarchy (view full)

Constructors

Hierarchy (view full)

Constructors

Properties

isDate: boolean
path: string

The path of the value in the data

-

Methods

Constructors

Properties

isDate: boolean
path: string

The path of the value in the data

+

Methods

  • Private

    Get the value of an object property or array by a path that is passed as string

    +

Returns Promise<FormulaResults | FormulaResults[]>

  • Private

    Get the value of an object property or array by a path that is passed as string

    Parameters

    • o: any

      object

    • s: string

      path

      -

    Returns string | number | boolean

Generated using TypeDoc

\ No newline at end of file +

Returns string | number | boolean

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Calculation.html b/docs/rita-core/docs/implementation/classes/Calculation.html index 15f8d13..529b271 100644 --- a/docs/rita-core/docs/implementation/classes/Calculation.html +++ b/docs/rita-core/docs/implementation/classes/Calculation.html @@ -1,6 +1,6 @@ Calculation | @educorvi/rita

Class Calculation

Class for all calculations. Calculations are also possible with Dates (for details see schema)

-

Hierarchy (view full)

Constructors

Hierarchy (view full)

Constructors

Properties

Methods

evaluate @@ -8,10 +8,10 @@ validate

Constructors

Properties

arguments: (number | Date | Atom | DateCalculation | Calculation)[]

The arguments of the calculation

-
operation: operations

The operation of the calculation

-

Methods

  • Evaluates the formula with the given data

    +

Returns Calculation

Properties

arguments: (number | Date | Atom | DateCalculation | Calculation)[]

The arguments of the calculation

+
operation: operations

The operation of the calculation

+

Methods

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<number | Date>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Comparison.html b/docs/rita-core/docs/implementation/classes/Comparison.html index 503c6d5..5c5dcb5 100644 --- a/docs/rita-core/docs/implementation/classes/Comparison.html +++ b/docs/rita-core/docs/implementation/classes/Comparison.html @@ -1,5 +1,5 @@ Comparison | @educorvi/rita

Class Comparison

Parent class for all Comparisons

-

Hierarchy (view full)

Constructors

Hierarchy (view full)

Constructors

Properties

arguments dates operation @@ -9,11 +9,11 @@

Constructors

Properties

arguments: (string | number | Date | Atom | Calculation)[]

The arguments of the comparison

-
dates: boolean

Indicates if dates are compared

-
operation: comparisons

Type of the comparison

-

Methods

  • Evaluates the formula with the given data

    +

Returns Comparison

Properties

arguments: (string | number | Date | Atom | Calculation)[]

The arguments of the comparison

+
dates: boolean

Indicates if dates are compared

+
operation: comparisons

Type of the comparison

+

Methods

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<boolean>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/DateCalculation.html b/docs/rita-core/docs/implementation/classes/DateCalculation.html index 84d2955..ec70671 100644 --- a/docs/rita-core/docs/implementation/classes/DateCalculation.html +++ b/docs/rita-core/docs/implementation/classes/DateCalculation.html @@ -1,4 +1,4 @@ -DateCalculation | @educorvi/rita

Class DateCalculation

Hierarchy (view full)

Constructors

constructor +DateCalculation | @educorvi/rita

Class DateCalculation

Hierarchy (view full)

Constructors

Properties

  • operation: dateOperations

    The operation of the calculation

  • dateResultUnit: timeUnits = timeUnits.seconds

    The unit of the result of the calculation when calculating with dates and result is a number

  • dateCalculationUnit: timeUnits = timeUnits.seconds

    The unit to calculate when calculating with dates and numbers

    -
  • Returns DateCalculation

    Properties

    arguments: (number | Date | Atom | DateCalculation | Calculation)[]

    The arguments of the calculation

    -
    dateCalculationUnit: timeUnits

    The unit to calculate with when calculating with dates and numbers

    -
    dateResultUnit: timeUnits

    The unit of the result of the calculation when calculating with dates and result is a number

    -
    operation: dateOperations

    The operation of the calculation

    -

    Methods

    • Private

      Generates a function that can be used in an Array.reduce function as argument to reduce arguments of a calculation

      +

    Returns DateCalculation

    Properties

    arguments: (number | Date | Atom | DateCalculation | Calculation)[]

    The arguments of the calculation

    +
    dateCalculationUnit: timeUnits

    The unit to calculate with when calculating with dates and numbers

    +
    dateResultUnit: timeUnits

    The unit of the result of the calculation when calculating with dates and result is a number

    +
    operation: dateOperations

    The operation of the calculation

    +

    Methods

    • Private

      Generates a function that can be used in an Array.reduce function as argument to reduce arguments of a calculation

      Parameters

      • func: ((x1, x2) => number)

        The function of the operation that needs to be calculated

          • (x1, x2): number
          • Parameters

            • x1: number
            • x2: number

            Returns number

      Returns ((d1, d2) => Date | Duration)

        • (d1, d2): Date | Duration
        • Parameters

          • d1: Date | Duration
          • d2: Date | Duration

          Returns Date | Duration

      Example: ```typescript const tmp = someDateCalculation.arguments; - const result = tmp.splice(1).reduce(this.dateMath(func), tmp[0]);

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults | FormulaResults[]>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/DefaultConsoleLogger.html b/docs/rita-core/docs/implementation/classes/DefaultConsoleLogger.html index 56ffb3a..fdf338c 100644 --- a/docs/rita-core/docs/implementation/classes/DefaultConsoleLogger.html +++ b/docs/rita-core/docs/implementation/classes/DefaultConsoleLogger.html @@ -1,7 +1,7 @@ -DefaultConsoleLogger | @educorvi/rita

    Class DefaultConsoleLogger

    Implements

    Constructors

    constructor +DefaultConsoleLogger | @educorvi/rita

    Class DefaultConsoleLogger

    Implements

    Constructors

    Methods

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Formula.html b/docs/rita-core/docs/implementation/classes/Formula.html index dfd2cc0..f31d17e 100644 --- a/docs/rita-core/docs/implementation/classes/Formula.html +++ b/docs/rita-core/docs/implementation/classes/Formula.html @@ -1,9 +1,9 @@ -Formula | @educorvi/rita

    Class FormulaAbstract

    Hierarchy (view full)

    Constructors

    constructor +Formula | @educorvi/rita

    Class FormulaAbstract

    Hierarchy (view full)

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults | FormulaResults[]>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/InternalError.html b/docs/rita-core/docs/implementation/classes/InternalError.html index 17a7d77..8144e68 100644 --- a/docs/rita-core/docs/implementation/classes/InternalError.html +++ b/docs/rita-core/docs/implementation/classes/InternalError.html @@ -1,12 +1,12 @@ InternalError | @educorvi/rita

    Class InternalError

    There was an internal error.

    -

    Hierarchy

    • Error
      • InternalError

    Constructors

    Hierarchy

    • Error
      • InternalError

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/docs/rita-core/docs/implementation/classes/Macro.html b/docs/rita-core/docs/implementation/classes/Macro.html index 81ebfa1..aef414d 100644 --- a/docs/rita-core/docs/implementation/classes/Macro.html +++ b/docs/rita-core/docs/implementation/classes/Macro.html @@ -1,13 +1,13 @@ -Macro | @educorvi/rita

    Hierarchy (view full)

    Constructors

    constructor +Macro | @educorvi/rita

    Hierarchy (view full)

    Constructors

    Properties

    Methods

    Constructors

    Properties

    array?: Atom

    If the type of the macro is 'length', this is the Atom that contains the array *

    -
    macro: "now" | "length"

    Indicates the type of this atom *

    -

    Methods

    • Evaluates the formula with the given data

      +

    Constructors

    Properties

    array?: Atom

    If the type of the macro is 'length', this is the Atom that contains the array *

    +
    macro: "now" | "length"

    Indicates the type of this atom *

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Not.html b/docs/rita-core/docs/implementation/classes/Not.html index ace9a61..cce05d2 100644 --- a/docs/rita-core/docs/implementation/classes/Not.html +++ b/docs/rita-core/docs/implementation/classes/Not.html @@ -1,15 +1,15 @@ Not | @educorvi/rita

    "Not" Operator Behaves like "!" in JavaScript when evaluated

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Not

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Operator.html b/docs/rita-core/docs/implementation/classes/Operator.html index 5b409aa..d625f60 100644 --- a/docs/rita-core/docs/implementation/classes/Operator.html +++ b/docs/rita-core/docs/implementation/classes/Operator.html @@ -1,14 +1,14 @@ Operator | @educorvi/rita

    Class OperatorAbstract

    Parent class for all operators

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Operator

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Or.html b/docs/rita-core/docs/implementation/classes/Or.html index 4741f25..1e0d14d 100644 --- a/docs/rita-core/docs/implementation/classes/Or.html +++ b/docs/rita-core/docs/implementation/classes/Or.html @@ -1,15 +1,15 @@ Or | @educorvi/rita

    "Or" Operator Behaves like || in JavaScript when evaluated

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Or

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Parser.html b/docs/rita-core/docs/implementation/classes/Parser.html index 883dfb5..55b8aba 100644 --- a/docs/rita-core/docs/implementation/classes/Parser.html +++ b/docs/rita-core/docs/implementation/classes/Parser.html @@ -1,5 +1,5 @@ Parser | @educorvi/rita

    Class for all actions related to parsing

    -

    Constructors

    Constructors

    Properties

    Constructors

    Properties

    plugins: Map<string, PluginClass> = ...
    toJson: ((rules) => string) = Parser.toJson

    Type declaration

      • (rules): string
      • Turn an array of rule objects back into a json ruleset

        +

    Constructors

    Properties

    plugins: Map<string, PluginClass> = ...
    toJson: ((rules) => string) = Parser.toJson

    Type declaration

      • (rules): string
      • Turn an array of rule objects back into a json ruleset

        Parameters

        • rules: Rule[]

          the array of rules

          -

        Returns string

    validate: undefined | AnyValidateFunction<unknown>

    The validate function used to validate RITA Json

    -

    Methods

    • Create Atom from json

      +

    Returns string

    validate: undefined | AnyValidateFunction<unknown>

    The validate function used to validate RITA Json

    +

    Methods

    • Private

      Parse the arguments of a calculation

      +

    Returns Atom

    • Private

      Parse the arguments of a comparison

      +

    Returns (number | Atom | Calculation)[]

    • Private

      Parse the arguments of a comparison

      Parameters

      • formulaArguments: (string | number | Record<string, any>)[]

        the arguments

      • dates: boolean

        Indicates if dates are compared

        -

      Returns (string | number | Date | Atom | Calculation)[]

    • Private

      Parse the arguments of a calculation

      +

    Returns (string | number | Date | Atom | Calculation)[]

    • Private

      Parse the arguments of a calculation

      Parameters

      • formulaArguments: (string | number | Record<string, any>)[]

        the arguments

        -

      Returns (number | Date | Atom | Calculation)[]

    • Create Operator from json

      +

    Returns (number | Date | Atom | Calculation)[]

    • Create Rule from json

      +

    Returns Operator

    • Create an Array of Rule objects from a json ruleset

      +

    Returns Rule

    • Create an Array of Rule objects from a json ruleset

      Parameters

      • jsonRuleset: Record<string, any>

        the ruleset

        -

      Returns Rule[]

    • Check if a given RITA Ruleset is valid

      +

    Returns Rule[]

    • Check if a given RITA Ruleset is valid

      Parameters

      • json: Record<string, any>

        the ruleset

        -

      Returns validationResult

    • Turn an array of rule objects back into a json ruleset

      +

    Returns validationResult

    • Turn an array of rule objects back into a json ruleset

      Parameters

      • rules: Rule[]

        the array of rules

        -

      Returns string

    Generated using TypeDoc

    \ No newline at end of file +

    Returns string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Plugin.html b/docs/rita-core/docs/implementation/classes/Plugin.html index 28c2d3a..d9ea6ab 100644 --- a/docs/rita-core/docs/implementation/classes/Plugin.html +++ b/docs/rita-core/docs/implementation/classes/Plugin.html @@ -1,7 +1,7 @@ Plugin | @educorvi/rita

    Class PluginAbstract

    When a rule is evaluated, the enrichData function is called and the data to evaluate against is passed to this plugin. The plugin is supposed to create its own data (or enrich the data object that is passed to it) and return it. This new object will then be used to evaluate the formula inside the plugin

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    Methods

    Constructors

    Properties

    formula: undefined | Formula

    The formula that will be evaluated with the enriched data

    -
    options: Record<any, any>

    The options given to this plugin

    -

    Methods

    • Enriches the data for the child formula

      +

    Constructors

    Properties

    formula: undefined | Formula

    The formula that will be evaluated with the enriched data

    +
    options: Record<any, any>

    The options given to this plugin

    +

    Methods

    • Enriches the data for the child formula

      Parameters

      • data: Record<string, any>

        The original data for evaluation

      • Optional logger: Logger

        Optionally pass a logger

      Returns Promise<Record<string, any>>

      The enriched data that is then used to evaluate the child formula

      -

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults | FormulaResults[]>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Quantifier.html b/docs/rita-core/docs/implementation/classes/Quantifier.html index ae0f79b..8783b3b 100644 --- a/docs/rita-core/docs/implementation/classes/Quantifier.html +++ b/docs/rita-core/docs/implementation/classes/Quantifier.html @@ -1,4 +1,4 @@ -Quantifier | @educorvi/rita

    Class Quantifier

    Hierarchy (view full)

    Constructors

    constructor +Quantifier | @educorvi/rita

    Class Quantifier

    Hierarchy (view full)

    Constructors

    Properties

    array formula placeholder @@ -6,12 +6,12 @@

    Methods

    Constructors

    Properties

    array: Formula[] | Atom

    The of the quantifier

    -
    formula: Formula

    The formula to evaluate for each value

    -
    placeholder: string

    The property name under which the current array value will be merged into the data.

    -
    quantifier: "forall" | "exists"

    Describes which quantifier this is

    -

    Methods

    • Evaluates the formula with the given data

      +

    Constructors

    Properties

    array: Formula[] | Atom

    The of the quantifier

    +
    formula: Formula

    The formula to evaluate for each value

    +
    placeholder: string

    The property name under which the current array value will be merged into the data.

    +
    quantifier: "forall" | "exists"

    Describes which quantifier this is

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/Rule.html b/docs/rita-core/docs/implementation/classes/Rule.html index 52d2248..1ee65c2 100644 --- a/docs/rita-core/docs/implementation/classes/Rule.html +++ b/docs/rita-core/docs/implementation/classes/Rule.html @@ -1,11 +1,11 @@ Rule | @educorvi/rita

    A Rule that can be evaluated

    -

    Constructors

    Constructors

    Properties

    Methods

    Constructors

    Properties

    comment: string

    A comment about what the rule does

    -
    id: string

    The id of the rule

    -
    rule: Formula

    The root of the rule

    -

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Properties

    comment: string

    A comment about what the rule does

    +
    id: string

    The id of the rule

    +
    rule: Formula

    The root of the rule

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/classes/RulesetError.html b/docs/rita-core/docs/implementation/classes/RulesetError.html index acb9931..1bb33cc 100644 --- a/docs/rita-core/docs/implementation/classes/RulesetError.html +++ b/docs/rita-core/docs/implementation/classes/RulesetError.html @@ -1,12 +1,12 @@ RulesetError | @educorvi/rita

    Class RulesetError

    There is an error in the ruleset

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/docs/rita-core/docs/implementation/classes/UndefinedPathError.html b/docs/rita-core/docs/implementation/classes/UndefinedPathError.html index f507ef8..9c154ac 100644 --- a/docs/rita-core/docs/implementation/classes/UndefinedPathError.html +++ b/docs/rita-core/docs/implementation/classes/UndefinedPathError.html @@ -1,12 +1,12 @@ UndefinedPathError | @educorvi/rita

    Class UndefinedPathError

    A path into the data was invalid

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/docs/rita-core/docs/implementation/classes/UnimplementedError.html b/docs/rita-core/docs/implementation/classes/UnimplementedError.html index c8803fa..dee21cd 100644 --- a/docs/rita-core/docs/implementation/classes/UnimplementedError.html +++ b/docs/rita-core/docs/implementation/classes/UnimplementedError.html @@ -1,12 +1,12 @@ UnimplementedError | @educorvi/rita

    Class UnimplementedError

    Tried to use a function that does not exist/is not yet implemented

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/docs/rita-core/docs/implementation/classes/UsageError.html b/docs/rita-core/docs/implementation/classes/UsageError.html index 21f4d09..2f951a4 100644 --- a/docs/rita-core/docs/implementation/classes/UsageError.html +++ b/docs/rita-core/docs/implementation/classes/UsageError.html @@ -1,12 +1,12 @@ UsageError | @educorvi/rita

    Class UsageError

    Indicates that the package is used in a wrong way

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/docs/rita-core/docs/implementation/enums/comparisons.html b/docs/rita-core/docs/implementation/enums/comparisons.html index 97c3b61..a857fbe 100644 --- a/docs/rita-core/docs/implementation/enums/comparisons.html +++ b/docs/rita-core/docs/implementation/enums/comparisons.html @@ -1,7 +1,7 @@ comparisons | @educorvi/rita

    Enumeration comparisons

    Types of comparisons

    -

    Enumeration Members

    Enumeration Members

    equal: "equal"
    greater: "greater"
    greaterOrEqual: "greaterOrEqual"
    smaller: "smaller"
    smallerOrEqual: "smallerOrEqual"

    Generated using TypeDoc

    \ No newline at end of file +

    Enumeration Members

    equal: "equal"
    greater: "greater"
    greaterOrEqual: "greaterOrEqual"
    smaller: "smaller"
    smallerOrEqual: "smallerOrEqual"

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/enums/dateOperations.html b/docs/rita-core/docs/implementation/enums/dateOperations.html index 7ff27b3..b5b6653 100644 --- a/docs/rita-core/docs/implementation/enums/dateOperations.html +++ b/docs/rita-core/docs/implementation/enums/dateOperations.html @@ -1,3 +1,3 @@ -dateOperations | @educorvi/rita

    Enumeration dateOperations

    Enumeration Members

    add +dateOperations | @educorvi/rita

    Generated using TypeDoc

    \ No newline at end of file +

    Enumeration Members

    add: "add"
    subtract: "subtract"

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/enums/operations.html b/docs/rita-core/docs/implementation/enums/operations.html index b53c643..4b90eb3 100644 --- a/docs/rita-core/docs/implementation/enums/operations.html +++ b/docs/rita-core/docs/implementation/enums/operations.html @@ -1,7 +1,7 @@ operations | @educorvi/rita

    Enumeration operations

    Mathematical operations

    -

    Enumeration Members

    add +

    Enumeration Members

    Enumeration Members

    add: "add"
    divide: "divide"
    modulo: "modulo"
    multiply: "multiply"
    subtract: "subtract"

    Generated using TypeDoc

    \ No newline at end of file +

    Enumeration Members

    add: "add"
    divide: "divide"
    modulo: "modulo"
    multiply: "multiply"
    subtract: "subtract"

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/functions/evaluateAll.html b/docs/rita-core/docs/implementation/functions/evaluateAll.html index 814f376..d61a5ba 100644 --- a/docs/rita-core/docs/implementation/functions/evaluateAll.html +++ b/docs/rita-core/docs/implementation/functions/evaluateAll.html @@ -1,2 +1,2 @@ evaluateAll | @educorvi/rita

    Function evaluateAll

    Generated using TypeDoc

    \ No newline at end of file +

    Parameters

    Returns Promise<EvaluationResult>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html b/docs/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html index b8cb244..01f33a5 100644 --- a/docs/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html +++ b/docs/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html @@ -1,4 +1,4 @@ mapArgumentsToJSONReady | @educorvi/rita

    Function mapArgumentsToJSONReady

    • A function that is supposed to be used as argument for the Array.map() function, to map arguments to their rita-json ready counterparts.

      Parameters

      • item: string | number | Date | Formula

        The item to be mapped

      Returns string | number | Record<string, any>

      Example: ```typescript - const jsonArguments = someCalculation.arguments.map(mapParameterToJSONReady);

    Generated using TypeDoc

    \ No newline at end of file + const jsonArguments = someCalculation.arguments.map(mapParameterToJSONReady);

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/functions/parseDate.html b/docs/rita-core/docs/implementation/functions/parseDate.html index 7a08c31..5083ebf 100644 --- a/docs/rita-core/docs/implementation/functions/parseDate.html +++ b/docs/rita-core/docs/implementation/functions/parseDate.html @@ -1,3 +1,3 @@ parseDate | @educorvi/rita

    Function parseDate

    • Parses the date in the argument string. Throws an exception if date can not be parsed

      Parameters

      • val: string

        the string to be parsed

        -

      Returns Date

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Date

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/functions/setLogger.html b/docs/rita-core/docs/implementation/functions/setLogger.html index bc7519b..a3247d3 100644 --- a/docs/rita-core/docs/implementation/functions/setLogger.html +++ b/docs/rita-core/docs/implementation/functions/setLogger.html @@ -1 +1 @@ -setLogger | @educorvi/rita

    Function setLogger

    Generated using TypeDoc

    \ No newline at end of file +setLogger | @educorvi/rita

    Function setLogger

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/interfaces/Logger.html b/docs/rita-core/docs/implementation/interfaces/Logger.html index e378f24..ac6b6af 100644 --- a/docs/rita-core/docs/implementation/interfaces/Logger.html +++ b/docs/rita-core/docs/implementation/interfaces/Logger.html @@ -1,6 +1,6 @@ -Logger | @educorvi/rita

    Interface Logger

    interface Logger {
        debug(data): void;
        error(data): void;
        fatal(data): void;
        log(data): void;
        warn(data): void;
    }

    Implemented by

    Methods

    debug +Logger | @educorvi/rita

    Interface Logger

    interface Logger {
        debug(data): void;
        error(data): void;
        fatal(data): void;
        log(data): void;
        warn(data): void;
    }

    Implemented by

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/types/EvaluationDetails.html b/docs/rita-core/docs/implementation/types/EvaluationDetails.html index 953d1b2..6d393cd 100644 --- a/docs/rita-core/docs/implementation/types/EvaluationDetails.html +++ b/docs/rita-core/docs/implementation/types/EvaluationDetails.html @@ -1,3 +1,3 @@ EvaluationDetails | @educorvi/rita

    Type alias EvaluationDetails

    EvaluationDetails: {
        id: string;
        result: boolean;
    }

    Type declaration

    • id: string

      The ID of the rule

    • result: boolean

      The result of the rule

      -

    Generated using TypeDoc

    \ No newline at end of file +

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/types/EvaluationResult.html b/docs/rita-core/docs/implementation/types/EvaluationResult.html index 90dbb9e..f55f905 100644 --- a/docs/rita-core/docs/implementation/types/EvaluationResult.html +++ b/docs/rita-core/docs/implementation/types/EvaluationResult.html @@ -1,4 +1,4 @@ EvaluationResult | @educorvi/rita

    Type alias EvaluationResult

    EvaluationResult: {
        counts: {
            false: number;
            true: number;
        };
        details: EvaluationDetails[];
        result: boolean;
    }

    Type declaration

    • counts: {
          false: number;
          true: number;
      }

      Amount of rules that were evaluated to true or false respectively.

      • false: number
      • true: number
    • details: EvaluationDetails[]

      The results for every rule

    • result: boolean

      The result of all rules combined (combined by logical "and")

      -

    Generated using TypeDoc

    \ No newline at end of file +

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/types/FormulaResults.html b/docs/rita-core/docs/implementation/types/FormulaResults.html index c420333..909b99d 100644 --- a/docs/rita-core/docs/implementation/types/FormulaResults.html +++ b/docs/rita-core/docs/implementation/types/FormulaResults.html @@ -1 +1 @@ -FormulaResults | @educorvi/rita

    Type alias FormulaResults

    FormulaResults: boolean | Date | number | string

    Generated using TypeDoc

    \ No newline at end of file +FormulaResults | @educorvi/rita

    Type alias FormulaResults

    FormulaResults: boolean | Date | number | string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/types/PluginClass.html b/docs/rita-core/docs/implementation/types/PluginClass.html index a5a76a5..99a3261 100644 --- a/docs/rita-core/docs/implementation/types/PluginClass.html +++ b/docs/rita-core/docs/implementation/types/PluginClass.html @@ -1,2 +1,2 @@ PluginClass | @educorvi/rita

    Type alias PluginClass

    PluginClass: (new (options, childFormula) => Plugin)

    Type of class that extends Plugin

    -

    Type declaration

      • new (options, childFormula): Plugin
      • Parameters

        • options: Record<any, any>
        • childFormula: undefined | Formula

        Returns Plugin

    Generated using TypeDoc

    \ No newline at end of file +

    Type declaration

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/variables/logger-1.html b/docs/rita-core/docs/implementation/variables/logger-1.html index 23905ef..a62c494 100644 --- a/docs/rita-core/docs/implementation/variables/logger-1.html +++ b/docs/rita-core/docs/implementation/variables/logger-1.html @@ -1 +1 @@ -logger | @educorvi/rita

    Variable logger

    logger: Logger = ...

    Generated using TypeDoc

    \ No newline at end of file +logger | @educorvi/rita

    Variable logger

    logger: Logger = ...

    Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/rita-core/docs/implementation/variables/version.html b/docs/rita-core/docs/implementation/variables/version.html index e560b4a..f58d18f 100644 --- a/docs/rita-core/docs/implementation/variables/version.html +++ b/docs/rita-core/docs/implementation/variables/version.html @@ -1 +1 @@ -version | @educorvi/rita

    Variable versionConst

    version: undefined | string = process.env.VERSION

    Generated using TypeDoc

    \ No newline at end of file +version | @educorvi/rita

    Variable versionConst

    version: undefined | string = process.env.VERSION

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/DatabaseConnectionClosedError.html b/persistent-rita/docs/classes/DatabaseConnectionClosedError.html index c20395c..4015406 100644 --- a/persistent-rita/docs/classes/DatabaseConnectionClosedError.html +++ b/persistent-rita/docs/classes/DatabaseConnectionClosedError.html @@ -1,6 +1,6 @@ DatabaseConnectionClosedError | Persistent Rita - v6.0.0

    Class DatabaseConnectionClosedError

    Is thrown when a closed database connection is tried to be accessed

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    Constructors

    Properties

    message: string
    name: string
    stack?: string

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Properties

    message: string
    name: string
    stack?: string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/DatabaseError.html b/persistent-rita/docs/classes/DatabaseError.html index 3df7f5b..a9cd8bf 100644 --- a/persistent-rita/docs/classes/DatabaseError.html +++ b/persistent-rita/docs/classes/DatabaseError.html @@ -1,6 +1,6 @@ DatabaseError | Persistent Rita - v6.0.0

    Class DatabaseError

    Indicates a error in the database

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    Constructors

    Properties

    message: string
    name: string
    stack?: string

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Properties

    message: string
    name: string
    stack?: string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/MySQL.html b/persistent-rita/docs/classes/MySQL.html index 5a6a5e7..a6cfb7c 100644 --- a/persistent-rita/docs/classes/MySQL.html +++ b/persistent-rita/docs/classes/MySQL.html @@ -1,5 +1,5 @@ MySQL | Persistent Rita - v6.0.0

    MySQL Adapter

    -

    Hierarchy

    • default
      • MySQL

    Constructors

    Hierarchy

    • default
      • MySQL

    Constructors

    Properties

    Constructors

    Properties

    dataSource: DataSource

    The connection to the database

    -
    repository: Repository<SQLModel>

    The repository

    -
    db: undefined | default

    The database instance (singleton pattern)

    -

    Methods

    • Gets the singleton database.

      +

    Constructors

    Properties

    dataSource: DataSource

    The connection to the database

    +
    repository: Repository<SQLModel>

    The repository

    +
    db: undefined | default

    The database instance (singleton pattern)

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<MySQL>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/PersistentRitaLogger.html b/persistent-rita/docs/classes/PersistentRitaLogger.html index 9771a6b..7824253 100644 --- a/persistent-rita/docs/classes/PersistentRitaLogger.html +++ b/persistent-rita/docs/classes/PersistentRitaLogger.html @@ -1,9 +1,9 @@ PersistentRitaLogger | Persistent Rita - v6.0.0

    Class PersistentRitaLoggerAbstract

    A logger for Persistant Rita

    -

    Implements

    • Logger

    Constructors

    Implements

    • Logger

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/Postgres.html b/persistent-rita/docs/classes/Postgres.html index 49677e2..787a5ed 100644 --- a/persistent-rita/docs/classes/Postgres.html +++ b/persistent-rita/docs/classes/Postgres.html @@ -1,5 +1,5 @@ Postgres | Persistent Rita - v6.0.0

    Postgres Adapter

    -

    Hierarchy

    • default
      • Postgres

    Constructors

    Hierarchy

    • default
      • Postgres

    Constructors

    Properties

    Constructors

    Properties

    dataSource: DataSource

    The connection to the database

    -
    repository: Repository<SQLModel>

    The repository

    -
    db: undefined | default

    The database instance (singleton pattern)

    -

    Methods

    • Gets the singleton database.

      +

    Constructors

    Properties

    dataSource: DataSource

    The connection to the database

    +
    repository: Repository<SQLModel>

    The repository

    +
    db: undefined | default

    The database instance (singleton pattern)

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<Postgres>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/RuleNotFoundError.html b/persistent-rita/docs/classes/RuleNotFoundError.html index 23c3d1a..760e4d2 100644 --- a/persistent-rita/docs/classes/RuleNotFoundError.html +++ b/persistent-rita/docs/classes/RuleNotFoundError.html @@ -1,6 +1,6 @@ RuleNotFoundError | Persistent Rita - v6.0.0

    Class RuleNotFoundError

    Indicates that no matching rule was found

    -

    Hierarchy

    • Error
      • RuleNotFoundError

    Constructors

    Hierarchy

    • Error
      • RuleNotFoundError

    Constructors

    Properties

    Constructors

    Properties

    message: string
    name: string
    stack?: string

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Properties

    message: string
    name: string
    stack?: string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/Ruleset.html b/persistent-rita/docs/classes/Ruleset.html index 543fe44..b7e6dc0 100644 --- a/persistent-rita/docs/classes/Ruleset.html +++ b/persistent-rita/docs/classes/Ruleset.html @@ -1,4 +1,4 @@ -Ruleset | Persistent Rita - v6.0.0

    Constructors

    constructor +Ruleset | Persistent Rita - v6.0.0

    Constructors

    Properties

    Constructors

    Properties

    description: string
    id: string
    name: string
    rules: Rule[]

    Methods

    • Adds a rule to the ruleset.

      +

    Constructors

    Properties

    description: string
    id: string
    name: string
    rules: Rule[]

    Methods

    • Deletes a rule from the ruleset.

      +

    Returns void

    • Evaluates the ruleset.

      +

    Returns void

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<EvaluationResult>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/SQLite.html b/persistent-rita/docs/classes/SQLite.html index 7ab05d7..d9f2fe0 100644 --- a/persistent-rita/docs/classes/SQLite.html +++ b/persistent-rita/docs/classes/SQLite.html @@ -1,5 +1,5 @@ SQLite | Persistent Rita - v6.0.0

    SQLite Adapter

    -

    Hierarchy

    • default
      • SQLite

    Constructors

    Hierarchy

    • default
      • SQLite

    Constructors

    Properties

    Constructors

    Properties

    dataSource: DataSource

    The connection to the database

    -
    repository: Repository<SQLModel>

    The repository

    -
    db: undefined | default

    The database instance (singleton pattern)

    -

    Methods

    • Gets the singleton database.

      +

    Constructors

    Properties

    dataSource: DataSource

    The connection to the database

    +
    repository: Repository<SQLModel>

    The repository

    +
    db: undefined | default

    The database instance (singleton pattern)

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<SQLite>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/classes/default.html b/persistent-rita/docs/classes/default.html index b620e32..9fe9931 100644 --- a/persistent-rita/docs/classes/default.html +++ b/persistent-rita/docs/classes/default.html @@ -1,5 +1,5 @@ default | Persistent Rita - v6.0.0

    Persistent Rita

    -

    Constructors

    Constructors

    Properties

    Constructors

    Properties

    parser: default = ...
    plugins: PluginClass[] = []

    Methods

    • Deletes a ruleset.

      +

    Constructors

    Properties

    parser: default = ...
    plugins: PluginClass[] = []

    Methods

    • Gets the ruleset with the given ID

      +

    Returns Promise<void>

    • Saves a ruleset.

      +

    Returns Promise<undefined | Ruleset>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<void>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/interfaces/DatabaseInterface.html b/persistent-rita/docs/interfaces/DatabaseInterface.html index 2867df9..e20dd4b 100644 --- a/persistent-rita/docs/interfaces/DatabaseInterface.html +++ b/persistent-rita/docs/interfaces/DatabaseInterface.html @@ -1,17 +1,17 @@ -DatabaseInterface | Persistent Rita - v6.0.0

    Interface DatabaseInterface

    interface DatabaseInterface {
        close(): Promise<void>;
        deleteAllRulesets(): Promise<void>;
        deleteRuleset(id): Promise<void>;
        getRuleset(id): Promise<undefined | Ruleset>;
        listRulesets(): Promise<Ruleset[]>;
        saveRuleset(id, data): Promise<void>;
    }

    Methods

    close +DatabaseInterface | Persistent Rita - v6.0.0

    Interface DatabaseInterface

    interface DatabaseInterface {
        close(): Promise<void>;
        deleteAllRulesets(): Promise<void>;
        deleteRuleset(id): Promise<void>;
        getRuleset(id): Promise<undefined | Ruleset>;
        listRulesets(): Promise<Ruleset[]>;
        saveRuleset(id, data): Promise<void>;
    }

    Methods

    • Gets a specific ruleset by it ID. If there is no ruleset with this ID, undefined will be returned.

      +

    Returns Promise<void>

    • Saves a ruleset with the given ID. If it already exists it will be updated, otherwise it will be created.

      +

    Returns Promise<undefined | Ruleset>

    • Saves a ruleset with the given ID. If it already exists it will be updated, otherwise it will be created.

      Parameters

      • id: string

        The ID of the ruleset

      • data: Ruleset

        The actual ruleset

        -

      Returns Promise<void>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<void>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/docs/types/DatabaseConfig.html b/persistent-rita/docs/types/DatabaseConfig.html index 2e6338d..f4d6691 100644 --- a/persistent-rita/docs/types/DatabaseConfig.html +++ b/persistent-rita/docs/types/DatabaseConfig.html @@ -1 +1 @@ -DatabaseConfig | Persistent Rita - v6.0.0

    Type alias DatabaseConfig

    DatabaseConfig: {
        database: string;
        host: string;
        password?: string;
        port?: number;
        username?: string;
    }

    Type declaration

    • database: string
    • host: string
    • Optional password?: string
    • Optional port?: number
    • Optional username?: string

    Generated using TypeDoc

    \ No newline at end of file +DatabaseConfig | Persistent Rita - v6.0.0

    Type alias DatabaseConfig

    DatabaseConfig: {
        database: string;
        host: string;
        password?: string;
        port?: number;
        username?: string;
    }

    Type declaration

    • database: string
    • host: string
    • Optional password?: string
    • Optional port?: number
    • Optional username?: string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/persistent-rita/package.json b/persistent-rita/package.json index 7dfd787..5b95a09 100644 --- a/persistent-rita/package.json +++ b/persistent-rita/package.json @@ -27,7 +27,7 @@ "reflect-metadata": "^0.2.1" }, "devDependencies": { - "@educorvi/rita": "workspace:^5.0.0", + "@educorvi/rita": "workspace:^5.0.1", "@types/jest": "^27.0.3", "dotenv": "^16.4.5", "jest": "^27.4.5", @@ -43,7 +43,7 @@ "webpack-node-externals": "^3.0.0" }, "peerDependencies": { - "@educorvi/rita": "^5.0.0", + "@educorvi/rita": "^5.0.1", "mysql2": "^3.6.5", "pg": "^8.7.1", "sqlite3": "^5.0.6", diff --git a/plugins/http/package.json b/plugins/http/package.json index 0703576..63ea197 100644 --- a/plugins/http/package.json +++ b/plugins/http/package.json @@ -25,7 +25,7 @@ }, "homepage": "https://github.com/educorvi/rita/tree/develop/plugins/http#readme", "devDependencies": { - "@educorvi/rita": "workspace:^5.0.0", + "@educorvi/rita": "workspace:^5.0.1", "@types/jest": "^27.0.3", "@types/node": "^17.0.35", "express": "^4.18.2", @@ -41,7 +41,7 @@ "ts-jest": "^27.0.7" }, "peerDependencies": { - "@educorvi/rita": "^5.0.0" + "@educorvi/rita": "^5.0.1" }, "dependencies": { "axios": "^1.6.7" diff --git a/rita-core/CHANGELOG.json b/rita-core/CHANGELOG.json index 1bb7d99..cdbaa39 100644 --- a/rita-core/CHANGELOG.json +++ b/rita-core/CHANGELOG.json @@ -1,6 +1,23 @@ { "name": "@educorvi/rita", "entries": [ + { + "version": "5.0.1", + "tag": "@educorvi/rita_v5.0.1", + "date": "Thu, 28 Mar 2024 16:26:46 GMT", + "comments": { + "none": [ + { + "comment": "Update dependencies" + } + ], + "patch": [ + { + "comment": "Add tslib to dependencies" + } + ] + } + }, { "version": "5.0.0", "tag": "@educorvi/rita_v5.0.0", diff --git a/rita-core/CHANGELOG.md b/rita-core/CHANGELOG.md index a911fae..2899e01 100644 --- a/rita-core/CHANGELOG.md +++ b/rita-core/CHANGELOG.md @@ -1,6 +1,14 @@ # Change Log - @educorvi/rita -This log was last generated on Tue, 14 Mar 2023 19:16:22 GMT and should not be manually modified. +This log was last generated on Thu, 28 Mar 2024 16:26:46 GMT and should not be manually modified. + +## 5.0.1 + +Thu, 28 Mar 2024 16:26:46 GMT + +### Patches + +- Add tslib to dependencies ## 5.0.0 diff --git a/rita-core/docs/implementation/classes/And.html b/rita-core/docs/implementation/classes/And.html index c6c392e..e5f393c 100644 --- a/rita-core/docs/implementation/classes/And.html +++ b/rita-core/docs/implementation/classes/And.html @@ -1,15 +1,15 @@ And | @educorvi/rita

    "And" Operator Behaves like "&&" in JavaScript when evaluated

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns And

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Atom.html b/rita-core/docs/implementation/classes/Atom.html index 0c0cdb4..d2d7a66 100644 --- a/rita-core/docs/implementation/classes/Atom.html +++ b/rita-core/docs/implementation/classes/Atom.html @@ -1,17 +1,17 @@ Atom | @educorvi/rita

    An atom that gets it value from the data

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    isDate: boolean
    path: string

    The path of the value in the data

    -

    Methods

    Constructors

    Properties

    isDate: boolean
    path: string

    The path of the value in the data

    +

    Methods

    • Private

      Get the value of an object property or array by a path that is passed as string

      +

    Returns Promise<FormulaResults | FormulaResults[]>

    • Private

      Get the value of an object property or array by a path that is passed as string

      Parameters

      • o: any

        object

      • s: string

        path

        -

      Returns string | number | boolean

    Generated using TypeDoc

    \ No newline at end of file +

    Returns string | number | boolean

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Calculation.html b/rita-core/docs/implementation/classes/Calculation.html index 15f8d13..529b271 100644 --- a/rita-core/docs/implementation/classes/Calculation.html +++ b/rita-core/docs/implementation/classes/Calculation.html @@ -1,6 +1,6 @@ Calculation | @educorvi/rita

    Class Calculation

    Class for all calculations. Calculations are also possible with Dates (for details see schema)

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    Methods

    evaluate @@ -8,10 +8,10 @@ validate

    Constructors

    Properties

    arguments: (number | Date | Atom | DateCalculation | Calculation)[]

    The arguments of the calculation

    -
    operation: operations

    The operation of the calculation

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Calculation

    Properties

    arguments: (number | Date | Atom | DateCalculation | Calculation)[]

    The arguments of the calculation

    +
    operation: operations

    The operation of the calculation

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<number | Date>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Comparison.html b/rita-core/docs/implementation/classes/Comparison.html index 503c6d5..5c5dcb5 100644 --- a/rita-core/docs/implementation/classes/Comparison.html +++ b/rita-core/docs/implementation/classes/Comparison.html @@ -1,5 +1,5 @@ Comparison | @educorvi/rita

    Class Comparison

    Parent class for all Comparisons

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments dates operation @@ -9,11 +9,11 @@

    Constructors

    Properties

    arguments: (string | number | Date | Atom | Calculation)[]

    The arguments of the comparison

    -
    dates: boolean

    Indicates if dates are compared

    -
    operation: comparisons

    Type of the comparison

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Comparison

    Properties

    arguments: (string | number | Date | Atom | Calculation)[]

    The arguments of the comparison

    +
    dates: boolean

    Indicates if dates are compared

    +
    operation: comparisons

    Type of the comparison

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/DateCalculation.html b/rita-core/docs/implementation/classes/DateCalculation.html index 84d2955..ec70671 100644 --- a/rita-core/docs/implementation/classes/DateCalculation.html +++ b/rita-core/docs/implementation/classes/DateCalculation.html @@ -1,4 +1,4 @@ -DateCalculation | @educorvi/rita

    Class DateCalculation

    Hierarchy (view full)

    Constructors

    constructor +DateCalculation | @educorvi/rita

    Class DateCalculation

    Hierarchy (view full)

    Constructors

    Properties

  • operation: dateOperations

    The operation of the calculation

  • dateResultUnit: timeUnits = timeUnits.seconds

    The unit of the result of the calculation when calculating with dates and result is a number

  • dateCalculationUnit: timeUnits = timeUnits.seconds

    The unit to calculate when calculating with dates and numbers

    -
  • Returns DateCalculation

    Properties

    arguments: (number | Date | Atom | DateCalculation | Calculation)[]

    The arguments of the calculation

    -
    dateCalculationUnit: timeUnits

    The unit to calculate with when calculating with dates and numbers

    -
    dateResultUnit: timeUnits

    The unit of the result of the calculation when calculating with dates and result is a number

    -
    operation: dateOperations

    The operation of the calculation

    -

    Methods

    • Private

      Generates a function that can be used in an Array.reduce function as argument to reduce arguments of a calculation

      +

    Returns DateCalculation

    Properties

    arguments: (number | Date | Atom | DateCalculation | Calculation)[]

    The arguments of the calculation

    +
    dateCalculationUnit: timeUnits

    The unit to calculate with when calculating with dates and numbers

    +
    dateResultUnit: timeUnits

    The unit of the result of the calculation when calculating with dates and result is a number

    +
    operation: dateOperations

    The operation of the calculation

    +

    Methods

    • Private

      Generates a function that can be used in an Array.reduce function as argument to reduce arguments of a calculation

      Parameters

      • func: ((x1, x2) => number)

        The function of the operation that needs to be calculated

          • (x1, x2): number
          • Parameters

            • x1: number
            • x2: number

            Returns number

      Returns ((d1, d2) => Date | Duration)

        • (d1, d2): Date | Duration
        • Parameters

          • d1: Date | Duration
          • d2: Date | Duration

          Returns Date | Duration

      Example: ```typescript const tmp = someDateCalculation.arguments; - const result = tmp.splice(1).reduce(this.dateMath(func), tmp[0]);

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults | FormulaResults[]>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/DefaultConsoleLogger.html b/rita-core/docs/implementation/classes/DefaultConsoleLogger.html index 56ffb3a..fdf338c 100644 --- a/rita-core/docs/implementation/classes/DefaultConsoleLogger.html +++ b/rita-core/docs/implementation/classes/DefaultConsoleLogger.html @@ -1,7 +1,7 @@ -DefaultConsoleLogger | @educorvi/rita

    Class DefaultConsoleLogger

    Implements

    Constructors

    constructor +DefaultConsoleLogger | @educorvi/rita

    Class DefaultConsoleLogger

    Implements

    Constructors

    Methods

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Formula.html b/rita-core/docs/implementation/classes/Formula.html index dfd2cc0..f31d17e 100644 --- a/rita-core/docs/implementation/classes/Formula.html +++ b/rita-core/docs/implementation/classes/Formula.html @@ -1,9 +1,9 @@ -Formula | @educorvi/rita

    Class FormulaAbstract

    Hierarchy (view full)

    Constructors

    constructor +Formula | @educorvi/rita

    Class FormulaAbstract

    Hierarchy (view full)

    Constructors

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults | FormulaResults[]>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/InternalError.html b/rita-core/docs/implementation/classes/InternalError.html index 17a7d77..8144e68 100644 --- a/rita-core/docs/implementation/classes/InternalError.html +++ b/rita-core/docs/implementation/classes/InternalError.html @@ -1,12 +1,12 @@ InternalError | @educorvi/rita

    Class InternalError

    There was an internal error.

    -

    Hierarchy

    • Error
      • InternalError

    Constructors

    Hierarchy

    • Error
      • InternalError

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/rita-core/docs/implementation/classes/Macro.html b/rita-core/docs/implementation/classes/Macro.html index 81ebfa1..aef414d 100644 --- a/rita-core/docs/implementation/classes/Macro.html +++ b/rita-core/docs/implementation/classes/Macro.html @@ -1,13 +1,13 @@ -Macro | @educorvi/rita

    Hierarchy (view full)

    Constructors

    constructor +Macro | @educorvi/rita

    Hierarchy (view full)

    Constructors

    Properties

    Methods

    Constructors

    Properties

    array?: Atom

    If the type of the macro is 'length', this is the Atom that contains the array *

    -
    macro: "now" | "length"

    Indicates the type of this atom *

    -

    Methods

    • Evaluates the formula with the given data

      +

    Constructors

    Properties

    array?: Atom

    If the type of the macro is 'length', this is the Atom that contains the array *

    +
    macro: "now" | "length"

    Indicates the type of this atom *

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Not.html b/rita-core/docs/implementation/classes/Not.html index ace9a61..cce05d2 100644 --- a/rita-core/docs/implementation/classes/Not.html +++ b/rita-core/docs/implementation/classes/Not.html @@ -1,15 +1,15 @@ Not | @educorvi/rita

    "Not" Operator Behaves like "!" in JavaScript when evaluated

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Not

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Operator.html b/rita-core/docs/implementation/classes/Operator.html index 5b409aa..d625f60 100644 --- a/rita-core/docs/implementation/classes/Operator.html +++ b/rita-core/docs/implementation/classes/Operator.html @@ -1,14 +1,14 @@ Operator | @educorvi/rita

    Class OperatorAbstract

    Parent class for all operators

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Operator

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Or.html b/rita-core/docs/implementation/classes/Or.html index 4741f25..1e0d14d 100644 --- a/rita-core/docs/implementation/classes/Or.html +++ b/rita-core/docs/implementation/classes/Or.html @@ -1,15 +1,15 @@ Or | @educorvi/rita

    "Or" Operator Behaves like || in JavaScript when evaluated

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    arguments: Formula[]

    The arguments of the operator

    -

    Methods

    • Evaluates the formula with the given data

      +

    Returns Or

    Properties

    arguments: Formula[]

    The arguments of the operator

    +

    Methods

    • Parameters

      • data: Record<string, any>
      • func: ((x1, x2) => boolean)
          • (x1, x2): boolean
          • Parameters

            • x1: boolean
            • x2: boolean

            Returns boolean

      • defaultValue: Promise<boolean> = ...

      Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Parser.html b/rita-core/docs/implementation/classes/Parser.html index 883dfb5..55b8aba 100644 --- a/rita-core/docs/implementation/classes/Parser.html +++ b/rita-core/docs/implementation/classes/Parser.html @@ -1,5 +1,5 @@ Parser | @educorvi/rita

    Class for all actions related to parsing

    -

    Constructors

    Constructors

    Properties

    Constructors

    Properties

    plugins: Map<string, PluginClass> = ...
    toJson: ((rules) => string) = Parser.toJson

    Type declaration

      • (rules): string
      • Turn an array of rule objects back into a json ruleset

        +

    Constructors

    Properties

    plugins: Map<string, PluginClass> = ...
    toJson: ((rules) => string) = Parser.toJson

    Type declaration

      • (rules): string
      • Turn an array of rule objects back into a json ruleset

        Parameters

        • rules: Rule[]

          the array of rules

          -

        Returns string

    validate: undefined | AnyValidateFunction<unknown>

    The validate function used to validate RITA Json

    -

    Methods

    • Create Atom from json

      +

    Returns string

    validate: undefined | AnyValidateFunction<unknown>

    The validate function used to validate RITA Json

    +

    Methods

    • Private

      Parse the arguments of a calculation

      +

    Returns Atom

    • Private

      Parse the arguments of a comparison

      +

    Returns (number | Atom | Calculation)[]

    • Private

      Parse the arguments of a comparison

      Parameters

      • formulaArguments: (string | number | Record<string, any>)[]

        the arguments

      • dates: boolean

        Indicates if dates are compared

        -

      Returns (string | number | Date | Atom | Calculation)[]

    • Private

      Parse the arguments of a calculation

      +

    Returns (string | number | Date | Atom | Calculation)[]

    • Private

      Parse the arguments of a calculation

      Parameters

      • formulaArguments: (string | number | Record<string, any>)[]

        the arguments

        -

      Returns (number | Date | Atom | Calculation)[]

    • Create Operator from json

      +

    Returns (number | Date | Atom | Calculation)[]

    • Create Rule from json

      +

    Returns Operator

    • Create an Array of Rule objects from a json ruleset

      +

    Returns Rule

    • Create an Array of Rule objects from a json ruleset

      Parameters

      • jsonRuleset: Record<string, any>

        the ruleset

        -

      Returns Rule[]

    • Check if a given RITA Ruleset is valid

      +

    Returns Rule[]

    • Check if a given RITA Ruleset is valid

      Parameters

      • json: Record<string, any>

        the ruleset

        -

      Returns validationResult

    • Turn an array of rule objects back into a json ruleset

      +

    Returns validationResult

    • Turn an array of rule objects back into a json ruleset

      Parameters

      • rules: Rule[]

        the array of rules

        -

      Returns string

    Generated using TypeDoc

    \ No newline at end of file +

    Returns string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Plugin.html b/rita-core/docs/implementation/classes/Plugin.html index 28c2d3a..d9ea6ab 100644 --- a/rita-core/docs/implementation/classes/Plugin.html +++ b/rita-core/docs/implementation/classes/Plugin.html @@ -1,7 +1,7 @@ Plugin | @educorvi/rita

    Class PluginAbstract

    When a rule is evaluated, the enrichData function is called and the data to evaluate against is passed to this plugin. The plugin is supposed to create its own data (or enrich the data object that is passed to it) and return it. This new object will then be used to evaluate the formula inside the plugin

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    Methods

    Constructors

    Properties

    formula: undefined | Formula

    The formula that will be evaluated with the enriched data

    -
    options: Record<any, any>

    The options given to this plugin

    -

    Methods

    • Enriches the data for the child formula

      +

    Constructors

    Properties

    formula: undefined | Formula

    The formula that will be evaluated with the enriched data

    +
    options: Record<any, any>

    The options given to this plugin

    +

    Methods

    • Enriches the data for the child formula

      Parameters

      • data: Record<string, any>

        The original data for evaluation

      • Optional logger: Logger

        Optionally pass a logger

      Returns Promise<Record<string, any>>

      The enriched data that is then used to evaluate the child formula

      -

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<FormulaResults | FormulaResults[]>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Quantifier.html b/rita-core/docs/implementation/classes/Quantifier.html index ae0f79b..8783b3b 100644 --- a/rita-core/docs/implementation/classes/Quantifier.html +++ b/rita-core/docs/implementation/classes/Quantifier.html @@ -1,4 +1,4 @@ -Quantifier | @educorvi/rita

    Class Quantifier

    Hierarchy (view full)

    Constructors

    constructor +Quantifier | @educorvi/rita

    Class Quantifier

    Hierarchy (view full)

    Constructors

    Properties

    array formula placeholder @@ -6,12 +6,12 @@

    Methods

    Constructors

    Properties

    array: Formula[] | Atom

    The of the quantifier

    -
    formula: Formula

    The formula to evaluate for each value

    -
    placeholder: string

    The property name under which the current array value will be merged into the data.

    -
    quantifier: "forall" | "exists"

    Describes which quantifier this is

    -

    Methods

    • Evaluates the formula with the given data

      +

    Constructors

    Properties

    array: Formula[] | Atom

    The of the quantifier

    +
    formula: Formula

    The formula to evaluate for each value

    +
    placeholder: string

    The property name under which the current array value will be merged into the data.

    +
    quantifier: "forall" | "exists"

    Describes which quantifier this is

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Promise<boolean>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/Rule.html b/rita-core/docs/implementation/classes/Rule.html index 52d2248..1ee65c2 100644 --- a/rita-core/docs/implementation/classes/Rule.html +++ b/rita-core/docs/implementation/classes/Rule.html @@ -1,11 +1,11 @@ Rule | @educorvi/rita

    A Rule that can be evaluated

    -

    Constructors

    Constructors

    Properties

    Methods

    Constructors

    Properties

    comment: string

    A comment about what the rule does

    -
    id: string

    The id of the rule

    -
    rule: Formula

    The root of the rule

    -

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Constructors

    Properties

    comment: string

    A comment about what the rule does

    +
    id: string

    The id of the rule

    +
    rule: Formula

    The root of the rule

    +

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/classes/RulesetError.html b/rita-core/docs/implementation/classes/RulesetError.html index acb9931..1bb33cc 100644 --- a/rita-core/docs/implementation/classes/RulesetError.html +++ b/rita-core/docs/implementation/classes/RulesetError.html @@ -1,12 +1,12 @@ RulesetError | @educorvi/rita

    Class RulesetError

    There is an error in the ruleset

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/rita-core/docs/implementation/classes/UndefinedPathError.html b/rita-core/docs/implementation/classes/UndefinedPathError.html index f507ef8..9c154ac 100644 --- a/rita-core/docs/implementation/classes/UndefinedPathError.html +++ b/rita-core/docs/implementation/classes/UndefinedPathError.html @@ -1,12 +1,12 @@ UndefinedPathError | @educorvi/rita

    Class UndefinedPathError

    A path into the data was invalid

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/rita-core/docs/implementation/classes/UnimplementedError.html b/rita-core/docs/implementation/classes/UnimplementedError.html index c8803fa..dee21cd 100644 --- a/rita-core/docs/implementation/classes/UnimplementedError.html +++ b/rita-core/docs/implementation/classes/UnimplementedError.html @@ -1,12 +1,12 @@ UnimplementedError | @educorvi/rita

    Class UnimplementedError

    Tried to use a function that does not exist/is not yet implemented

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/rita-core/docs/implementation/classes/UsageError.html b/rita-core/docs/implementation/classes/UsageError.html index 21f4d09..2f951a4 100644 --- a/rita-core/docs/implementation/classes/UsageError.html +++ b/rita-core/docs/implementation/classes/UsageError.html @@ -1,12 +1,12 @@ UsageError | @educorvi/rita

    Class UsageError

    Indicates that the package is used in a wrong way

    -

    Hierarchy (view full)

    Constructors

    Hierarchy (view full)

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    +

    Constructors

    Properties

    message: string
    name: string
    stack?: string
    prepareStackTrace?: ((err, stackTraces) => any)

    Optional override for formatting stack traces

    Type declaration

    See

    https://v8.dev/docs/stack-trace-api#customizing-stack-traces

    diff --git a/rita-core/docs/implementation/enums/comparisons.html b/rita-core/docs/implementation/enums/comparisons.html index 97c3b61..a857fbe 100644 --- a/rita-core/docs/implementation/enums/comparisons.html +++ b/rita-core/docs/implementation/enums/comparisons.html @@ -1,7 +1,7 @@ comparisons | @educorvi/rita

    Enumeration comparisons

    Types of comparisons

    -

    Enumeration Members

    Enumeration Members

    equal: "equal"
    greater: "greater"
    greaterOrEqual: "greaterOrEqual"
    smaller: "smaller"
    smallerOrEqual: "smallerOrEqual"

    Generated using TypeDoc

    \ No newline at end of file +

    Enumeration Members

    equal: "equal"
    greater: "greater"
    greaterOrEqual: "greaterOrEqual"
    smaller: "smaller"
    smallerOrEqual: "smallerOrEqual"

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/enums/dateOperations.html b/rita-core/docs/implementation/enums/dateOperations.html index 7ff27b3..b5b6653 100644 --- a/rita-core/docs/implementation/enums/dateOperations.html +++ b/rita-core/docs/implementation/enums/dateOperations.html @@ -1,3 +1,3 @@ -dateOperations | @educorvi/rita

    Enumeration dateOperations

    Enumeration Members

    add +dateOperations | @educorvi/rita

    Generated using TypeDoc

    \ No newline at end of file +

    Enumeration Members

    add: "add"
    subtract: "subtract"

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/enums/operations.html b/rita-core/docs/implementation/enums/operations.html index b53c643..4b90eb3 100644 --- a/rita-core/docs/implementation/enums/operations.html +++ b/rita-core/docs/implementation/enums/operations.html @@ -1,7 +1,7 @@ operations | @educorvi/rita

    Enumeration operations

    Mathematical operations

    -

    Enumeration Members

    add +

    Enumeration Members

    Enumeration Members

    add: "add"
    divide: "divide"
    modulo: "modulo"
    multiply: "multiply"
    subtract: "subtract"

    Generated using TypeDoc

    \ No newline at end of file +

    Enumeration Members

    add: "add"
    divide: "divide"
    modulo: "modulo"
    multiply: "multiply"
    subtract: "subtract"

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/functions/evaluateAll.html b/rita-core/docs/implementation/functions/evaluateAll.html index 814f376..d61a5ba 100644 --- a/rita-core/docs/implementation/functions/evaluateAll.html +++ b/rita-core/docs/implementation/functions/evaluateAll.html @@ -1,2 +1,2 @@ evaluateAll | @educorvi/rita

    Function evaluateAll

    Generated using TypeDoc

    \ No newline at end of file +

    Parameters

    Returns Promise<EvaluationResult>

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html b/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html index b8cb244..01f33a5 100644 --- a/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html +++ b/rita-core/docs/implementation/functions/mapArgumentsToJSONReady.html @@ -1,4 +1,4 @@ mapArgumentsToJSONReady | @educorvi/rita

    Function mapArgumentsToJSONReady

    • A function that is supposed to be used as argument for the Array.map() function, to map arguments to their rita-json ready counterparts.

      Parameters

      • item: string | number | Date | Formula

        The item to be mapped

      Returns string | number | Record<string, any>

      Example: ```typescript - const jsonArguments = someCalculation.arguments.map(mapParameterToJSONReady);

    Generated using TypeDoc

    \ No newline at end of file + const jsonArguments = someCalculation.arguments.map(mapParameterToJSONReady);

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/functions/parseDate.html b/rita-core/docs/implementation/functions/parseDate.html index 7a08c31..5083ebf 100644 --- a/rita-core/docs/implementation/functions/parseDate.html +++ b/rita-core/docs/implementation/functions/parseDate.html @@ -1,3 +1,3 @@ parseDate | @educorvi/rita

    Function parseDate

    • Parses the date in the argument string. Throws an exception if date can not be parsed

      Parameters

      • val: string

        the string to be parsed

        -

      Returns Date

    Generated using TypeDoc

    \ No newline at end of file +

    Returns Date

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/functions/setLogger.html b/rita-core/docs/implementation/functions/setLogger.html index bc7519b..a3247d3 100644 --- a/rita-core/docs/implementation/functions/setLogger.html +++ b/rita-core/docs/implementation/functions/setLogger.html @@ -1 +1 @@ -setLogger | @educorvi/rita

    Function setLogger

    Generated using TypeDoc

    \ No newline at end of file +setLogger | @educorvi/rita

    Function setLogger

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/interfaces/Logger.html b/rita-core/docs/implementation/interfaces/Logger.html index e378f24..ac6b6af 100644 --- a/rita-core/docs/implementation/interfaces/Logger.html +++ b/rita-core/docs/implementation/interfaces/Logger.html @@ -1,6 +1,6 @@ -Logger | @educorvi/rita

    Interface Logger

    interface Logger {
        debug(data): void;
        error(data): void;
        fatal(data): void;
        log(data): void;
        warn(data): void;
    }

    Implemented by

    Methods

    debug +Logger | @educorvi/rita

    Interface Logger

    interface Logger {
        debug(data): void;
        error(data): void;
        fatal(data): void;
        log(data): void;
        warn(data): void;
    }

    Implemented by

    Methods

    Generated using TypeDoc

    \ No newline at end of file +

    Methods

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/types/EvaluationDetails.html b/rita-core/docs/implementation/types/EvaluationDetails.html index 953d1b2..6d393cd 100644 --- a/rita-core/docs/implementation/types/EvaluationDetails.html +++ b/rita-core/docs/implementation/types/EvaluationDetails.html @@ -1,3 +1,3 @@ EvaluationDetails | @educorvi/rita

    Type alias EvaluationDetails

    EvaluationDetails: {
        id: string;
        result: boolean;
    }

    Type declaration

    • id: string

      The ID of the rule

    • result: boolean

      The result of the rule

      -

    Generated using TypeDoc

    \ No newline at end of file +

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/types/EvaluationResult.html b/rita-core/docs/implementation/types/EvaluationResult.html index 90dbb9e..f55f905 100644 --- a/rita-core/docs/implementation/types/EvaluationResult.html +++ b/rita-core/docs/implementation/types/EvaluationResult.html @@ -1,4 +1,4 @@ EvaluationResult | @educorvi/rita

    Type alias EvaluationResult

    EvaluationResult: {
        counts: {
            false: number;
            true: number;
        };
        details: EvaluationDetails[];
        result: boolean;
    }

    Type declaration

    • counts: {
          false: number;
          true: number;
      }

      Amount of rules that were evaluated to true or false respectively.

      • false: number
      • true: number
    • details: EvaluationDetails[]

      The results for every rule

    • result: boolean

      The result of all rules combined (combined by logical "and")

      -

    Generated using TypeDoc

    \ No newline at end of file +

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/types/FormulaResults.html b/rita-core/docs/implementation/types/FormulaResults.html index c420333..909b99d 100644 --- a/rita-core/docs/implementation/types/FormulaResults.html +++ b/rita-core/docs/implementation/types/FormulaResults.html @@ -1 +1 @@ -FormulaResults | @educorvi/rita

    Type alias FormulaResults

    FormulaResults: boolean | Date | number | string

    Generated using TypeDoc

    \ No newline at end of file +FormulaResults | @educorvi/rita

    Type alias FormulaResults

    FormulaResults: boolean | Date | number | string

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/types/PluginClass.html b/rita-core/docs/implementation/types/PluginClass.html index a5a76a5..99a3261 100644 --- a/rita-core/docs/implementation/types/PluginClass.html +++ b/rita-core/docs/implementation/types/PluginClass.html @@ -1,2 +1,2 @@ PluginClass | @educorvi/rita

    Type alias PluginClass

    PluginClass: (new (options, childFormula) => Plugin)

    Type of class that extends Plugin

    -

    Type declaration

      • new (options, childFormula): Plugin
      • Parameters

        • options: Record<any, any>
        • childFormula: undefined | Formula

        Returns Plugin

    Generated using TypeDoc

    \ No newline at end of file +

    Type declaration

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/variables/logger-1.html b/rita-core/docs/implementation/variables/logger-1.html index 23905ef..a62c494 100644 --- a/rita-core/docs/implementation/variables/logger-1.html +++ b/rita-core/docs/implementation/variables/logger-1.html @@ -1 +1 @@ -logger | @educorvi/rita

    Variable logger

    logger: Logger = ...

    Generated using TypeDoc

    \ No newline at end of file +logger | @educorvi/rita

    Variable logger

    logger: Logger = ...

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/docs/implementation/variables/version.html b/rita-core/docs/implementation/variables/version.html index e560b4a..f58d18f 100644 --- a/rita-core/docs/implementation/variables/version.html +++ b/rita-core/docs/implementation/variables/version.html @@ -1 +1 @@ -version | @educorvi/rita

    Variable versionConst

    version: undefined | string = process.env.VERSION

    Generated using TypeDoc

    \ No newline at end of file +version | @educorvi/rita

    Variable versionConst

    version: undefined | string = process.env.VERSION

    Generated using TypeDoc

    \ No newline at end of file diff --git a/rita-core/package.json b/rita-core/package.json index 1fffdb9..ea95c47 100644 --- a/rita-core/package.json +++ b/rita-core/package.json @@ -1,6 +1,6 @@ { "name": "@educorvi/rita", - "version": "5.0.0", + "version": "5.0.1", "description": "JSON Schema for rules that can be used to evaluate data and a Typescript implementation to evaluate those rules", "bugs": { "url": "https://github.com/educorvi/rita/issues" diff --git a/rita-http/package.json b/rita-http/package.json index 6ac52cc..750cc72 100644 --- a/rita-http/package.json +++ b/rita-http/package.json @@ -38,7 +38,7 @@ }, "dependencies": { "@educorvi/persistent-rita": "workspace:^6.0.0", - "@educorvi/rita": "workspace:^5.0.0", + "@educorvi/rita": "workspace:^5.0.1", "@educorvi/rita-plugin-http": "workspace:*", "@tsoa/runtime": "^5.0.0", "body-parser": "^1.20.2", diff --git a/rita-smt/main/package.json b/rita-smt/main/package.json index ba50f57..cc9c120 100644 --- a/rita-smt/main/package.json +++ b/rita-smt/main/package.json @@ -25,7 +25,7 @@ "commander": "^9.2.0" }, "devDependencies": { - "@educorvi/rita": "workspace:^5.0.0", + "@educorvi/rita": "workspace:^5.0.1", "@rollup/plugin-commonjs": "^21.1.0", "@rollup/plugin-json": "^4.1.0", "@rollup/plugin-node-resolve": "^13.1.3", @@ -48,6 +48,6 @@ "@types/jest": "^27.0.3" }, "peerDependencies": { - "@educorvi/rita": "^5.0.0" + "@educorvi/rita": "^5.0.1" } }