Files
nearby/proto/mediums/ble_frames.proto
T
Alexey Polyudov 30039f266f Merge branch 'google3'
Change-Id: I0c3068279f34e50b286caf84940281f5b5e4dfbb
2020-06-24 18:19:54 -07:00

40 lines
964 B
Protocol Buffer

syntax = "proto2";
package location.nearby.mediums;
option optimize_for = LITE_RUNTIME;
option java_outer_classname = "BleFramesProto";
option java_package = "com.google.location.nearby.mediums.proto";
option objc_class_prefix = "GNCM";
// This should map exactly to BleAdvertisement's socket versions.
// TODO(alexanderkang): Make BleAdvertisement reference this proto.
enum SocketVersion {
UNKNOWN_SOCKET_VERSION = 0;
V1 = 1;
V2 = 2;
}
message SocketControlFrame {
enum ControlFrameType {
UNKNOWN_CONTROL_FRAME_TYPE = 0;
INTRODUCTION = 1;
DISCONNECTION = 2;
}
optional ControlFrameType type = 1;
// Exactly one of the following fields will be set.
optional IntroductionFrame introduction = 2;
optional DisconnectionFrame disconnection = 3;
}
message IntroductionFrame {
optional bytes service_id_hash = 1;
optional SocketVersion socket_version = 2;
}
message DisconnectionFrame {
optional bytes service_id_hash = 1;
}