2024-05-11 16:23:52 +02:00
|
|
|
syntax = "proto3";
|
|
|
|
|
|
|
|
package hyperlog;
|
|
|
|
|
|
|
|
service Graph {
|
2024-05-11 23:23:00 +02:00
|
|
|
rpc Get(GetRequest) returns (GetReply);
|
2024-05-11 16:23:52 +02:00
|
|
|
}
|
|
|
|
|
2024-05-11 23:23:00 +02:00
|
|
|
|
|
|
|
message UserGraphItem {
|
|
|
|
map<string, GraphItem> items = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
message SectionGraphItem {
|
|
|
|
map<string, GraphItem> items = 1;
|
|
|
|
}
|
|
|
|
|
2024-05-12 12:58:54 +02:00
|
|
|
message ItemStateNotDone {}
|
|
|
|
message ItemStateDone {}
|
2024-05-11 23:23:00 +02:00
|
|
|
|
|
|
|
message ItemGraphItem {
|
|
|
|
string title = 1;
|
|
|
|
string description = 2;
|
2024-05-12 12:58:54 +02:00
|
|
|
oneof item_state {
|
|
|
|
ItemStateNotDone not_done = 3;
|
|
|
|
ItemStateDone done = 4;
|
|
|
|
}
|
2024-05-11 23:23:00 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
message GraphItem {
|
|
|
|
string path = 1;
|
|
|
|
oneof contents {
|
|
|
|
UserGraphItem user = 2;
|
|
|
|
SectionGraphItem section = 3;
|
|
|
|
ItemGraphItem item = 4;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
message GetRequest {
|
|
|
|
string root = 1;
|
|
|
|
repeated string paths = 2;
|
2024-05-11 16:23:52 +02:00
|
|
|
}
|
|
|
|
|
2024-05-11 23:23:00 +02:00
|
|
|
message GetReply {
|
2024-05-12 12:58:54 +02:00
|
|
|
GraphItem item = 1;
|
2024-05-11 16:23:52 +02:00
|
|
|
}
|
|
|
|
|