Help us shape the future of Go! Take the 2026 Go Developer Survey

common

package
v0.0.9 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	AuthenticateReasonTagVendorAuthenticateReason      int32 = 0
	AuthenticateReasonTagFaceAuthenticateReason        int32 = 1
	AuthenticateReasonTagFingerprintAuthenticateReason int32 = 2
)
View Source
const (
	OperationStateTagFingerprintOperationState int32 = 0
	OperationStateTagFaceOperationState        int32 = 1
)
View Source
const DescriptorICancellationSignal = "android.hardware.biometrics.common.ICancellationSignal"
View Source
const (
	MethodICancellationSignalCancel = "cancel"
)
View Source
const (
	TransactionICancellationSignalCancel = binder.FirstCallTransaction + 0
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthenticateReason

type AuthenticateReason struct {
	Tag                           int32
	VendorAuthenticateReason      AuthenticateReasonVendor
	FaceAuthenticateReason        AuthenticateReasonFace
	FingerprintAuthenticateReason AuthenticateReasonFingerprint
}

func (*AuthenticateReason) GetFaceAuthenticateReason

func (u *AuthenticateReason) GetFaceAuthenticateReason() (AuthenticateReasonFace, bool)

func (*AuthenticateReason) GetFingerprintAuthenticateReason

func (u *AuthenticateReason) GetFingerprintAuthenticateReason() (AuthenticateReasonFingerprint, bool)

func (*AuthenticateReason) GetVendorAuthenticateReason

func (u *AuthenticateReason) GetVendorAuthenticateReason() (AuthenticateReasonVendor, bool)

func (*AuthenticateReason) MarshalParcel

func (u *AuthenticateReason) MarshalParcel(
	p *parcel.Parcel,
) error

func (*AuthenticateReason) SetFaceAuthenticateReason

func (u *AuthenticateReason) SetFaceAuthenticateReason(
	v AuthenticateReasonFace,
)

func (*AuthenticateReason) SetFingerprintAuthenticateReason

func (u *AuthenticateReason) SetFingerprintAuthenticateReason(
	v AuthenticateReasonFingerprint,
)

func (*AuthenticateReason) SetVendorAuthenticateReason

func (u *AuthenticateReason) SetVendorAuthenticateReason(
	v AuthenticateReasonVendor,
)

func (*AuthenticateReason) UnmarshalParcel

func (u *AuthenticateReason) UnmarshalParcel(
	p *parcel.Parcel,
) error

type AuthenticateReasonFace

type AuthenticateReasonFace int32
const (
	AuthenticateReasonFaceUNKNOWN                        AuthenticateReasonFace = 0
	AuthenticateReasonFaceStartedWakingUp                AuthenticateReasonFace = 1
	AuthenticateReasonFacePrimaryBouncerShown            AuthenticateReasonFace = 2
	AuthenticateReasonFaceAssistantVisible               AuthenticateReasonFace = 3
	AuthenticateReasonFaceAlternateBiometricBouncerShown AuthenticateReasonFace = 4
	AuthenticateReasonFaceNotificationPanelClicked       AuthenticateReasonFace = 5
	AuthenticateReasonFaceOccludingAppRequested          AuthenticateReasonFace = 6
	AuthenticateReasonFacePickUpGestureTriggered         AuthenticateReasonFace = 7
	AuthenticateReasonFaceQsExpanded                     AuthenticateReasonFace = 8
	AuthenticateReasonFaceSwipeUpOnBouncer               AuthenticateReasonFace = 9
	AuthenticateReasonFaceUdfpsPointerDown               AuthenticateReasonFace = 10
)

type AuthenticateReasonFingerprint

type AuthenticateReasonFingerprint int32
const (
	AuthenticateReasonFingerprintUNKNOWN AuthenticateReasonFingerprint = 0
)

type AuthenticateReasonVendor

type AuthenticateReasonVendor struct {
	Extension any
}

func (*AuthenticateReasonVendor) MarshalParcel

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

func (*AuthenticateReasonVendor) UnmarshalParcel

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

type CancellationSignalProxy

type CancellationSignalProxy struct {
	Remote binder.IBinder
}

func NewCancellationSignalProxy

func NewCancellationSignalProxy(
	remote binder.IBinder,
) *CancellationSignalProxy

func (*CancellationSignalProxy) AsBinder

func (p *CancellationSignalProxy) AsBinder() binder.IBinder

func (*CancellationSignalProxy) Cancel

func (p *CancellationSignalProxy) Cancel(
	ctx context.Context,
) error

type CancellationSignalStub

type CancellationSignalStub struct {
	Impl      ICancellationSignal
	Transport binder.VersionAwareTransport
}

CancellationSignalStub dispatches incoming binder transactions to a typed ICancellationSignal implementation.

func (*CancellationSignalStub) Descriptor

func (s *CancellationSignalStub) Descriptor() string

func (*CancellationSignalStub) OnTransaction

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

type CommonProps

type CommonProps struct {
	SensorId              int32
	SensorStrength        SensorStrength
	MaxEnrollmentsPerUser int32
	ComponentInfo         []ComponentInfo
}

func (*CommonProps) MarshalParcel

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

func (*CommonProps) UnmarshalParcel

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

type ComponentInfo

type ComponentInfo struct {
	ComponentId     string
	HardwareVersion string
	FirmwareVersion string
	SerialNumber    string
	SoftwareVersion string
}

func (*ComponentInfo) MarshalParcel

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

func (*ComponentInfo) UnmarshalParcel

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

type DisplayState

type DisplayState int32
const (
	DisplayStateUNKNOWN     DisplayState = 0
	DisplayStateLOCKSCREEN  DisplayState = 1
	DisplayStateNoUi        DisplayState = 2
	DisplayStateSCREENSAVER DisplayState = 3
	DisplayStateAOD         DisplayState = 4
)

type FoldState

type FoldState int32
const (
	FoldStateUNKNOWN     FoldState = 0
	FoldStateHalfOpened  FoldState = 1
	FoldStateFullyOpened FoldState = 2
	FoldStateFullyClosed FoldState = 3
)

type ICancellationSignal

type ICancellationSignal interface {
	AsBinder() binder.IBinder
	Cancel(ctx context.Context) error
}

func NewCancellationSignalStub

func NewCancellationSignalStub(
	impl ICancellationSignalServer,
) ICancellationSignal

NewCancellationSignalStub creates a server-side ICancellationSignal wrapping the given server implementation. The returned value satisfies ICancellationSignal 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 ICancellationSignalServer

type ICancellationSignalServer interface {
	Cancel(ctx context.Context) error
}

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

type OperationContext

type OperationContext struct {
	Id                 int32
	Reason             OperationReason
	IsAod              bool
	IsCrypto           bool
	WakeReason         WakeReason
	DisplayState       DisplayState
	AuthenticateReason *AuthenticateReason
	FoldState          FoldState
	OperationState     *OperationState
}

func (*OperationContext) MarshalParcel

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

func (*OperationContext) UnmarshalParcel

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

type OperationReason

type OperationReason byte
const (
	OperationReasonUNKNOWN         OperationReason = 0
	OperationReasonBiometricPrompt OperationReason = 1
	OperationReasonKEYGUARD        OperationReason = 2
)

type OperationState

type OperationState struct {
	Tag                       int32
	FingerprintOperationState OperationStateFingerprintOperationState
	FaceOperationState        OperationStateFaceOperationState
}

func (*OperationState) GetFaceOperationState

func (u *OperationState) GetFaceOperationState() (OperationStateFaceOperationState, bool)

func (*OperationState) GetFingerprintOperationState

func (u *OperationState) GetFingerprintOperationState() (OperationStateFingerprintOperationState, bool)

func (*OperationState) MarshalParcel

func (u *OperationState) MarshalParcel(
	p *parcel.Parcel,
) error

func (*OperationState) SetFaceOperationState

func (u *OperationState) SetFaceOperationState(
	v OperationStateFaceOperationState,
)

func (*OperationState) SetFingerprintOperationState

func (u *OperationState) SetFingerprintOperationState(
	v OperationStateFingerprintOperationState,
)

func (*OperationState) UnmarshalParcel

func (u *OperationState) UnmarshalParcel(
	p *parcel.Parcel,
) error

type OperationStateFaceOperationState

type OperationStateFaceOperationState struct {
	Extension any
}

func (*OperationStateFaceOperationState) MarshalParcel

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

func (*OperationStateFaceOperationState) UnmarshalParcel

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

type OperationStateFingerprintOperationState

type OperationStateFingerprintOperationState struct {
	Extension                 any
	IsHardwareIgnoringTouches bool
}

func (*OperationStateFingerprintOperationState) MarshalParcel

func (*OperationStateFingerprintOperationState) UnmarshalParcel

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

type SensorStrength

type SensorStrength byte
const (
	SensorStrengthCONVENIENCE SensorStrength = 0
	SensorStrengthWEAK        SensorStrength = 1
	SensorStrengthSTRONG      SensorStrength = 2
)

type WakeReason

type WakeReason int32
const (
	WakeReasonUNKNOWN           WakeReason = 0
	WakeReasonPowerButton       WakeReason = 1
	WakeReasonGESTURE           WakeReason = 2
	WakeReasonWakeKey           WakeReason = 3
	WakeReasonWakeMotion        WakeReason = 4
	WakeReasonLID               WakeReason = 5
	WakeReasonDisplayGroupAdded WakeReason = 6
	WakeReasonTAP               WakeReason = 7
	WakeReasonLIFT              WakeReason = 8
	WakeReasonBIOMETRIC         WakeReason = 9
)

Jump to

Keyboard shortcuts

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