writeGeneralUtilities method
void
writeGeneralUtilities(
- ObjcOptions generatorOptions,
- Root root,
- Indent indent, {
- required String dartPackageName,
override
Writes any necessary helper utilities to indent
if needed.
This method is not required, and does not need to be overridden.
Implementation
@override
void writeGeneralUtilities(
ObjcOptions generatorOptions,
Root root,
Indent indent, {
required String dartPackageName,
}) {
if (root.containsHostApi) {
_writeWrapError(indent);
indent.newln();
}
if (root.containsFlutterApi) {
_writeCreateConnectionError(indent);
indent.newln();
}
if (root.containsHostApi || root.containsFlutterApi) {
_writeGetNullableObjectAtIndex(indent);
}
if (root.requiresOverflowClass) {
_writeDataClassDeclaration(
generatorOptions,
root,
indent,
_overflowClass,
);
}
}