addToBuilderAsBlocking static method

void addToBuilderAsBlocking(
  1. ObjCProtocolBuilder builder, {
  2. NSTextInputTraitType autocorrectionType()?,
  3. void setAutocorrectionType_(
    1. NSTextInputTraitType
    )?,
  4. NSTextInputTraitType spellCheckingType()?,
  5. void setSpellCheckingType_(
    1. NSTextInputTraitType
    )?,
  6. NSTextInputTraitType grammarCheckingType()?,
  7. void setGrammarCheckingType_(
    1. NSTextInputTraitType
    )?,
  8. NSTextInputTraitType smartQuotesType()?,
  9. void setSmartQuotesType_(
    1. NSTextInputTraitType
    )?,
  10. NSTextInputTraitType smartDashesType()?,
  11. void setSmartDashesType_(
    1. NSTextInputTraitType
    )?,
  12. NSTextInputTraitType smartInsertDeleteType()?,
  13. void setSmartInsertDeleteType_(
    1. NSTextInputTraitType
    )?,
  14. NSTextInputTraitType textReplacementType()?,
  15. void setTextReplacementType_(
    1. NSTextInputTraitType
    )?,
  16. NSTextInputTraitType dataDetectionType()?,
  17. void setDataDetectionType_(
    1. NSTextInputTraitType
    )?,
  18. NSTextInputTraitType linkDetectionType()?,
  19. void setLinkDetectionType_(
    1. NSTextInputTraitType
    )?,
  20. NSTextInputTraitType textCompletionType()?,
  21. void setTextCompletionType_(
    1. NSTextInputTraitType
    )?,
  22. NSTextInputTraitType inlinePredictionType()?,
  23. void setInlinePredictionType_(
    1. NSTextInputTraitType
    )?,
  24. NSTextInputTraitType mathExpressionCompletionType()?,
  25. void setMathExpressionCompletionType_(
    1. NSTextInputTraitType
    )?,
  26. NSWritingToolsBehavior writingToolsBehavior()?,
  27. void setWritingToolsBehavior_(
    1. NSWritingToolsBehavior
    )?,
  28. NSWritingToolsResultOptions allowedWritingToolsResultOptions()?,
  29. void setAllowedWritingToolsResultOptions_(
    1. NSWritingToolsResultOptions
    )?,
  30. bool $keepIsolateAlive = true,
})

Adds the implementation of the NSTextInputTraits protocol to an existing objc.ObjCProtocolBuilder. All methods that can be implemented as blocking listeners will be.

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

Implementation

static void addToBuilderAsBlocking(
  objc.ObjCProtocolBuilder builder, {
  NSTextInputTraitType Function()? autocorrectionType,
  void Function(NSTextInputTraitType)? setAutocorrectionType_,
  NSTextInputTraitType Function()? spellCheckingType,
  void Function(NSTextInputTraitType)? setSpellCheckingType_,
  NSTextInputTraitType Function()? grammarCheckingType,
  void Function(NSTextInputTraitType)? setGrammarCheckingType_,
  NSTextInputTraitType Function()? smartQuotesType,
  void Function(NSTextInputTraitType)? setSmartQuotesType_,
  NSTextInputTraitType Function()? smartDashesType,
  void Function(NSTextInputTraitType)? setSmartDashesType_,
  NSTextInputTraitType Function()? smartInsertDeleteType,
  void Function(NSTextInputTraitType)? setSmartInsertDeleteType_,
  NSTextInputTraitType Function()? textReplacementType,
  void Function(NSTextInputTraitType)? setTextReplacementType_,
  NSTextInputTraitType Function()? dataDetectionType,
  void Function(NSTextInputTraitType)? setDataDetectionType_,
  NSTextInputTraitType Function()? linkDetectionType,
  void Function(NSTextInputTraitType)? setLinkDetectionType_,
  NSTextInputTraitType Function()? textCompletionType,
  void Function(NSTextInputTraitType)? setTextCompletionType_,
  NSTextInputTraitType Function()? inlinePredictionType,
  void Function(NSTextInputTraitType)? setInlinePredictionType_,
  NSTextInputTraitType Function()? mathExpressionCompletionType,
  void Function(NSTextInputTraitType)? setMathExpressionCompletionType_,
  NSWritingToolsBehavior Function()? writingToolsBehavior,
  void Function(NSWritingToolsBehavior)? setWritingToolsBehavior_,
  NSWritingToolsResultOptions Function()? allowedWritingToolsResultOptions,
  void Function(NSWritingToolsResultOptions)?
  setAllowedWritingToolsResultOptions_,
  bool $keepIsolateAlive = true,
}) {
  NSTextInputTraits.autocorrectionType.implement(builder, autocorrectionType);
  NSTextInputTraits.setAutocorrectionType_.implementAsBlocking(
    builder,
    setAutocorrectionType_,
  );
  NSTextInputTraits.spellCheckingType.implement(builder, spellCheckingType);
  NSTextInputTraits.setSpellCheckingType_.implementAsBlocking(
    builder,
    setSpellCheckingType_,
  );
  NSTextInputTraits.grammarCheckingType.implement(
    builder,
    grammarCheckingType,
  );
  NSTextInputTraits.setGrammarCheckingType_.implementAsBlocking(
    builder,
    setGrammarCheckingType_,
  );
  NSTextInputTraits.smartQuotesType.implement(builder, smartQuotesType);
  NSTextInputTraits.setSmartQuotesType_.implementAsBlocking(
    builder,
    setSmartQuotesType_,
  );
  NSTextInputTraits.smartDashesType.implement(builder, smartDashesType);
  NSTextInputTraits.setSmartDashesType_.implementAsBlocking(
    builder,
    setSmartDashesType_,
  );
  NSTextInputTraits.smartInsertDeleteType.implement(
    builder,
    smartInsertDeleteType,
  );
  NSTextInputTraits.setSmartInsertDeleteType_.implementAsBlocking(
    builder,
    setSmartInsertDeleteType_,
  );
  NSTextInputTraits.textReplacementType.implement(
    builder,
    textReplacementType,
  );
  NSTextInputTraits.setTextReplacementType_.implementAsBlocking(
    builder,
    setTextReplacementType_,
  );
  NSTextInputTraits.dataDetectionType.implement(builder, dataDetectionType);
  NSTextInputTraits.setDataDetectionType_.implementAsBlocking(
    builder,
    setDataDetectionType_,
  );
  NSTextInputTraits.linkDetectionType.implement(builder, linkDetectionType);
  NSTextInputTraits.setLinkDetectionType_.implementAsBlocking(
    builder,
    setLinkDetectionType_,
  );
  NSTextInputTraits.textCompletionType.implement(builder, textCompletionType);
  NSTextInputTraits.setTextCompletionType_.implementAsBlocking(
    builder,
    setTextCompletionType_,
  );
  NSTextInputTraits.inlinePredictionType.implement(
    builder,
    inlinePredictionType,
  );
  NSTextInputTraits.setInlinePredictionType_.implementAsBlocking(
    builder,
    setInlinePredictionType_,
  );
  NSTextInputTraits.mathExpressionCompletionType.implement(
    builder,
    mathExpressionCompletionType,
  );
  NSTextInputTraits.setMathExpressionCompletionType_.implementAsBlocking(
    builder,
    setMathExpressionCompletionType_,
  );
  NSTextInputTraits.writingToolsBehavior.implement(
    builder,
    writingToolsBehavior,
  );
  NSTextInputTraits.setWritingToolsBehavior_.implementAsBlocking(
    builder,
    setWritingToolsBehavior_,
  );
  NSTextInputTraits.allowedWritingToolsResultOptions.implement(
    builder,
    allowedWritingToolsResultOptions,
  );
  NSTextInputTraits.setAllowedWritingToolsResultOptions_.implementAsBlocking(
    builder,
    setAllowedWritingToolsResultOptions_,
  );
  builder.addProtocol($protocol);
}