blob: 70d47ee20b2ed8ba90d9ce9c5acc4b65e17e31b1 [file] [log] [blame]
Jakub Pawlowski2fc6e6b2015-12-29 13:19:21 -08001/*
2 * Copyright (C) 2016 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package android.bluetooth;
18
19import android.os.Parcel;
20import android.os.Parcelable;
21
22import android.util.Log;
23
24/**
25 * Out Of Band Data for Bluetooth device.
Jeff Sharkeyfa6a1bc2016-03-01 17:36:23 -070026 * @hide
Jakub Pawlowski2fc6e6b2015-12-29 13:19:21 -080027 */
Jeff Sharkey9ad443f2016-03-01 17:28:36 -070028public class OobData implements Parcelable {
Jakub Pawlowski2fc6e6b2015-12-29 13:19:21 -080029 private byte[] securityManagerTk;
30
31 public byte[] getSecurityManagerTk() {
32 return securityManagerTk;
33 }
34
35 public void setSecurityManagerTk(byte[] securityManagerTk) {
36 this.securityManagerTk = securityManagerTk;
37 }
38
39 public OobData() { }
40
41 private OobData(Parcel in) {
42 securityManagerTk = in.createByteArray();
43 }
44
45 public int describeContents() {
46 return 0;
47 }
48
49 @Override
50 public void writeToParcel(Parcel out, int flags) {
51 out.writeByteArray(securityManagerTk);
52 }
53
54 public static final Parcelable.Creator<OobData> CREATOR
55 = new Parcelable.Creator<OobData>() {
56 public OobData createFromParcel(Parcel in) {
57 return new OobData(in);
58 }
59
60 public OobData[] newArray(int size) {
61 return new OobData[size];
62 }
63 };
64}