companion

package
v0.0.6 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	TransactionIAssociationRequestCallbackOnAssociationPending = binder.FirstCallTransaction + 0
	TransactionIAssociationRequestCallbackOnAssociationCreated = binder.FirstCallTransaction + 1
	TransactionIAssociationRequestCallbackOnFailure            = binder.FirstCallTransaction + 2
)
View Source
const (
	MethodIAssociationRequestCallbackOnAssociationPending = "onAssociationPending"
	MethodIAssociationRequestCallbackOnAssociationCreated = "onAssociationCreated"
	MethodIAssociationRequestCallbackOnFailure            = "onFailure"
)
View Source
const (
	TransactionICompanionDeviceDiscoveryServiceStartDiscovery       = binder.FirstCallTransaction + 0
	TransactionICompanionDeviceDiscoveryServiceOnAssociationCreated = binder.FirstCallTransaction + 1
)
View Source
const (
	MethodICompanionDeviceDiscoveryServiceStartDiscovery       = "startDiscovery"
	MethodICompanionDeviceDiscoveryServiceOnAssociationCreated = "onAssociationCreated"
)
View Source
const (
	TransactionICompanionDeviceManagerAssociate                                = binder.FirstCallTransaction + 0
	TransactionICompanionDeviceManagerGetAssociations                          = binder.FirstCallTransaction + 1
	TransactionICompanionDeviceManagerGetAllAssociationsForUser                = binder.FirstCallTransaction + 2
	TransactionICompanionDeviceManagerLegacyDisassociate                       = binder.FirstCallTransaction + 3
	TransactionICompanionDeviceManagerDisassociate                             = binder.FirstCallTransaction + 4
	TransactionICompanionDeviceManagerHasNotificationAccess                    = binder.FirstCallTransaction + 5
	TransactionICompanionDeviceManagerRequestNotificationAccess                = binder.FirstCallTransaction + 6
	TransactionICompanionDeviceManagerIsDeviceAssociatedForWifiConnection      = binder.FirstCallTransaction + 7
	TransactionICompanionDeviceManagerRegisterDevicePresenceListenerService    = binder.FirstCallTransaction + 8
	TransactionICompanionDeviceManagerUnregisterDevicePresenceListenerService  = binder.FirstCallTransaction + 9
	TransactionICompanionDeviceManagerCanPairWithoutPrompt                     = binder.FirstCallTransaction + 10
	TransactionICompanionDeviceManagerCreateAssociation                        = binder.FirstCallTransaction + 11
	TransactionICompanionDeviceManagerAddOnAssociationsChangedListener         = binder.FirstCallTransaction + 12
	TransactionICompanionDeviceManagerRemoveOnAssociationsChangedListener      = binder.FirstCallTransaction + 13
	TransactionICompanionDeviceManagerAddOnTransportsChangedListener           = binder.FirstCallTransaction + 14
	TransactionICompanionDeviceManagerRemoveOnTransportsChangedListener        = binder.FirstCallTransaction + 15
	TransactionICompanionDeviceManagerSendMessage                              = binder.FirstCallTransaction + 16
	TransactionICompanionDeviceManagerAddOnMessageReceivedListener             = binder.FirstCallTransaction + 17
	TransactionICompanionDeviceManagerRemoveOnMessageReceivedListener          = binder.FirstCallTransaction + 18
	TransactionICompanionDeviceManagerNotifyDeviceAppeared                     = binder.FirstCallTransaction + 19
	TransactionICompanionDeviceManagerNotifyDeviceDisappeared                  = binder.FirstCallTransaction + 20
	TransactionICompanionDeviceManagerBuildPermissionTransferUserConsentIntent = binder.FirstCallTransaction + 21
	TransactionICompanionDeviceManagerIsPermissionTransferUserConsented        = binder.FirstCallTransaction + 22
	TransactionICompanionDeviceManagerStartSystemDataTransfer                  = binder.FirstCallTransaction + 23
	TransactionICompanionDeviceManagerAttachSystemDataTransport                = binder.FirstCallTransaction + 24
	TransactionICompanionDeviceManagerDetachSystemDataTransport                = binder.FirstCallTransaction + 25
	TransactionICompanionDeviceManagerIsCompanionApplicationBound              = binder.FirstCallTransaction + 26
	TransactionICompanionDeviceManagerBuildAssociationCancellationIntent       = binder.FirstCallTransaction + 27
	TransactionICompanionDeviceManagerEnableSystemDataSync                     = binder.FirstCallTransaction + 28
	TransactionICompanionDeviceManagerDisableSystemDataSync                    = binder.FirstCallTransaction + 29
	TransactionICompanionDeviceManagerEnablePermissionsSync                    = binder.FirstCallTransaction + 30
	TransactionICompanionDeviceManagerDisablePermissionsSync                   = binder.FirstCallTransaction + 31
	TransactionICompanionDeviceManagerGetPermissionSyncRequest                 = binder.FirstCallTransaction + 32
	TransactionICompanionDeviceManagerEnableSecureTransport                    = binder.FirstCallTransaction + 33
	TransactionICompanionDeviceManagerSetAssociationTag                        = binder.FirstCallTransaction + 34
	TransactionICompanionDeviceManagerClearAssociationTag                      = binder.FirstCallTransaction + 35
	TransactionICompanionDeviceManagerGetBackupPayload                         = binder.FirstCallTransaction + 36
	TransactionICompanionDeviceManagerApplyRestoredPayload                     = binder.FirstCallTransaction + 37
	TransactionICompanionDeviceManagerStartObservingDevicePresence             = binder.FirstCallTransaction + 38
	TransactionICompanionDeviceManagerStopObservingDevicePresence              = binder.FirstCallTransaction + 39
)
View Source
const (
	MethodICompanionDeviceManagerAssociate                                = "associate"
	MethodICompanionDeviceManagerGetAssociations                          = "getAssociations"
	MethodICompanionDeviceManagerGetAllAssociationsForUser                = "getAllAssociationsForUser"
	MethodICompanionDeviceManagerLegacyDisassociate                       = "legacyDisassociate"
	MethodICompanionDeviceManagerDisassociate                             = "disassociate"
	MethodICompanionDeviceManagerHasNotificationAccess                    = "hasNotificationAccess"
	MethodICompanionDeviceManagerRequestNotificationAccess                = "requestNotificationAccess"
	MethodICompanionDeviceManagerIsDeviceAssociatedForWifiConnection      = "isDeviceAssociatedForWifiConnection"
	MethodICompanionDeviceManagerRegisterDevicePresenceListenerService    = "registerDevicePresenceListenerService"
	MethodICompanionDeviceManagerUnregisterDevicePresenceListenerService  = "unregisterDevicePresenceListenerService"
	MethodICompanionDeviceManagerCanPairWithoutPrompt                     = "canPairWithoutPrompt"
	MethodICompanionDeviceManagerCreateAssociation                        = "createAssociation"
	MethodICompanionDeviceManagerAddOnAssociationsChangedListener         = "addOnAssociationsChangedListener"
	MethodICompanionDeviceManagerRemoveOnAssociationsChangedListener      = "removeOnAssociationsChangedListener"
	MethodICompanionDeviceManagerAddOnTransportsChangedListener           = "addOnTransportsChangedListener"
	MethodICompanionDeviceManagerRemoveOnTransportsChangedListener        = "removeOnTransportsChangedListener"
	MethodICompanionDeviceManagerSendMessage                              = "sendMessage"
	MethodICompanionDeviceManagerAddOnMessageReceivedListener             = "addOnMessageReceivedListener"
	MethodICompanionDeviceManagerRemoveOnMessageReceivedListener          = "removeOnMessageReceivedListener"
	MethodICompanionDeviceManagerNotifyDeviceAppeared                     = "notifyDeviceAppeared"
	MethodICompanionDeviceManagerNotifyDeviceDisappeared                  = "notifyDeviceDisappeared"
	MethodICompanionDeviceManagerBuildPermissionTransferUserConsentIntent = "buildPermissionTransferUserConsentIntent"
	MethodICompanionDeviceManagerIsPermissionTransferUserConsented        = "isPermissionTransferUserConsented"
	MethodICompanionDeviceManagerStartSystemDataTransfer                  = "startSystemDataTransfer"
	MethodICompanionDeviceManagerAttachSystemDataTransport                = "attachSystemDataTransport"
	MethodICompanionDeviceManagerDetachSystemDataTransport                = "detachSystemDataTransport"
	MethodICompanionDeviceManagerIsCompanionApplicationBound              = "isCompanionApplicationBound"
	MethodICompanionDeviceManagerBuildAssociationCancellationIntent       = "buildAssociationCancellationIntent"
	MethodICompanionDeviceManagerEnableSystemDataSync                     = "enableSystemDataSync"
	MethodICompanionDeviceManagerDisableSystemDataSync                    = "disableSystemDataSync"
	MethodICompanionDeviceManagerEnablePermissionsSync                    = "enablePermissionsSync"
	MethodICompanionDeviceManagerDisablePermissionsSync                   = "disablePermissionsSync"
	MethodICompanionDeviceManagerGetPermissionSyncRequest                 = "getPermissionSyncRequest"
	MethodICompanionDeviceManagerEnableSecureTransport                    = "enableSecureTransport"
	MethodICompanionDeviceManagerSetAssociationTag                        = "setAssociationTag"
	MethodICompanionDeviceManagerClearAssociationTag                      = "clearAssociationTag"
	MethodICompanionDeviceManagerGetBackupPayload                         = "getBackupPayload"
	MethodICompanionDeviceManagerApplyRestoredPayload                     = "applyRestoredPayload"
	MethodICompanionDeviceManagerStartObservingDevicePresence             = "startObservingDevicePresence"
	MethodICompanionDeviceManagerStopObservingDevicePresence              = "stopObservingDevicePresence"
)
View Source
const (
	TransactionICompanionDeviceServiceOnDeviceAppeared      = binder.FirstCallTransaction + 0
	TransactionICompanionDeviceServiceOnDeviceDisappeared   = binder.FirstCallTransaction + 1
	TransactionICompanionDeviceServiceOnDevicePresenceEvent = binder.FirstCallTransaction + 2
)
View Source
const (
	MethodICompanionDeviceServiceOnDeviceAppeared      = "onDeviceAppeared"
	MethodICompanionDeviceServiceOnDeviceDisappeared   = "onDeviceDisappeared"
	MethodICompanionDeviceServiceOnDevicePresenceEvent = "onDevicePresenceEvent"
)
View Source
const (
	TransactionISystemDataTransferCallbackOnResult = binder.FirstCallTransaction + 0
	TransactionISystemDataTransferCallbackOnError  = binder.FirstCallTransaction + 1
)
View Source
const (
	MethodISystemDataTransferCallbackOnResult = "onResult"
	MethodISystemDataTransferCallbackOnError  = "onError"
)
View Source
const DescriptorIAssociationRequestCallback = "android.companion.IAssociationRequestCallback"
View Source
const DescriptorICompanionDeviceDiscoveryService = "android.companion.ICompanionDeviceDiscoveryService"
View Source
const DescriptorICompanionDeviceManager = "android.companion.ICompanionDeviceManager"
View Source
const DescriptorICompanionDeviceService = "android.companion.ICompanionDeviceService"
View Source
const DescriptorIOnAssociationsChangedListener = "android.companion.IOnAssociationsChangedListener"
View Source
const DescriptorIOnMessageReceivedListener = "android.companion.IOnMessageReceivedListener"
View Source
const DescriptorIOnTransportsChangedListener = "android.companion.IOnTransportsChangedListener"
View Source
const DescriptorISystemDataTransferCallback = "android.companion.ISystemDataTransferCallback"
View Source
const (
	MethodIOnAssociationsChangedListenerOnAssociationsChanged = "onAssociationsChanged"
)
View Source
const (
	MethodIOnMessageReceivedListenerOnMessageReceived = "onMessageReceived"
)
View Source
const (
	MethodIOnTransportsChangedListenerOnTransportsChanged = "onTransportsChanged"
)
View Source
const (
	TransactionIOnAssociationsChangedListenerOnAssociationsChanged = binder.FirstCallTransaction + 0
)
View Source
const (
	TransactionIOnMessageReceivedListenerOnMessageReceived = binder.FirstCallTransaction + 0
)
View Source
const (
	TransactionIOnTransportsChangedListenerOnTransportsChanged = binder.FirstCallTransaction + 0
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AssociationInfo

type AssociationInfo struct {
	Id                   int32
	UserId               int32
	PackageName          string
	Tag                  string
	DeviceProfile        string
	SelfManaged          bool
	NotifyOnDeviceNearby bool
	Revoked              bool
	Pending              bool
	TimeApprovedMs       int64
	LastTimeConnectedMs  int64
	SystemDataSyncFlags  int32
}

func (*AssociationInfo) MarshalParcel

func (s *AssociationInfo) MarshalParcel(
	p *parcel.Parcel,
) error

func (*AssociationInfo) UnmarshalParcel

func (s *AssociationInfo) UnmarshalParcel(
	p *parcel.Parcel,
) error

type AssociationRequest

type AssociationRequest struct {
	Flg          int32
	UserId       int32
	CreationTime int64
}

func (*AssociationRequest) MarshalParcel

func (s *AssociationRequest) MarshalParcel(
	p *parcel.Parcel,
) error

func (*AssociationRequest) UnmarshalParcel

func (s *AssociationRequest) UnmarshalParcel(
	p *parcel.Parcel,
) error

type AssociationRequestCallbackProxy

type AssociationRequestCallbackProxy struct {
	Remote binder.IBinder
}

func NewAssociationRequestCallbackProxy

func NewAssociationRequestCallbackProxy(
	remote binder.IBinder,
) *AssociationRequestCallbackProxy

func (*AssociationRequestCallbackProxy) AsBinder

func (*AssociationRequestCallbackProxy) OnAssociationCreated

func (p *AssociationRequestCallbackProxy) OnAssociationCreated(
	ctx context.Context,
	associationInfo AssociationInfo,
) error

func (*AssociationRequestCallbackProxy) OnAssociationPending

func (p *AssociationRequestCallbackProxy) OnAssociationPending(
	ctx context.Context,
	pendingIntent app.PendingIntent,
) error

func (*AssociationRequestCallbackProxy) OnFailure

func (p *AssociationRequestCallbackProxy) OnFailure(
	ctx context.Context,
	error_ string,
) error

type AssociationRequestCallbackStub

type AssociationRequestCallbackStub struct {
	Impl      IAssociationRequestCallback
	Transport binder.VersionAwareTransport
}

AssociationRequestCallbackStub dispatches incoming binder transactions to a typed IAssociationRequestCallback implementation.

func (*AssociationRequestCallbackStub) Descriptor

func (s *AssociationRequestCallbackStub) Descriptor() string

func (*AssociationRequestCallbackStub) OnTransaction

type BluetoothLEDeviceFilter

type BluetoothLEDeviceFilter struct {
}

func (*BluetoothLEDeviceFilter) MarshalParcel

func (s *BluetoothLEDeviceFilter) MarshalParcel(
	p *parcel.Parcel,
) error

func (*BluetoothLEDeviceFilter) UnmarshalParcel

func (s *BluetoothLEDeviceFilter) UnmarshalParcel(
	p *parcel.Parcel,
) error

type CompanionDeviceDiscoveryServiceProxy

type CompanionDeviceDiscoveryServiceProxy struct {
	Remote binder.IBinder
}

func NewCompanionDeviceDiscoveryServiceProxy

func NewCompanionDeviceDiscoveryServiceProxy(
	remote binder.IBinder,
) *CompanionDeviceDiscoveryServiceProxy

func (*CompanionDeviceDiscoveryServiceProxy) AsBinder

func (*CompanionDeviceDiscoveryServiceProxy) OnAssociationCreated

func (p *CompanionDeviceDiscoveryServiceProxy) OnAssociationCreated(
	ctx context.Context,
) error

func (*CompanionDeviceDiscoveryServiceProxy) StartDiscovery

func (p *CompanionDeviceDiscoveryServiceProxy) StartDiscovery(
	ctx context.Context,
	request AssociationRequest,
	applicationCallback IAssociationRequestCallback,
	serviceCallback infra.AndroidFuture,
) error

type CompanionDeviceDiscoveryServiceStub

type CompanionDeviceDiscoveryServiceStub struct {
	Impl      ICompanionDeviceDiscoveryService
	Transport binder.VersionAwareTransport
}

CompanionDeviceDiscoveryServiceStub dispatches incoming binder transactions to a typed ICompanionDeviceDiscoveryService implementation.

func (*CompanionDeviceDiscoveryServiceStub) Descriptor

func (*CompanionDeviceDiscoveryServiceStub) OnTransaction

type CompanionDeviceManagerProxy

type CompanionDeviceManagerProxy struct {
	Remote binder.IBinder
}

func GetCompanionDeviceManager

func GetCompanionDeviceManager(
	ctx context.Context,
	sm *servicemanager.ServiceManager,
) (*CompanionDeviceManagerProxy, error)

GetCompanionDeviceManager retrieves the CompanionDeviceService service and returns a typed proxy.

func NewCompanionDeviceManagerProxy

func NewCompanionDeviceManagerProxy(
	remote binder.IBinder,
) *CompanionDeviceManagerProxy

func (*CompanionDeviceManagerProxy) AddOnAssociationsChangedListener

func (p *CompanionDeviceManagerProxy) AddOnAssociationsChangedListener(
	ctx context.Context,
	listener IOnAssociationsChangedListener,
) error

func (*CompanionDeviceManagerProxy) AddOnMessageReceivedListener

func (p *CompanionDeviceManagerProxy) AddOnMessageReceivedListener(
	ctx context.Context,
	messageType int32,
	listener IOnMessageReceivedListener,
) error

func (*CompanionDeviceManagerProxy) AddOnTransportsChangedListener

func (p *CompanionDeviceManagerProxy) AddOnTransportsChangedListener(
	ctx context.Context,
	listener IOnTransportsChangedListener,
) error

func (*CompanionDeviceManagerProxy) ApplyRestoredPayload

func (p *CompanionDeviceManagerProxy) ApplyRestoredPayload(
	ctx context.Context,
	payload []byte,
) error

func (*CompanionDeviceManagerProxy) AsBinder

func (*CompanionDeviceManagerProxy) Associate

func (*CompanionDeviceManagerProxy) AttachSystemDataTransport

func (p *CompanionDeviceManagerProxy) AttachSystemDataTransport(
	ctx context.Context,
	packageName string,
	associationId int32,
	fd int32,
) error

func (*CompanionDeviceManagerProxy) BuildAssociationCancellationIntent

func (p *CompanionDeviceManagerProxy) BuildAssociationCancellationIntent(
	ctx context.Context,
) (app.PendingIntent, error)

func (*CompanionDeviceManagerProxy) BuildPermissionTransferUserConsentIntent

func (p *CompanionDeviceManagerProxy) BuildPermissionTransferUserConsentIntent(
	ctx context.Context,
	associationId int32,
) (app.PendingIntent, error)

func (*CompanionDeviceManagerProxy) CanPairWithoutPrompt

func (p *CompanionDeviceManagerProxy) CanPairWithoutPrompt(
	ctx context.Context,
	packageName string,
	deviceMacAddress string,
) (bool, error)

func (*CompanionDeviceManagerProxy) ClearAssociationTag

func (p *CompanionDeviceManagerProxy) ClearAssociationTag(
	ctx context.Context,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) CreateAssociation

func (p *CompanionDeviceManagerProxy) CreateAssociation(
	ctx context.Context,
	packageName string,
	macAddress string,
	certificate []byte,
) error

func (*CompanionDeviceManagerProxy) DetachSystemDataTransport

func (p *CompanionDeviceManagerProxy) DetachSystemDataTransport(
	ctx context.Context,
	packageName string,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) DisablePermissionsSync

func (p *CompanionDeviceManagerProxy) DisablePermissionsSync(
	ctx context.Context,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) DisableSystemDataSync

func (p *CompanionDeviceManagerProxy) DisableSystemDataSync(
	ctx context.Context,
	associationId int32,
	flags int32,
) error

func (*CompanionDeviceManagerProxy) Disassociate

func (p *CompanionDeviceManagerProxy) Disassociate(
	ctx context.Context,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) EnablePermissionsSync

func (p *CompanionDeviceManagerProxy) EnablePermissionsSync(
	ctx context.Context,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) EnableSecureTransport

func (p *CompanionDeviceManagerProxy) EnableSecureTransport(
	ctx context.Context,
	enabled bool,
) error

func (*CompanionDeviceManagerProxy) EnableSystemDataSync

func (p *CompanionDeviceManagerProxy) EnableSystemDataSync(
	ctx context.Context,
	associationId int32,
	flags int32,
) error

func (*CompanionDeviceManagerProxy) GetAllAssociationsForUser

func (p *CompanionDeviceManagerProxy) GetAllAssociationsForUser(
	ctx context.Context,
) ([]AssociationInfo, error)

func (*CompanionDeviceManagerProxy) GetAssociations

func (p *CompanionDeviceManagerProxy) GetAssociations(
	ctx context.Context,
) ([]AssociationInfo, error)

func (*CompanionDeviceManagerProxy) GetBackupPayload

func (p *CompanionDeviceManagerProxy) GetBackupPayload(
	ctx context.Context,
) ([]byte, error)

func (*CompanionDeviceManagerProxy) GetPermissionSyncRequest

func (p *CompanionDeviceManagerProxy) GetPermissionSyncRequest(
	ctx context.Context,
	associationId int32,
) (datatransfer.PermissionSyncRequest, error)

func (*CompanionDeviceManagerProxy) HasNotificationAccess

func (p *CompanionDeviceManagerProxy) HasNotificationAccess(
	ctx context.Context,
	component content.ComponentName,
) (bool, error)

func (*CompanionDeviceManagerProxy) IsCompanionApplicationBound

func (p *CompanionDeviceManagerProxy) IsCompanionApplicationBound(
	ctx context.Context,
	packageName string,
) (bool, error)

func (*CompanionDeviceManagerProxy) IsDeviceAssociatedForWifiConnection

func (p *CompanionDeviceManagerProxy) IsDeviceAssociatedForWifiConnection(
	ctx context.Context,
	packageName string,
	macAddress string,
) (bool, error)

func (*CompanionDeviceManagerProxy) IsPermissionTransferUserConsented

func (p *CompanionDeviceManagerProxy) IsPermissionTransferUserConsented(
	ctx context.Context,
	associationId int32,
) (bool, error)

func (*CompanionDeviceManagerProxy) LegacyDisassociate

func (p *CompanionDeviceManagerProxy) LegacyDisassociate(
	ctx context.Context,
	deviceMacAddress string,
) error

func (*CompanionDeviceManagerProxy) NotifyDeviceAppeared

func (p *CompanionDeviceManagerProxy) NotifyDeviceAppeared(
	ctx context.Context,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) NotifyDeviceDisappeared

func (p *CompanionDeviceManagerProxy) NotifyDeviceDisappeared(
	ctx context.Context,
	associationId int32,
) error

func (*CompanionDeviceManagerProxy) RegisterDevicePresenceListenerService

func (p *CompanionDeviceManagerProxy) RegisterDevicePresenceListenerService(
	ctx context.Context,
	deviceAddress string,
) error

func (*CompanionDeviceManagerProxy) RemoveOnAssociationsChangedListener

func (p *CompanionDeviceManagerProxy) RemoveOnAssociationsChangedListener(
	ctx context.Context,
	listener IOnAssociationsChangedListener,
) error

func (*CompanionDeviceManagerProxy) RemoveOnMessageReceivedListener

func (p *CompanionDeviceManagerProxy) RemoveOnMessageReceivedListener(
	ctx context.Context,
	messageType int32,
	listener IOnMessageReceivedListener,
) error

func (*CompanionDeviceManagerProxy) RemoveOnTransportsChangedListener

func (p *CompanionDeviceManagerProxy) RemoveOnTransportsChangedListener(
	ctx context.Context,
	listener IOnTransportsChangedListener,
) error

func (*CompanionDeviceManagerProxy) RequestNotificationAccess

func (p *CompanionDeviceManagerProxy) RequestNotificationAccess(
	ctx context.Context,
	component content.ComponentName,
) (app.PendingIntent, error)

func (*CompanionDeviceManagerProxy) SendMessage

func (p *CompanionDeviceManagerProxy) SendMessage(
	ctx context.Context,
	messageType int32,
	data []byte,
	associationIds []int32,
) error

func (*CompanionDeviceManagerProxy) SetAssociationTag

func (p *CompanionDeviceManagerProxy) SetAssociationTag(
	ctx context.Context,
	associationId int32,
	tag string,
) error

func (*CompanionDeviceManagerProxy) StartObservingDevicePresence

func (p *CompanionDeviceManagerProxy) StartObservingDevicePresence(
	ctx context.Context,
	request ObservingDevicePresenceRequest,
	packageName string,
) error

func (*CompanionDeviceManagerProxy) StartSystemDataTransfer

func (p *CompanionDeviceManagerProxy) StartSystemDataTransfer(
	ctx context.Context,
	packageName string,
	associationId int32,
	callback ISystemDataTransferCallback,
) error

func (*CompanionDeviceManagerProxy) StopObservingDevicePresence

func (p *CompanionDeviceManagerProxy) StopObservingDevicePresence(
	ctx context.Context,
	request ObservingDevicePresenceRequest,
	packageName string,
) error

func (*CompanionDeviceManagerProxy) UnregisterDevicePresenceListenerService

func (p *CompanionDeviceManagerProxy) UnregisterDevicePresenceListenerService(
	ctx context.Context,
	deviceAddress string,
) error

type CompanionDeviceManagerStub

type CompanionDeviceManagerStub struct {
	Impl      ICompanionDeviceManager
	Transport binder.VersionAwareTransport
}

CompanionDeviceManagerStub dispatches incoming binder transactions to a typed ICompanionDeviceManager implementation.

func (*CompanionDeviceManagerStub) Descriptor

func (s *CompanionDeviceManagerStub) Descriptor() string

func (*CompanionDeviceManagerStub) OnTransaction

func (s *CompanionDeviceManagerStub) OnTransaction(
	ctx context.Context,
	code binder.TransactionCode,
	_data *parcel.Parcel,
) (*parcel.Parcel, error)

type CompanionDeviceServiceProxy

type CompanionDeviceServiceProxy struct {
	Remote binder.IBinder
}

func NewCompanionDeviceServiceProxy

func NewCompanionDeviceServiceProxy(
	remote binder.IBinder,
) *CompanionDeviceServiceProxy

func (*CompanionDeviceServiceProxy) AsBinder

func (*CompanionDeviceServiceProxy) OnDeviceAppeared

func (p *CompanionDeviceServiceProxy) OnDeviceAppeared(
	ctx context.Context,
	associationInfo AssociationInfo,
) error

func (*CompanionDeviceServiceProxy) OnDeviceDisappeared

func (p *CompanionDeviceServiceProxy) OnDeviceDisappeared(
	ctx context.Context,
	associationInfo AssociationInfo,
) error

func (*CompanionDeviceServiceProxy) OnDevicePresenceEvent

func (p *CompanionDeviceServiceProxy) OnDevicePresenceEvent(
	ctx context.Context,
	event DevicePresenceEvent,
) error

type CompanionDeviceServiceStub

type CompanionDeviceServiceStub struct {
	Impl      ICompanionDeviceService
	Transport binder.VersionAwareTransport
}

CompanionDeviceServiceStub dispatches incoming binder transactions to a typed ICompanionDeviceService implementation.

func (*CompanionDeviceServiceStub) Descriptor

func (s *CompanionDeviceServiceStub) Descriptor() string

func (*CompanionDeviceServiceStub) OnTransaction

func (s *CompanionDeviceServiceStub) OnTransaction(
	ctx context.Context,
	code binder.TransactionCode,
	_data *parcel.Parcel,
) (*parcel.Parcel, error)

type DevicePresenceEvent

type DevicePresenceEvent struct {
	AssociationId int32
	Event         int32
}

func (*DevicePresenceEvent) MarshalParcel

func (s *DevicePresenceEvent) MarshalParcel(
	p *parcel.Parcel,
) error

func (*DevicePresenceEvent) UnmarshalParcel

func (s *DevicePresenceEvent) UnmarshalParcel(
	p *parcel.Parcel,
) error

type IAssociationRequestCallback

type IAssociationRequestCallback interface {
	AsBinder() binder.IBinder
	OnAssociationPending(ctx context.Context, pendingIntent app.PendingIntent) error
	OnAssociationCreated(ctx context.Context, associationInfo AssociationInfo) error
	OnFailure(ctx context.Context, error_ string) error
}

func NewAssociationRequestCallbackStub

func NewAssociationRequestCallbackStub(
	impl IAssociationRequestCallbackServer,
) IAssociationRequestCallback

NewAssociationRequestCallbackStub creates a server-side IAssociationRequestCallback wrapping the given server implementation. The returned value satisfies IAssociationRequestCallback and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type IAssociationRequestCallbackServer

type IAssociationRequestCallbackServer interface {
	OnAssociationPending(ctx context.Context, pendingIntent app.PendingIntent) error
	OnAssociationCreated(ctx context.Context, associationInfo AssociationInfo) error
	OnFailure(ctx context.Context, error_ string) error
}

IAssociationRequestCallbackServer is the server-side interface that user implementations provide to NewAssociationRequestCallbackStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type ICompanionDeviceDiscoveryService

type ICompanionDeviceDiscoveryService interface {
	AsBinder() binder.IBinder
	StartDiscovery(ctx context.Context, request AssociationRequest, applicationCallback IAssociationRequestCallback, serviceCallback infra.AndroidFuture) error
	OnAssociationCreated(ctx context.Context) error
}

func NewCompanionDeviceDiscoveryServiceStub

func NewCompanionDeviceDiscoveryServiceStub(
	impl ICompanionDeviceDiscoveryServiceServer,
) ICompanionDeviceDiscoveryService

NewCompanionDeviceDiscoveryServiceStub creates a server-side ICompanionDeviceDiscoveryService wrapping the given server implementation. The returned value satisfies ICompanionDeviceDiscoveryService and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type ICompanionDeviceDiscoveryServiceServer

type ICompanionDeviceDiscoveryServiceServer interface {
	StartDiscovery(ctx context.Context, request AssociationRequest, applicationCallback IAssociationRequestCallback, serviceCallback infra.AndroidFuture) error
	OnAssociationCreated(ctx context.Context) error
}

ICompanionDeviceDiscoveryServiceServer is the server-side interface that user implementations provide to NewCompanionDeviceDiscoveryServiceStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type ICompanionDeviceManager

type ICompanionDeviceManager interface {
	AsBinder() binder.IBinder
	Associate(ctx context.Context, request AssociationRequest, callback IAssociationRequestCallback) error
	GetAssociations(ctx context.Context) ([]AssociationInfo, error)
	GetAllAssociationsForUser(ctx context.Context) ([]AssociationInfo, error)
	LegacyDisassociate(ctx context.Context, deviceMacAddress string) error
	Disassociate(ctx context.Context, associationId int32) error
	HasNotificationAccess(ctx context.Context, component content.ComponentName) (bool, error)
	RequestNotificationAccess(ctx context.Context, component content.ComponentName) (app.PendingIntent, error)
	IsDeviceAssociatedForWifiConnection(ctx context.Context, packageName string, macAddress string) (bool, error)
	RegisterDevicePresenceListenerService(ctx context.Context, deviceAddress string) error
	UnregisterDevicePresenceListenerService(ctx context.Context, deviceAddress string) error
	CanPairWithoutPrompt(ctx context.Context, packageName string, deviceMacAddress string) (bool, error)
	CreateAssociation(ctx context.Context, packageName string, macAddress string, certificate []byte) error
	AddOnAssociationsChangedListener(ctx context.Context, listener IOnAssociationsChangedListener) error
	RemoveOnAssociationsChangedListener(ctx context.Context, listener IOnAssociationsChangedListener) error
	AddOnTransportsChangedListener(ctx context.Context, listener IOnTransportsChangedListener) error
	RemoveOnTransportsChangedListener(ctx context.Context, listener IOnTransportsChangedListener) error
	SendMessage(ctx context.Context, messageType int32, data []byte, associationIds []int32) error
	AddOnMessageReceivedListener(ctx context.Context, messageType int32, listener IOnMessageReceivedListener) error
	RemoveOnMessageReceivedListener(ctx context.Context, messageType int32, listener IOnMessageReceivedListener) error
	NotifyDeviceAppeared(ctx context.Context, associationId int32) error
	NotifyDeviceDisappeared(ctx context.Context, associationId int32) error
	BuildPermissionTransferUserConsentIntent(ctx context.Context, associationId int32) (app.PendingIntent, error)
	IsPermissionTransferUserConsented(ctx context.Context, associationId int32) (bool, error)
	StartSystemDataTransfer(ctx context.Context, packageName string, associationId int32, callback ISystemDataTransferCallback) error
	AttachSystemDataTransport(ctx context.Context, packageName string, associationId int32, fd int32) error
	DetachSystemDataTransport(ctx context.Context, packageName string, associationId int32) error
	IsCompanionApplicationBound(ctx context.Context, packageName string) (bool, error)
	BuildAssociationCancellationIntent(ctx context.Context) (app.PendingIntent, error)
	EnableSystemDataSync(ctx context.Context, associationId int32, flags int32) error
	DisableSystemDataSync(ctx context.Context, associationId int32, flags int32) error
	EnablePermissionsSync(ctx context.Context, associationId int32) error
	DisablePermissionsSync(ctx context.Context, associationId int32) error
	GetPermissionSyncRequest(ctx context.Context, associationId int32) (datatransfer.PermissionSyncRequest, error)
	EnableSecureTransport(ctx context.Context, enabled bool) error
	SetAssociationTag(ctx context.Context, associationId int32, tag string) error
	ClearAssociationTag(ctx context.Context, associationId int32) error
	GetBackupPayload(ctx context.Context) ([]byte, error)
	ApplyRestoredPayload(ctx context.Context, payload []byte) error
	StartObservingDevicePresence(ctx context.Context, request ObservingDevicePresenceRequest, packageName string) error
	StopObservingDevicePresence(ctx context.Context, request ObservingDevicePresenceRequest, packageName string) error
}

func NewCompanionDeviceManagerStub

func NewCompanionDeviceManagerStub(
	impl ICompanionDeviceManagerServer,
) ICompanionDeviceManager

NewCompanionDeviceManagerStub creates a server-side ICompanionDeviceManager wrapping the given server implementation. The returned value satisfies ICompanionDeviceManager and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type ICompanionDeviceManagerServer

type ICompanionDeviceManagerServer interface {
	Associate(ctx context.Context, request AssociationRequest, callback IAssociationRequestCallback) error
	GetAssociations(ctx context.Context) ([]AssociationInfo, error)
	GetAllAssociationsForUser(ctx context.Context) ([]AssociationInfo, error)
	LegacyDisassociate(ctx context.Context, deviceMacAddress string) error
	Disassociate(ctx context.Context, associationId int32) error
	HasNotificationAccess(ctx context.Context, component content.ComponentName) (bool, error)
	RequestNotificationAccess(ctx context.Context, component content.ComponentName) (app.PendingIntent, error)
	IsDeviceAssociatedForWifiConnection(ctx context.Context, packageName string, macAddress string) (bool, error)
	RegisterDevicePresenceListenerService(ctx context.Context, deviceAddress string) error
	UnregisterDevicePresenceListenerService(ctx context.Context, deviceAddress string) error
	CanPairWithoutPrompt(ctx context.Context, packageName string, deviceMacAddress string) (bool, error)
	CreateAssociation(ctx context.Context, packageName string, macAddress string, certificate []byte) error
	AddOnAssociationsChangedListener(ctx context.Context, listener IOnAssociationsChangedListener) error
	RemoveOnAssociationsChangedListener(ctx context.Context, listener IOnAssociationsChangedListener) error
	AddOnTransportsChangedListener(ctx context.Context, listener IOnTransportsChangedListener) error
	RemoveOnTransportsChangedListener(ctx context.Context, listener IOnTransportsChangedListener) error
	SendMessage(ctx context.Context, messageType int32, data []byte, associationIds []int32) error
	AddOnMessageReceivedListener(ctx context.Context, messageType int32, listener IOnMessageReceivedListener) error
	RemoveOnMessageReceivedListener(ctx context.Context, messageType int32, listener IOnMessageReceivedListener) error
	NotifyDeviceAppeared(ctx context.Context, associationId int32) error
	NotifyDeviceDisappeared(ctx context.Context, associationId int32) error
	BuildPermissionTransferUserConsentIntent(ctx context.Context, associationId int32) (app.PendingIntent, error)
	IsPermissionTransferUserConsented(ctx context.Context, associationId int32) (bool, error)
	StartSystemDataTransfer(ctx context.Context, packageName string, associationId int32, callback ISystemDataTransferCallback) error
	AttachSystemDataTransport(ctx context.Context, packageName string, associationId int32, fd int32) error
	DetachSystemDataTransport(ctx context.Context, packageName string, associationId int32) error
	IsCompanionApplicationBound(ctx context.Context, packageName string) (bool, error)
	BuildAssociationCancellationIntent(ctx context.Context) (app.PendingIntent, error)
	EnableSystemDataSync(ctx context.Context, associationId int32, flags int32) error
	DisableSystemDataSync(ctx context.Context, associationId int32, flags int32) error
	EnablePermissionsSync(ctx context.Context, associationId int32) error
	DisablePermissionsSync(ctx context.Context, associationId int32) error
	GetPermissionSyncRequest(ctx context.Context, associationId int32) (datatransfer.PermissionSyncRequest, error)
	EnableSecureTransport(ctx context.Context, enabled bool) error
	SetAssociationTag(ctx context.Context, associationId int32, tag string) error
	ClearAssociationTag(ctx context.Context, associationId int32) error
	GetBackupPayload(ctx context.Context) ([]byte, error)
	ApplyRestoredPayload(ctx context.Context, payload []byte) error
	StartObservingDevicePresence(ctx context.Context, request ObservingDevicePresenceRequest, packageName string) error
	StopObservingDevicePresence(ctx context.Context, request ObservingDevicePresenceRequest, packageName string) error
}

ICompanionDeviceManagerServer is the server-side interface that user implementations provide to NewCompanionDeviceManagerStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type ICompanionDeviceService

type ICompanionDeviceService interface {
	AsBinder() binder.IBinder
	OnDeviceAppeared(ctx context.Context, associationInfo AssociationInfo) error
	OnDeviceDisappeared(ctx context.Context, associationInfo AssociationInfo) error
	OnDevicePresenceEvent(ctx context.Context, event DevicePresenceEvent) error
}

func NewCompanionDeviceServiceStub

func NewCompanionDeviceServiceStub(
	impl ICompanionDeviceServiceServer,
) ICompanionDeviceService

NewCompanionDeviceServiceStub creates a server-side ICompanionDeviceService wrapping the given server implementation. The returned value satisfies ICompanionDeviceService and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type ICompanionDeviceServiceServer

type ICompanionDeviceServiceServer interface {
	OnDeviceAppeared(ctx context.Context, associationInfo AssociationInfo) error
	OnDeviceDisappeared(ctx context.Context, associationInfo AssociationInfo) error
	OnDevicePresenceEvent(ctx context.Context, event DevicePresenceEvent) error
}

ICompanionDeviceServiceServer is the server-side interface that user implementations provide to NewCompanionDeviceServiceStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type IOnAssociationsChangedListener

type IOnAssociationsChangedListener interface {
	AsBinder() binder.IBinder
	OnAssociationsChanged(ctx context.Context, associations []AssociationInfo) error
}

func NewOnAssociationsChangedListenerStub

func NewOnAssociationsChangedListenerStub(
	impl IOnAssociationsChangedListenerServer,
) IOnAssociationsChangedListener

NewOnAssociationsChangedListenerStub creates a server-side IOnAssociationsChangedListener wrapping the given server implementation. The returned value satisfies IOnAssociationsChangedListener and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type IOnAssociationsChangedListenerServer

type IOnAssociationsChangedListenerServer interface {
	OnAssociationsChanged(ctx context.Context, associations []AssociationInfo) error
}

IOnAssociationsChangedListenerServer is the server-side interface that user implementations provide to NewOnAssociationsChangedListenerStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type IOnMessageReceivedListener

type IOnMessageReceivedListener interface {
	AsBinder() binder.IBinder
	OnMessageReceived(ctx context.Context, associationId int32, data []byte) error
}

func NewOnMessageReceivedListenerStub

func NewOnMessageReceivedListenerStub(
	impl IOnMessageReceivedListenerServer,
) IOnMessageReceivedListener

NewOnMessageReceivedListenerStub creates a server-side IOnMessageReceivedListener wrapping the given server implementation. The returned value satisfies IOnMessageReceivedListener and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type IOnMessageReceivedListenerServer

type IOnMessageReceivedListenerServer interface {
	OnMessageReceived(ctx context.Context, associationId int32, data []byte) error
}

IOnMessageReceivedListenerServer is the server-side interface that user implementations provide to NewOnMessageReceivedListenerStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type IOnTransportsChangedListener

type IOnTransportsChangedListener interface {
	AsBinder() binder.IBinder
	OnTransportsChanged(ctx context.Context, associations []AssociationInfo) error
}

func NewOnTransportsChangedListenerStub

func NewOnTransportsChangedListenerStub(
	impl IOnTransportsChangedListenerServer,
) IOnTransportsChangedListener

NewOnTransportsChangedListenerStub creates a server-side IOnTransportsChangedListener wrapping the given server implementation. The returned value satisfies IOnTransportsChangedListener and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type IOnTransportsChangedListenerServer

type IOnTransportsChangedListenerServer interface {
	OnTransportsChanged(ctx context.Context, associations []AssociationInfo) error
}

IOnTransportsChangedListenerServer is the server-side interface that user implementations provide to NewOnTransportsChangedListenerStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type ISystemDataTransferCallback

type ISystemDataTransferCallback interface {
	AsBinder() binder.IBinder
	OnResult(ctx context.Context) error
	OnError(ctx context.Context, error_ string) error
}

func NewSystemDataTransferCallbackStub

func NewSystemDataTransferCallbackStub(
	impl ISystemDataTransferCallbackServer,
) ISystemDataTransferCallback

NewSystemDataTransferCallbackStub creates a server-side ISystemDataTransferCallback wrapping the given server implementation. The returned value satisfies ISystemDataTransferCallback and can be passed to proxy methods; its AsBinder() returns a *binder.StubBinder that is auto-registered with the binder driver on first use.

type ISystemDataTransferCallbackServer

type ISystemDataTransferCallbackServer interface {
	OnResult(ctx context.Context) error
	OnError(ctx context.Context, error_ string) error
}

ISystemDataTransferCallbackServer is the server-side interface that user implementations provide to NewSystemDataTransferCallbackStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).

type ObservingDevicePresenceRequest

type ObservingDevicePresenceRequest struct {
	AssociationId int32
}

func (*ObservingDevicePresenceRequest) MarshalParcel

func (s *ObservingDevicePresenceRequest) MarshalParcel(
	p *parcel.Parcel,
) error

func (*ObservingDevicePresenceRequest) UnmarshalParcel

func (s *ObservingDevicePresenceRequest) UnmarshalParcel(
	p *parcel.Parcel,
) error

type OnAssociationsChangedListenerProxy

type OnAssociationsChangedListenerProxy struct {
	Remote binder.IBinder
}

func NewOnAssociationsChangedListenerProxy

func NewOnAssociationsChangedListenerProxy(
	remote binder.IBinder,
) *OnAssociationsChangedListenerProxy

func (*OnAssociationsChangedListenerProxy) AsBinder

func (*OnAssociationsChangedListenerProxy) OnAssociationsChanged

func (p *OnAssociationsChangedListenerProxy) OnAssociationsChanged(
	ctx context.Context,
	associations []AssociationInfo,
) error

type OnAssociationsChangedListenerStub

type OnAssociationsChangedListenerStub struct {
	Impl      IOnAssociationsChangedListener
	Transport binder.VersionAwareTransport
}

OnAssociationsChangedListenerStub dispatches incoming binder transactions to a typed IOnAssociationsChangedListener implementation.

func (*OnAssociationsChangedListenerStub) Descriptor

func (s *OnAssociationsChangedListenerStub) Descriptor() string

func (*OnAssociationsChangedListenerStub) OnTransaction

type OnMessageReceivedListenerProxy

type OnMessageReceivedListenerProxy struct {
	Remote binder.IBinder
}

func NewOnMessageReceivedListenerProxy

func NewOnMessageReceivedListenerProxy(
	remote binder.IBinder,
) *OnMessageReceivedListenerProxy

func (*OnMessageReceivedListenerProxy) AsBinder

func (*OnMessageReceivedListenerProxy) OnMessageReceived

func (p *OnMessageReceivedListenerProxy) OnMessageReceived(
	ctx context.Context,
	associationId int32,
	data []byte,
) error

type OnMessageReceivedListenerStub

type OnMessageReceivedListenerStub struct {
	Impl      IOnMessageReceivedListener
	Transport binder.VersionAwareTransport
}

OnMessageReceivedListenerStub dispatches incoming binder transactions to a typed IOnMessageReceivedListener implementation.

func (*OnMessageReceivedListenerStub) Descriptor

func (s *OnMessageReceivedListenerStub) Descriptor() string

func (*OnMessageReceivedListenerStub) OnTransaction

type OnTransportsChangedListenerProxy

type OnTransportsChangedListenerProxy struct {
	Remote binder.IBinder
}

func NewOnTransportsChangedListenerProxy

func NewOnTransportsChangedListenerProxy(
	remote binder.IBinder,
) *OnTransportsChangedListenerProxy

func (*OnTransportsChangedListenerProxy) AsBinder

func (*OnTransportsChangedListenerProxy) OnTransportsChanged

func (p *OnTransportsChangedListenerProxy) OnTransportsChanged(
	ctx context.Context,
	associations []AssociationInfo,
) error

type OnTransportsChangedListenerStub

type OnTransportsChangedListenerStub struct {
	Impl      IOnTransportsChangedListener
	Transport binder.VersionAwareTransport
}

OnTransportsChangedListenerStub dispatches incoming binder transactions to a typed IOnTransportsChangedListener implementation.

func (*OnTransportsChangedListenerStub) Descriptor

func (s *OnTransportsChangedListenerStub) Descriptor() string

func (*OnTransportsChangedListenerStub) OnTransaction

type SystemDataTransferCallbackProxy

type SystemDataTransferCallbackProxy struct {
	Remote binder.IBinder
}

func NewSystemDataTransferCallbackProxy

func NewSystemDataTransferCallbackProxy(
	remote binder.IBinder,
) *SystemDataTransferCallbackProxy

func (*SystemDataTransferCallbackProxy) AsBinder

func (*SystemDataTransferCallbackProxy) OnError

func (p *SystemDataTransferCallbackProxy) OnError(
	ctx context.Context,
	error_ string,
) error

func (*SystemDataTransferCallbackProxy) OnResult

type SystemDataTransferCallbackStub

type SystemDataTransferCallbackStub struct {
	Impl      ISystemDataTransferCallback
	Transport binder.VersionAwareTransport
}

SystemDataTransferCallbackStub dispatches incoming binder transactions to a typed ISystemDataTransferCallback implementation.

func (*SystemDataTransferCallbackStub) Descriptor

func (s *SystemDataTransferCallbackStub) Descriptor() string

func (*SystemDataTransferCallbackStub) OnTransaction

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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