2019-11-22 17:58:13 +02:00
|
|
|
///
|
2023-01-31 10:43:56 +02:00
|
|
|
/// Copyright © 2016-2023 The Thingsboard Authors
|
2019-11-22 17:58:13 +02:00
|
|
|
///
|
|
|
|
|
/// Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
|
/// you may not use this file except in compliance with the License.
|
|
|
|
|
/// You may obtain a copy of the License at
|
|
|
|
|
///
|
|
|
|
|
/// http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
///
|
|
|
|
|
/// Unless required by applicable law or agreed to in writing, software
|
|
|
|
|
/// distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
|
/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
|
/// See the License for the specific language governing permissions and
|
|
|
|
|
/// limitations under the License.
|
|
|
|
|
///
|
|
|
|
|
|
|
|
|
|
import { RuleNodeType } from '@shared/models/rule-node.models';
|
|
|
|
|
|
|
|
|
|
export enum ComponentType {
|
|
|
|
|
ENRICHMENT = 'ENRICHMENT',
|
|
|
|
|
FILTER = 'FILTER',
|
|
|
|
|
TRANSFORMATION = 'TRANSFORMATION',
|
|
|
|
|
ACTION = 'ACTION',
|
2021-12-08 15:35:59 +02:00
|
|
|
EXTERNAL = 'EXTERNAL',
|
|
|
|
|
FLOW = 'FLOW'
|
2019-11-22 17:58:13 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export enum ComponentScope {
|
|
|
|
|
SYSTEM = 'SYSTEM',
|
|
|
|
|
TENANT = 'TENANT'
|
|
|
|
|
}
|
|
|
|
|
|
2023-04-24 13:49:57 +02:00
|
|
|
export enum ComponentClusteringMode {
|
|
|
|
|
USER_PREFERENCE = 'USER_PREFERENCE',
|
|
|
|
|
ENABLED = 'ENABLED',
|
|
|
|
|
SINGLETON = 'SINGLETON'
|
2023-04-20 16:07:14 +02:00
|
|
|
}
|
|
|
|
|
|
2019-11-22 17:58:13 +02:00
|
|
|
export interface ComponentDescriptor {
|
|
|
|
|
type: ComponentType | RuleNodeType;
|
|
|
|
|
scope?: ComponentScope;
|
2023-04-24 13:49:57 +02:00
|
|
|
clusteringMode: ComponentClusteringMode;
|
2019-11-22 17:58:13 +02:00
|
|
|
name: string;
|
|
|
|
|
clazz: string;
|
|
|
|
|
configurationDescriptor?: any;
|
|
|
|
|
actions?: string;
|
|
|
|
|
}
|