addToBuilder static method

void addToBuilder(
  1. ObjCProtocolBuilder builder, {
  2. void stackView_willDetachViews_(
    1. NSStackView,
    2. NSArray
    )?,
  3. void stackView_didReattachViews_(
    1. NSStackView,
    2. NSArray
    )?,
  4. bool $keepIsolateAlive = true,
})

Adds the implementation of the NSStackViewDelegate protocol to an existing objc.ObjCProtocolBuilder.

Note: You cannot call this method after you have called builder.build.

Implementation

static void addToBuilder(
  objc.ObjCProtocolBuilder builder, {
  void Function(NSStackView, objc.NSArray)? stackView_willDetachViews_,
  void Function(NSStackView, objc.NSArray)? stackView_didReattachViews_,
  bool $keepIsolateAlive = true,
}) {
  NSStackViewDelegate.stackView_willDetachViews_.implement(
    builder,
    stackView_willDetachViews_,
  );
  NSStackViewDelegate.stackView_didReattachViews_.implement(
    builder,
    stackView_didReattachViews_,
  );
  builder.addProtocol($protocol);
}