Struct script::dom::audioparam::AudioParam
source · #[repr(C)]pub struct AudioParam {
reflector_: Reflector,
context: Dom<BaseAudioContext>,
node: NodeId,
param: ParamType,
automation_rate: Cell<AutomationRate>,
default_value: f32,
min_value: f32,
max_value: f32,
}
Fields
reflector_: Reflector
context: Dom<BaseAudioContext>
node: NodeId
param: ParamType
automation_rate: Cell<AutomationRate>
default_value: f32
min_value: f32
max_value: f32
Implementations
sourceimpl AudioParam
impl AudioParam
pub fn new_inherited(
context: &BaseAudioContext,
node: NodeId,
param: ParamType,
automation_rate: AutomationRate,
default_value: f32,
min_value: f32,
max_value: f32
) -> AudioParam
pub fn new(
window: &Window,
context: &BaseAudioContext,
node: NodeId,
param: ParamType,
automation_rate: AutomationRate,
default_value: f32,
min_value: f32,
max_value: f32
) -> Root<Dom<AudioParam>>
fn message_node(&self, message: AudioNodeMessage)
pub fn context(&self) -> &BaseAudioContext
pub fn node_id(&self) -> NodeId
pub fn param_type(&self) -> ParamType
sourceimpl AudioParam
impl AudioParam
fn __assert_parent_type(&self)
Trait Implementations
sourceimpl AudioParamMethods for AudioParam
impl AudioParamMethods for AudioParam
fn AutomationRate(&self) -> AutomationRate
fn SetAutomationRate(&self, automation_rate: AutomationRate)
fn Value(&self) -> Finite<f32>
fn SetValue(&self, value: Finite<f32>)
fn DefaultValue(&self) -> Finite<f32>
fn MinValue(&self) -> Finite<f32>
fn MaxValue(&self) -> Finite<f32>
fn SetValueAtTime(
&self,
value: Finite<f32>,
start_time: Finite<f64>
) -> Result<Root<Dom<AudioParam>>, Error>
fn LinearRampToValueAtTime(
&self,
value: Finite<f32>,
end_time: Finite<f64>
) -> Result<Root<Dom<AudioParam>>, Error>
fn ExponentialRampToValueAtTime(
&self,
value: Finite<f32>,
end_time: Finite<f64>
) -> Result<Root<Dom<AudioParam>>, Error>
fn SetTargetAtTime(
&self,
target: Finite<f32>,
start_time: Finite<f64>,
time_constant: Finite<f32>
) -> Result<Root<Dom<AudioParam>>, Error>
fn SetValueCurveAtTime(
&self,
values: Vec<Finite<f32>>,
start_time: Finite<f64>,
end_time: Finite<f64>
) -> Result<Root<Dom<AudioParam>>, Error>
fn CancelScheduledValues(
&self,
cancel_time: Finite<f64>
) -> Result<Root<Dom<AudioParam>>, Error>
fn CancelAndHoldAtTime(
&self,
cancel_time: Finite<f64>
) -> Result<Root<Dom<AudioParam>>, Error>
sourceimpl DomObject for AudioParam
impl DomObject for AudioParam
sourceimpl DomObjectWrap for AudioParam
impl DomObjectWrap for AudioParam
sourceconst WRAP: unsafe fn(_: SafeJSContext, _: &GlobalScope, _: Box<Self>) -> Root<Dom<Self>> = {dom::bindings::codegen::Bindings::AudioParamBinding::AudioParamBinding::Wrap as for<'a> unsafe fn(script_runtime::JSContext, &'a dom::globalscope::GlobalScope, std::boxed::Box<dom::audioparam::AudioParam>) -> dom::bindings::root::Root<dom::bindings::root::Dom<dom::audioparam::AudioParam>>}
const WRAP: unsafe fn(_: SafeJSContext, _: &GlobalScope, _: Box<Self>) -> Root<Dom<Self>> = {dom::bindings::codegen::Bindings::AudioParamBinding::AudioParamBinding::Wrap as for<'a> unsafe fn(script_runtime::JSContext, &'a dom::globalscope::GlobalScope, std::boxed::Box<dom::audioparam::AudioParam>) -> dom::bindings::root::Root<dom::bindings::root::Dom<dom::audioparam::AudioParam>>}
Function pointer to the general wrap function type
sourceimpl HasParent for AudioParam
impl HasParent for AudioParam
sourceimpl IDLInterface for AudioParam
impl IDLInterface for AudioParam
sourceimpl JSTraceable for AudioParam
impl JSTraceable for AudioParam
sourceimpl MallocSizeOf for AudioParam
impl MallocSizeOf for AudioParam
sourcefn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Measure the heap usage of all descendant heap-allocated structures, but
not the space taken up by the value itself. Read more
sourceimpl MutDomObject for AudioParam
impl MutDomObject for AudioParam
sourceunsafe fn init_reflector(&self, obj: *mut JSObject)
unsafe fn init_reflector(&self, obj: *mut JSObject)
Initializes the Reflector
sourceimpl PartialEq<AudioParam> for AudioParam
impl PartialEq<AudioParam> for AudioParam
sourcefn eq(&self, other: &AudioParam) -> bool
fn eq(&self, other: &AudioParam) -> bool
sourceimpl ToJSValConvertible for AudioParam
impl ToJSValConvertible for AudioParam
sourceunsafe fn to_jsval(&self, cx: *mut JSContext, rval: MutableHandleValue<'_>)
unsafe fn to_jsval(&self, cx: *mut JSContext, rval: MutableHandleValue<'_>)
Convert
self
to a JSVal
. JSAPI failure causes a panic.Auto Trait Implementations
impl !RefUnwindSafe for AudioParam
impl !Send for AudioParam
impl !Sync for AudioParam
impl Unpin for AudioParam
impl !UnwindSafe for AudioParam
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> MaybeBoxed<Box<T, Global>> for T
impl<T> MaybeBoxed<Box<T, Global>> for T
sourcefn maybe_boxed(self) -> Box<T, Global>
fn maybe_boxed(self) -> Box<T, Global>
Convert
sourceimpl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
sourcefn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert