Skip to content

Commit

Permalink
Merge pull request #26 from Green-Software-Foundation/rename-interface
Browse files Browse the repository at this point in the history
Rename interface
  • Loading branch information
narekhovhannisyan authored Oct 3, 2024
2 parents 1dd048a + 33a6fc1 commit 6db2e4e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
1 change: 0 additions & 1 deletion src/interfaces/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ export const PluginFactory =
mapping: MappingParams
) => ({
metadata: {
kind: 'execute',
// Handles empty metadata
inputs: {...params.metadata && params.metadata.inputs || {}, ...parametersMetadata?.inputs},
outputs: parametersMetadata?.outputs || params.metadata && params.metadata.outputs || {},
Expand Down
15 changes: 1 addition & 14 deletions src/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,12 @@ export type RandIntGeneratorParams = {

/** Interface */
export type PluginParams = Record<string, any>;
export type ExecutePlugin = {
export type PluginInterface = {
execute: (
inputs: PluginParams[],
config?: Record<string, any>
) => PluginParams[] | Promise<PluginParams[]>;
metadata: {
kind: string;
inputs?: ParameterMetadata;
outputs?: ParameterMetadata;
};
Expand Down Expand Up @@ -94,18 +93,6 @@ export type TimeParams = {
export type ConfigParams = Record<string, any>;
export type MappingParams = Record<string, string>;

/** Group-by */
export type GroupByPlugin = {
execute: (inputs: PluginParams[], config: GroupByConfig) => {children: any};
metadata: {
kind: string;
};
[key: string]: any;
};

export type GroupByConfig = {
group: string[];
};

export type ArithmeticParameters = {
config: any;
Expand Down

0 comments on commit 6db2e4e

Please sign in to comment.