@comunica/core
Advanced tools
Comparing version 1.15.0 to 1.17.0
@@ -10,3 +10,3 @@ "use strict"; | ||
var __exportStar = (this && this.__exportStar) || function(m, exports) { | ||
for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); | ||
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); | ||
}; | ||
@@ -13,0 +13,0 @@ Object.defineProperty(exports, "__esModule", { value: true }); |
@@ -1,3 +0,3 @@ | ||
import { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import { Bus } from './Bus'; | ||
import type { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import type { Bus } from './Bus'; | ||
/** | ||
@@ -4,0 +4,0 @@ * An ActionObserver can passively listen to {@link Actor#run} inputs and outputs for all actors on a certain bus. |
import { Map } from 'immutable'; | ||
import { Bus } from './Bus'; | ||
import { Logger } from './Logger'; | ||
import type { Bus } from './Bus'; | ||
import type { Logger } from './Logger'; | ||
/** | ||
@@ -84,9 +84,9 @@ * An actor can act on messages of certain types and provide output of a certain type. | ||
deinitialize(): Promise<any>; | ||
protected getDefaultLogData(context: ActionContext | undefined, data?: any): any; | ||
protected logTrace(context: ActionContext | undefined, message: string, data?: any): void; | ||
protected logDebug(context: ActionContext | undefined, message: string, data?: any): void; | ||
protected logInfo(context: ActionContext | undefined, message: string, data?: any): void; | ||
protected logWarn(context: ActionContext | undefined, message: string, data?: any): void; | ||
protected logError(context: ActionContext | undefined, message: string, data?: any): void; | ||
protected logFatal(context: ActionContext | undefined, message: string, data?: any): void; | ||
protected getDefaultLogData(context: ActionContext | undefined, data?: (() => any)): any; | ||
protected logTrace(context: ActionContext | undefined, message: string, data?: (() => any)): void; | ||
protected logDebug(context: ActionContext | undefined, message: string, data?: (() => any)): void; | ||
protected logInfo(context: ActionContext | undefined, message: string, data?: (() => any)): void; | ||
protected logWarn(context: ActionContext | undefined, message: string, data?: (() => any)): void; | ||
protected logError(context: ActionContext | undefined, message: string, data?: (() => any)): void; | ||
protected logFatal(context: ActionContext | undefined, message: string, data?: (() => any)): void; | ||
} | ||
@@ -93,0 +93,0 @@ export interface IActorArgs<I extends IAction, T extends IActorTest, O extends IActorOutput> { |
@@ -84,7 +84,5 @@ "use strict"; | ||
getDefaultLogData(context, data) { | ||
if (!data) { | ||
data = {}; | ||
} | ||
data.actor = this.name; | ||
return data; | ||
const dataActual = data ? data() : {}; | ||
dataActual.actor = this.name; | ||
return dataActual; | ||
} | ||
@@ -135,2 +133,3 @@ logTrace(context, message, data) { | ||
*/ | ||
// eslint-disable-next-line no-redeclare | ||
function ActionContext(hash) { | ||
@@ -137,0 +136,0 @@ return immutable_1.Map(hash); |
@@ -1,3 +0,3 @@ | ||
import { ActionObserver } from './ActionObserver'; | ||
import { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import type { ActionObserver } from './ActionObserver'; | ||
import type { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
/** | ||
@@ -4,0 +4,0 @@ * A publish-subscribe bus for sending actions to actors |
@@ -1,3 +0,4 @@ | ||
import { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import { Bus, IActorReply, IBusArgs } from './Bus'; | ||
import type { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import type { IActorReply, IBusArgs } from './Bus'; | ||
import { Bus } from './Bus'; | ||
/** | ||
@@ -4,0 +5,0 @@ * A bus that indexes identified actors, |
@@ -1,3 +0,3 @@ | ||
import { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import { Bus, IActorReply } from './Bus'; | ||
import type { Actor, IAction, IActorOutput, IActorTest } from './Actor'; | ||
import type { Bus, IActorReply } from './Bus'; | ||
/** | ||
@@ -4,0 +4,0 @@ * A mediator can mediate an action over a bus of actors. |
{ | ||
"name": "@comunica/core", | ||
"version": "1.15.0", | ||
"version": "1.17.0", | ||
"description": "Lightweight, semantic and modular actor framework", | ||
@@ -18,3 +18,7 @@ "lsd:module": "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/core", | ||
"typings": "index", | ||
"repository": "https://github.com/comunica/comunica/tree/master/packages/core", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/comunica/comunica.git", | ||
"directory": "packages/core" | ||
}, | ||
"publishConfig": { | ||
@@ -34,3 +38,3 @@ "access": "public" | ||
}, | ||
"homepage": "https://github.com/comunica/comunica#readme", | ||
"homepage": "https://comunica.dev/", | ||
"files": [ | ||
@@ -68,3 +72,3 @@ "components", | ||
}, | ||
"gitHead": "d71011b99f9fb5d125822fd42e75db6868ef4a64" | ||
"gitHead": "cea13b435ebbda09e0ad359f54d3c62077fe3bba" | ||
} |
@@ -5,6 +5,11 @@ # Comunica Core | ||
The core framework of Comunica, which consists of a mediatable publish-subscribe actor system. | ||
The core framework of Comunica, which consists of a **actors**, **buses**, and **mediators**. | ||
This module is part of the [Comunica framework](https://github.com/comunica/comunica). | ||
**[Click here to learn more about this core architecture](https://comunica.dev/docs/modify/advanced/architecture_core/).** | ||
This module is part of the [Comunica framework](https://github.com/comunica/comunica), | ||
and should only be used by [developers that want to build their own query engine](https://comunica.dev/docs/modify/). | ||
[Click here if you just want to query with Comunica](https://comunica.dev/docs/query/). | ||
## Install | ||
@@ -16,4 +21,9 @@ | ||
## Usage | ||
## Exported classes | ||
TODO | ||
* [`Actor`](https://comunica.github.io/comunica/classes/core.actor-1.html): An actor can act on messages of certain types and provide output of a certain type. | ||
* [`Bus`](https://comunica.github.io/comunica/classes/core.bus-1.html): A publish-subscribe bus for sending actions to actors to test whether or not they can run an action. | ||
* [`Mediator`](https://comunica.github.io/comunica/classes/core.mediator-1.html): A mediator can mediate an action over a bus of actors. | ||
* [`ActionObserver`](https://comunica.github.io/comunica/classes/core.actionobserver-1.html): An ActionObserver can passively listen to Actor.run inputs and outputs for all actors on a certain bus. | ||
* [`BusIndexed`](https://comunica.github.io/comunica/classes/core.busindexed-1.html): A bus that indexes identified actors, so that actions with a corresponding identifier can be published more efficiently. | ||
* [`Logger`](https://comunica.github.io/comunica/classes/core.logger-1.html): A logger accepts messages from different levels and emits them in a certain way. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
51794
28
2