Skip to content

Instantly share code, notes, and snippets.

@t404
Last active November 27, 2020 03:59
Show Gist options
  • Save t404/14f883d069a4051a393f9d48e7cf19be to your computer and use it in GitHub Desktop.
Save t404/14f883d069a4051a393f9d48e7cf19be to your computer and use it in GitHub Desktop.
[proto import 外部文件] #grpc #proto
// proto/device/device.proto
syntax = "proto3";
package device;
import "list.proto";
import "pointer.proto";
import "device_group.proto";
import "thing/property.proto";
syntax = "proto3";
package core.thing;
enum EnumThingType {
UNKNOW = 0;
EDGE_THING = 1;
END_THING = 2;
}
//模型下属性 事件 服务类型
enum EnumThingMetaType {
UNKNOW_THING = 0;
SYS_THING = 1;
USER_THING = 2;
}
//子类型
enum EnumIsSysThingType {
UNKNOW_SYSTEM_THING = 0;
SYSTEM_THING = 1;
COMMON_THING = 2;
}
//子类型
enum EnumSysThingType {
UNKNOW_SYS = 0;
SYS_COMMON_THING = 1;
SYS_THING_OPC_TYPE = 2;
SYS_VIDEO_THING = 10;
SYS_VIDEO_IPC = 11;
SYS_VIDEO_NVR = 12;
}
enum EnumMetaType {
UNKNOW_TYPE = 0;
INT32 = 1;
FLOAT = 2;
DOUBLE = 3;
STRING = 4;
ENUM = 5;
ARRAY = 6;
BOOL = 7;
STRUCT = 8;
DATE = 9;
}
enum EnumRightType {
ALL = 0;
READ = 1;
WRITE = 2;
}
enum EnumServiceType {
SYNC = 0;
ASYNC = 1;
}
enum EnumEventType {
INFO = 0;
WARNING = 1;
ERROR = 2;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment