le

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 21, 2026 License: CC0-1.0 Imports: 6 Imported by: 0

Documentation

Overview

Package le provides Go bindings for android.bluetooth.le.

Index

Constants

View Source
const (
	ExtraCallbackType   = consts.ExtraCallbackType
	ExtraErrorCode      = consts.ExtraErrorCode
	ExtraListScanResult = consts.ExtraListScanResult
)
View Source
const (
	Creator                    = consts.Creator
	DataComplete               = consts.DataComplete
	DataTruncated              = consts.DataTruncated
	PeriodicIntervalNotPresent = consts.PeriodicIntervalNotPresent
	PhyUnused                  = consts.PhyUnused
	SidNotPresent              = consts.SidNotPresent
	TxPowerNotPresent          = consts.TxPowerNotPresent
)

Variables

This section is empty.

Functions

func Init

func Init(env *jni.Env) error

Init resolves all JNI class and method references for this package. It is safe to call multiple times (uses sync.Once internally). Exported for E2E testing on Android.

Types

type BluetoothLeAdvertiser added in v0.0.4

type BluetoothLeAdvertiser struct {
	VM  *jni.VM
	Obj *jni.GlobalRef
}

BluetoothLeAdvertiser wraps android.bluetooth.le.BluetoothLeAdvertiser.

func (*BluetoothLeAdvertiser) StartAdvertising3 added in v0.0.4

func (m *BluetoothLeAdvertiser) StartAdvertising3(
	arg0 *jni.Object,
	arg1 *jni.Object,
	arg2 *jni.Object,
) error

StartAdvertising3 calls android.bluetooth.le.BluetoothLeAdvertiser.startAdvertising.

func (*BluetoothLeAdvertiser) StartAdvertising4_1 added in v0.0.4

func (m *BluetoothLeAdvertiser) StartAdvertising4_1(
	arg0 *jni.Object,
	arg1 *jni.Object,
	arg2 *jni.Object,
	arg3 *jni.Object,
) error

StartAdvertising4_1 calls android.bluetooth.le.BluetoothLeAdvertiser.startAdvertising.

func (*BluetoothLeAdvertiser) StartAdvertisingSet6 added in v0.0.4

func (m *BluetoothLeAdvertiser) StartAdvertisingSet6(
	arg0 *jni.Object,
	arg1 *jni.Object,
	arg2 *jni.Object,
	arg3 *jni.Object,
	arg4 *jni.Object,
	arg5 *jni.Object,
) error

StartAdvertisingSet6 calls android.bluetooth.le.BluetoothLeAdvertiser.startAdvertisingSet.

func (*BluetoothLeAdvertiser) StartAdvertisingSet8_1 added in v0.0.4

func (m *BluetoothLeAdvertiser) StartAdvertisingSet8_1(
	arg0 *jni.Object,
	arg1 *jni.Object,
	arg2 *jni.Object,
	arg3 *jni.Object,
	arg4 *jni.Object,
	arg5 int32,
	arg6 int32,
	arg7 *jni.Object,
) error

StartAdvertisingSet8_1 calls android.bluetooth.le.BluetoothLeAdvertiser.startAdvertisingSet.

func (*BluetoothLeAdvertiser) StopAdvertising added in v0.0.4

func (m *BluetoothLeAdvertiser) StopAdvertising(arg0 *jni.Object) error

StopAdvertising calls android.bluetooth.le.BluetoothLeAdvertiser.stopAdvertising.

func (*BluetoothLeAdvertiser) StopAdvertisingSet added in v0.0.4

func (m *BluetoothLeAdvertiser) StopAdvertisingSet(arg0 *jni.Object) error

StopAdvertisingSet calls android.bluetooth.le.BluetoothLeAdvertiser.stopAdvertisingSet.

type BluetoothLeScanner added in v0.0.4

type BluetoothLeScanner struct {
	VM  *jni.VM
	Obj *jni.GlobalRef
}

BluetoothLeScanner wraps android.bluetooth.le.BluetoothLeScanner.

func (*BluetoothLeScanner) FlushPendingScanResults added in v0.0.4

func (m *BluetoothLeScanner) FlushPendingScanResults(arg0 *jni.Object) error

FlushPendingScanResults calls android.bluetooth.le.BluetoothLeScanner.flushPendingScanResults.

func (*BluetoothLeScanner) StartScan1 added in v0.0.4

func (m *BluetoothLeScanner) StartScan1(arg0 *jni.Object) error

StartScan1 calls android.bluetooth.le.BluetoothLeScanner.startScan.

func (*BluetoothLeScanner) StartScan3_1 added in v0.0.4

func (m *BluetoothLeScanner) StartScan3_1(
	arg0 *jni.Object,
	arg1 *jni.Object,
	arg2 *jni.Object,
) (int32, error)

StartScan3_1 calls android.bluetooth.le.BluetoothLeScanner.startScan.

func (*BluetoothLeScanner) StartScan3_2 added in v0.0.4

func (m *BluetoothLeScanner) StartScan3_2(
	arg0 *jni.Object,
	arg1 *jni.Object,
	arg2 *jni.Object,
) error

StartScan3_2 calls android.bluetooth.le.BluetoothLeScanner.startScan.

func (*BluetoothLeScanner) StopScan1 added in v0.0.4

func (m *BluetoothLeScanner) StopScan1(arg0 *jni.Object) error

StopScan1 calls android.bluetooth.le.BluetoothLeScanner.stopScan.

func (*BluetoothLeScanner) StopScan1_1 added in v0.0.4

func (m *BluetoothLeScanner) StopScan1_1(arg0 *jni.Object) error

StopScan1_1 calls android.bluetooth.le.BluetoothLeScanner.stopScan.

type ScanResult added in v0.0.4

type ScanResult struct {
	VM  *jni.VM
	Obj *jni.GlobalRef
}

ScanResult wraps android.bluetooth.le.ScanResult.

func (*ScanResult) DescribeContents added in v0.0.4

func (m *ScanResult) DescribeContents() (int32, error)

DescribeContents calls android.bluetooth.le.ScanResult.describeContents.

func (*ScanResult) Equals added in v0.0.4

func (m *ScanResult) Equals(arg0 *jni.Object) (bool, error)

Equals calls android.bluetooth.le.ScanResult.equals.

func (*ScanResult) GetAdvertisingSid added in v0.0.4

func (m *ScanResult) GetAdvertisingSid() (int32, error)

GetAdvertisingSid calls android.bluetooth.le.ScanResult.getAdvertisingSid.

func (*ScanResult) GetDataStatus added in v0.0.4

func (m *ScanResult) GetDataStatus() (int32, error)

GetDataStatus calls android.bluetooth.le.ScanResult.getDataStatus.

func (*ScanResult) GetDevice added in v0.0.4

func (m *ScanResult) GetDevice() (*jni.Object, error)

GetDevice calls android.bluetooth.le.ScanResult.getDevice.

func (*ScanResult) GetPeriodicAdvertisingInterval added in v0.0.4

func (m *ScanResult) GetPeriodicAdvertisingInterval() (int32, error)

GetPeriodicAdvertisingInterval calls android.bluetooth.le.ScanResult.getPeriodicAdvertisingInterval.

func (*ScanResult) GetPrimaryPhy added in v0.0.4

func (m *ScanResult) GetPrimaryPhy() (int32, error)

GetPrimaryPhy calls android.bluetooth.le.ScanResult.getPrimaryPhy.

func (*ScanResult) GetRssi added in v0.0.4

func (m *ScanResult) GetRssi() (int32, error)

GetRssi calls android.bluetooth.le.ScanResult.getRssi.

func (*ScanResult) GetScanRecord added in v0.0.4

func (m *ScanResult) GetScanRecord() (*jni.Object, error)

GetScanRecord calls android.bluetooth.le.ScanResult.getScanRecord.

func (*ScanResult) GetSecondaryPhy added in v0.0.4

func (m *ScanResult) GetSecondaryPhy() (int32, error)

GetSecondaryPhy calls android.bluetooth.le.ScanResult.getSecondaryPhy.

func (*ScanResult) GetTimestampNanos added in v0.0.4

func (m *ScanResult) GetTimestampNanos() (int64, error)

GetTimestampNanos calls android.bluetooth.le.ScanResult.getTimestampNanos.

func (*ScanResult) GetTxPower added in v0.0.4

func (m *ScanResult) GetTxPower() (int32, error)

GetTxPower calls android.bluetooth.le.ScanResult.getTxPower.

func (*ScanResult) HashCode added in v0.0.4

func (m *ScanResult) HashCode() (int32, error)

HashCode calls android.bluetooth.le.ScanResult.hashCode.

func (*ScanResult) IsConnectable added in v0.0.4

func (m *ScanResult) IsConnectable() (bool, error)

IsConnectable calls android.bluetooth.le.ScanResult.isConnectable.

func (*ScanResult) IsLegacy added in v0.0.4

func (m *ScanResult) IsLegacy() (bool, error)

IsLegacy calls android.bluetooth.le.ScanResult.isLegacy.

func (*ScanResult) ToString added in v0.0.4

func (m *ScanResult) ToString() (string, error)

ToString calls android.bluetooth.le.ScanResult.toString.

func (*ScanResult) WriteToParcel added in v0.0.4

func (m *ScanResult) WriteToParcel(arg0 *jni.Object, arg1 int32) error

WriteToParcel calls android.bluetooth.le.ScanResult.writeToParcel.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL