pub enum MethodKind {
Method,
Constructor,
Field,
Getter,
Setter,
StaticBlock,
ClassSource,
}Expand description
クラスメンバの種別。
Variants§
Method
Constructor
Field
フィールド宣言(x = expr; または x;、#x = expr; を含む)。
params/body は使わず、初期化式は ClassMember::field_init に持つ。
Getter
get name() {...}(アクセサ getter)。
Setter
set name(v) {...}(アクセサ setter)。
StaticBlock
static { ... }(ES2022 静的初期化ブロック)。body に文の列を持つ
(key/params/field_init は使わない)。
ClassSource
クラス全体のソースを持つだけの仮のメンバ(body のソース範囲だけを使う。Function.prototype.toString 用)。
Trait Implementations§
Source§impl Clone for MethodKind
impl Clone for MethodKind
Source§impl Debug for MethodKind
impl Debug for MethodKind
Source§impl PartialEq for MethodKind
impl PartialEq for MethodKind
impl StructuralPartialEq for MethodKind
Auto Trait Implementations§
impl Freeze for MethodKind
impl RefUnwindSafe for MethodKind
impl Send for MethodKind
impl Sync for MethodKind
impl Unpin for MethodKind
impl UnsafeUnpin for MethodKind
impl UnwindSafe for MethodKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more