syntax = "proto3";

package hiku.protobuf.query;

message RepeatedString {
  repeated string items = 1;
}

message RepeatedInteger {
  repeated sint32 items = 1;
}

message Option {
  oneof value {
    string string = 1;
    sint32 integer = 2;
    RepeatedString repeated_string = 3;
    RepeatedInteger repeated_integer = 4;
  }
}

message Field {
  string name = 1;
  map<string, Option> options = 2;
}

message Link {
  string name = 1;
  Node node = 2;
  map<string, Option> options = 3;
}

message Item {
  oneof value {
    Field field = 1;
    Link link = 2;
  }
}

message Node {
  repeated Item items = 1;
}
