blob: 67df22fe461836100b7cd0858bab9c4a38cffcd0 [file] [log] [blame]
// Copyright 2020 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
syntax = "proto2";
package location.nearby.proto;
import "logs/proto/logs_annotations/logs_annotations.proto";
option optimize_for = LITE_RUNTIME;
option (logs_proto.file_not_used_for_logging_except_enums) = true;
option java_api_version = 2;
option java_package = "com.google.location.nearby.proto";
option java_outer_classname = "BootstrapEnums";
option go_api_flag = "OPEN_TO_OPAQUE_HYBRID"; // See http://go/go-api-flag.
// Medium used for offline socket.
enum SocketMedium {
SOCKET_MEDIUM_UNKNOWN = 0;
// Bluetooth rfcomm socket.
SOCKET_BLUETOOTH_RFCOMM = 1;
// BLE gatt socket.
SOCKET_BLE_GATT = 2;
}
enum NearbyBootstrapEvent {
EVENT_UNKNOWN = 0;
// Enable target mode.
EVENT_ENABLE_TARGET = 1;
// Disable target mode.
EVENT_DISABLE_TARGET = 2;
// Start scan devices.
EVENT_START_SCAN = 3;
// Stop scan devices.
EVENT_STOP_SCAN = 4;
// Find one or more scan results.
EVENT_HAS_SCAN_RESULT = 5;
// Start connect in SPAKE.
EVENT_START_CONNECT_SPAKE = 6;
// Start connect in ECDH.
EVENT_START_CONNECT_ECDH = 7;
// Input token for SPAKE connection if previous one is incorrect.
EVENT_INPUT_TOKEN = 8;
// Confirm connection for ECDH connection.
EVENT_CONFIRM = 9;
// Disconnect.
EVENT_DISCONNECT = 10;
// Connection is established.
EVENT_CONNECTED = 11;
// Connection is disconnected.
EVENT_DISCONNECTED = 12;
// Connect is timeout.
EVENT_CONNECT_TIMEOUT = 13;
}
enum NearbyBootstrapDeviceType {
DEVICE_TYPE_UNKNOWN = 0;
DEVICE_TYPE_ANDROID_PHONE = 1;
DEVICE_TYPE_ANDROID_TABLET = 2;
DEVICE_TYPE_ANDROID_TV = 3;
DEVICE_TYPE_ANDROID_WEAR = 4;
}
enum NearbyBootstrapDeviceRole {
DEVICE_ROLE_UNKNOWN = 0;
// Device to be bootstrapped.
DEVICE_ROLE_TARGET = 1;
// Device that initiate the bootstrap.
DEVICE_ROLE_SOURCE = 2;
}