Documentation
¶
Index ¶
- Constants
- type IVibratorControlService
- type IVibratorControlServiceServer
- type IVibratorController
- type IVibratorControllerServer
- type ScaleParam
- type VibrationParam
- type VibratorControlServiceProxy
- func (p *VibratorControlServiceProxy) AsBinder() binder.IBinder
- func (p *VibratorControlServiceProxy) ClearVibrationParams(ctx context.Context, typesMask int32, token IVibratorController) error
- func (p *VibratorControlServiceProxy) OnRequestVibrationParamsComplete(ctx context.Context, requestToken binder.IBinder, result []VibrationParam) error
- func (p *VibratorControlServiceProxy) RegisterVibratorController(ctx context.Context, controller IVibratorController) error
- func (p *VibratorControlServiceProxy) SetVibrationParams(ctx context.Context, params []VibrationParam, token IVibratorController) error
- func (p *VibratorControlServiceProxy) UnregisterVibratorController(ctx context.Context, controller IVibratorController) error
- type VibratorControlServiceStub
- type VibratorControllerProxy
- type VibratorControllerStub
Constants ¶
const ( TransactionIVibratorControlServiceRegisterVibratorController = binder.FirstCallTransaction + 0 TransactionIVibratorControlServiceUnregisterVibratorController = binder.FirstCallTransaction + 1 TransactionIVibratorControlServiceSetVibrationParams = binder.FirstCallTransaction + 2 TransactionIVibratorControlServiceClearVibrationParams = binder.FirstCallTransaction + 3 TransactionIVibratorControlServiceOnRequestVibrationParamsComplete = binder.FirstCallTransaction + 4 )
const ( MethodIVibratorControlServiceRegisterVibratorController = "registerVibratorController" MethodIVibratorControlServiceUnregisterVibratorController = "unregisterVibratorController" MethodIVibratorControlServiceSetVibrationParams = "setVibrationParams" MethodIVibratorControlServiceClearVibrationParams = "clearVibrationParams" MethodIVibratorControlServiceOnRequestVibrationParamsComplete = "onRequestVibrationParamsComplete" )
const ( ScaleParamTypeAlarm int32 = (1 << 0) ScaleParamTypeNotification int32 = (1 << 1) ScaleParamTypeRingtone int32 = (1 << 2) ScaleParamTypeInteractive int32 = (1 << 3) ScaleParamTypeMedia int32 = (1 << 4) )
const DescriptorIVibratorControlService = "android.frameworks.vibrator.IVibratorControlService"
const DescriptorIVibratorController = "android.frameworks.vibrator.IVibratorController"
const (
MethodIVibratorControllerRequestVibrationParams = "requestVibrationParams"
)
const (
TransactionIVibratorControllerRequestVibrationParams = binder.FirstCallTransaction + 0
)
const (
VibrationParamTagScale int32 = 0
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IVibratorControlService ¶
type IVibratorControlService interface {
AsBinder() binder.IBinder
RegisterVibratorController(ctx context.Context, controller IVibratorController) error
UnregisterVibratorController(ctx context.Context, controller IVibratorController) error
SetVibrationParams(ctx context.Context, params []VibrationParam, token IVibratorController) error
ClearVibrationParams(ctx context.Context, typesMask int32, token IVibratorController) error
OnRequestVibrationParamsComplete(ctx context.Context, requestToken binder.IBinder, result []VibrationParam) error
}
func NewVibratorControlServiceStub ¶
func NewVibratorControlServiceStub( impl IVibratorControlServiceServer, ) IVibratorControlService
NewVibratorControlServiceStub creates a server-side IVibratorControlService wrapping the given server implementation. The returned value satisfies IVibratorControlService 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 IVibratorControlServiceServer ¶
type IVibratorControlServiceServer interface {
RegisterVibratorController(ctx context.Context, controller IVibratorController) error
UnregisterVibratorController(ctx context.Context, controller IVibratorController) error
SetVibrationParams(ctx context.Context, params []VibrationParam, token IVibratorController) error
ClearVibrationParams(ctx context.Context, typesMask int32, token IVibratorController) error
OnRequestVibrationParamsComplete(ctx context.Context, requestToken binder.IBinder, result []VibrationParam) error
}
IVibratorControlServiceServer is the server-side interface that user implementations provide to NewVibratorControlServiceStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).
type IVibratorController ¶
type IVibratorController interface {
AsBinder() binder.IBinder
RequestVibrationParams(ctx context.Context, typesMask int32, deadlineElapsedRealtimeMillis int64, requestToken binder.IBinder) error
}
func NewVibratorControllerStub ¶
func NewVibratorControllerStub( impl IVibratorControllerServer, ) IVibratorController
NewVibratorControllerStub creates a server-side IVibratorController wrapping the given server implementation. The returned value satisfies IVibratorController 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 IVibratorControllerServer ¶
type IVibratorControllerServer interface {
RequestVibrationParams(ctx context.Context, typesMask int32, deadlineElapsedRealtimeMillis int64, requestToken binder.IBinder) error
}
IVibratorControllerServer is the server-side interface that user implementations provide to NewVibratorControllerStub. It contains only the business methods, without AsBinder (which is provided by the stub itself).
type ScaleParam ¶
func (*ScaleParam) MarshalParcel ¶
func (s *ScaleParam) MarshalParcel( p *parcel.Parcel, ) error
func (*ScaleParam) UnmarshalParcel ¶
func (s *ScaleParam) UnmarshalParcel( p *parcel.Parcel, ) error
type VibrationParam ¶
type VibrationParam struct {
Tag int32
Scale ScaleParam
}
func (*VibrationParam) GetScale ¶
func (u *VibrationParam) GetScale() (ScaleParam, bool)
func (*VibrationParam) MarshalParcel ¶
func (u *VibrationParam) MarshalParcel( p *parcel.Parcel, ) error
func (*VibrationParam) SetScale ¶
func (u *VibrationParam) SetScale( v ScaleParam, )
func (*VibrationParam) UnmarshalParcel ¶
func (u *VibrationParam) UnmarshalParcel( p *parcel.Parcel, ) error
type VibratorControlServiceProxy ¶
func NewVibratorControlServiceProxy ¶
func NewVibratorControlServiceProxy( remote binder.IBinder, ) *VibratorControlServiceProxy
func (*VibratorControlServiceProxy) AsBinder ¶
func (p *VibratorControlServiceProxy) AsBinder() binder.IBinder
func (*VibratorControlServiceProxy) ClearVibrationParams ¶
func (p *VibratorControlServiceProxy) ClearVibrationParams( ctx context.Context, typesMask int32, token IVibratorController, ) error
func (*VibratorControlServiceProxy) OnRequestVibrationParamsComplete ¶
func (p *VibratorControlServiceProxy) OnRequestVibrationParamsComplete( ctx context.Context, requestToken binder.IBinder, result []VibrationParam, ) error
func (*VibratorControlServiceProxy) RegisterVibratorController ¶
func (p *VibratorControlServiceProxy) RegisterVibratorController( ctx context.Context, controller IVibratorController, ) error
func (*VibratorControlServiceProxy) SetVibrationParams ¶
func (p *VibratorControlServiceProxy) SetVibrationParams( ctx context.Context, params []VibrationParam, token IVibratorController, ) error
func (*VibratorControlServiceProxy) UnregisterVibratorController ¶
func (p *VibratorControlServiceProxy) UnregisterVibratorController( ctx context.Context, controller IVibratorController, ) error
type VibratorControlServiceStub ¶
type VibratorControlServiceStub struct {
Impl IVibratorControlService
Transport binder.VersionAwareTransport
}
VibratorControlServiceStub dispatches incoming binder transactions to a typed IVibratorControlService implementation.
func (*VibratorControlServiceStub) Descriptor ¶
func (s *VibratorControlServiceStub) Descriptor() string
func (*VibratorControlServiceStub) OnTransaction ¶
func (s *VibratorControlServiceStub) OnTransaction( ctx context.Context, code binder.TransactionCode, _data *parcel.Parcel, ) (*parcel.Parcel, error)
type VibratorControllerProxy ¶
func NewVibratorControllerProxy ¶
func NewVibratorControllerProxy( remote binder.IBinder, ) *VibratorControllerProxy
func (*VibratorControllerProxy) AsBinder ¶
func (p *VibratorControllerProxy) AsBinder() binder.IBinder
func (*VibratorControllerProxy) RequestVibrationParams ¶
type VibratorControllerStub ¶
type VibratorControllerStub struct {
Impl IVibratorController
Transport binder.VersionAwareTransport
}
VibratorControllerStub dispatches incoming binder transactions to a typed IVibratorController implementation.
func (*VibratorControllerStub) Descriptor ¶
func (s *VibratorControllerStub) Descriptor() string
func (*VibratorControllerStub) OnTransaction ¶
func (s *VibratorControllerStub) OnTransaction( ctx context.Context, code binder.TransactionCode, _data *parcel.Parcel, ) (*parcel.Parcel, error)