syntax = "proto2";

import "google/protobuf/swift-descriptor.proto";

option (.google.protobuf.swift_file_options).entities_access_control = InternalEntities;
option (.google.protobuf.swift_file_options).class_prefix = "PB";

message User {
  optional Group group = 1;
  optional string groupName = 2;
}

message Group {
  optional User owner = 1;

}

message PerfomanceBatch {
  repeated Perfomance batch = 1;
}

message Perfomance {
   required int32 ints = 1;
   required int64 ints64 = 2;
   required double doubles = 3;
   required float floats  = 4;
   optional string str  = 5;
   optional bytes bytes  = 6;
   optional string description = 7;
}

message ProtoPoint {
    required float latitude = 1;
    required float longitude = 2;
}


//ISSUE #57
// enum Flavor {
//   CHOCOLATE = 1;
//   VANILLA = 2;
// }

message IceCreamCone {
  enum Flavor {
    CHOCOLATE = 1;
    VANILLA = 2;
  }
  optional int32 scoops = 1;
  optional Flavor flavor = 2;

}

//Subuilders
message Foo {
  optional int32 val = 1;
  // some other fields.
}

message Bar {
  optional Foo foo = 1;
  // some other fields.
}

message Baz {
  optional Bar bar = 1;
  // some other fields.
}
