first commit
This commit is contained in:
14
src/models/Get.ts
Normal file
14
src/models/Get.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
type Query = {
|
||||
depth: number;
|
||||
};
|
||||
|
||||
type Get = {
|
||||
uuid?: string;
|
||||
path?: string;
|
||||
type?: string;
|
||||
rights?: string;
|
||||
value?: undefined;
|
||||
query?: Query;
|
||||
};
|
||||
|
||||
export type Gets = Get[];
|
10
src/models/Light.ts
Normal file
10
src/models/Light.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
export type Light = {
|
||||
State: boolean;
|
||||
Brightness: number;
|
||||
Red: number;
|
||||
Green: number;
|
||||
Blue: number;
|
||||
White: number;
|
||||
Amber: number;
|
||||
Purple: number;
|
||||
};
|
11
src/models/MovingHead.ts
Normal file
11
src/models/MovingHead.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
export type MovingHead = {
|
||||
State: boolean;
|
||||
Brightness: number;
|
||||
Red: number;
|
||||
Green: number;
|
||||
Blue: number;
|
||||
White: number;
|
||||
Zoom: number;
|
||||
Pan: number;
|
||||
Tilt: number;
|
||||
};
|
8
src/models/Publish.ts
Normal file
8
src/models/Publish.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
export type Publish = {
|
||||
event: string;
|
||||
uuid?: string;
|
||||
path?: string;
|
||||
type?: string;
|
||||
value?: undefined;
|
||||
};
|
||||
export type Pubs = Publish[];
|
10
src/models/Request.ts
Normal file
10
src/models/Request.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import type { Gets } from './Get';
|
||||
import type { Sets } from './Set';
|
||||
import type { Subs } from './Subscribe';
|
||||
|
||||
export type Request = {
|
||||
get?: Gets;
|
||||
set?: Sets;
|
||||
subscribe?: Subs;
|
||||
unsubscribe?: Subs;
|
||||
};
|
11
src/models/Response.ts
Normal file
11
src/models/Response.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import type { Gets } from './Get';
|
||||
import type { Sets } from './Set';
|
||||
import type { Subs } from './Subscribe';
|
||||
import type { Pubs } from './Publish';
|
||||
|
||||
export type Response = {
|
||||
get?: Gets;
|
||||
set?: Sets;
|
||||
subscribe?: Subs;
|
||||
publish?: Pubs;
|
||||
};
|
6
src/models/Set.ts
Normal file
6
src/models/Set.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
type Set = {
|
||||
path: string;
|
||||
value: number | undefined;
|
||||
};
|
||||
|
||||
export type Sets = Set[];
|
8
src/models/Subscribe.ts
Normal file
8
src/models/Subscribe.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
export type Subscribe = {
|
||||
uuid?: string;
|
||||
path?: string;
|
||||
depth?: number;
|
||||
value?: string | undefined;
|
||||
};
|
||||
|
||||
export type Subs = Subscribe[];
|
Reference in New Issue
Block a user