syntax = "proto3"; import "google/protobuf/wrappers.proto"; package entities.schema; // Plain enumerations enum EntityStatus { STATUS_A = 0; STATUS_B = 1; STATUS_C = 2; } enum EntityType { TYPE_A = 0; TYPE_B = 1; TYPE_C = 2; } // Entity with scalars message ScalarEntity { uint32 uint32_f = 1; int32 int32_f= 2; bool bool_f = 4; string string_f = 5; int64 int64_f = 6; uint64 uint64_f = 7; bytes bytes_f = 8; float float_f = 9; double double_f = 10; EntityStatus status = 11; EntityType type = 12; } message NestedEntity { ScalarEntity first = 1; ScalarEntity second = 2; } message HierarchyEntity { oneof data { ScalarEntity first_entity = 1; NestedEntity second_entity = 2; } } message HierarchyEntitySameTypes { oneof data { ScalarEntity first_entity = 1; ScalarEntity second_entity = 2; } } message EntityUuids { string uuid_str = 1; string opt_uuid_str = 2; bytes uuid_bytes = 3; bytes opt_uuid_bytes = 4; }