diff --git a/pkgs/ffigen/CHANGELOG.md b/pkgs/ffigen/CHANGELOG.md
index dc25359e6b..2ce3d350b5 100644
--- a/pkgs/ffigen/CHANGELOG.md
+++ b/pkgs/ffigen/CHANGELOG.md
@@ -3,6 +3,9 @@
- Create a public facing API for ffigen that can be invoked as a library:
`void generate(Config config)`. Make `Config` an implementatble interface,
rather than needing to be parsed from yaml.
+- Add a `external-versions` config option. Setting the minimum target
+ version will omit APIs from the generated bindings if they were deprecated
+ before this version.
## 13.0.0
diff --git a/pkgs/ffigen/README.md b/pkgs/ffigen/README.md
index a5b87fa8f9..cc1a85aaf7 100644
--- a/pkgs/ffigen/README.md
+++ b/pkgs/ffigen/README.md
@@ -662,7 +662,41 @@ import:
- 'package:some_pkg/symbols.yaml'
- 'path/to/some/symbol_file.yaml'
```
-
+
+
+
+
+
+ external-versions
+ |
+
+ Interfaces, methods, and other API elements may be marked with
+ deprecation annotations that indicate which platform version they were
+ deprecated in. If external-versions is set, APIs that were
+ deprecated as of the minimum version will be omitted from the
+ generated bindings.
+
+ The minimum version is specified per platform, and an API will be
+ generated if it is available on *any* of the targeted platform versions.
+ If a version is not specified for a particular platform, the API's
+ inclusion will be based purely on the platforms that have a specified
+ minimum version.
+
+ Current support OS keys are ios and macos. If you have a use case for
+ version checking on other OSs, please file an issue.
+ |
+
+
+```yaml
+external-versions:
+ # See https://docs.flutter.dev/reference/supported-platforms.
+ ios:
+ min: 12.0.0
+ macos:
+ min: 10.14.0
+```
+
+ |
diff --git a/pkgs/ffigen/ffigen.schema.json b/pkgs/ffigen/ffigen.schema.json
index e5f6b0f32d..f849a875db 100644
--- a/pkgs/ffigen/ffigen.schema.json
+++ b/pkgs/ffigen/ffigen.schema.json
@@ -469,6 +469,30 @@
},
"silence-enum-warning": {
"type": "boolean"
+ },
+ "external-versions": {
+ "type": "object",
+ "additionalProperties": false,
+ "properties": {
+ "ios": {
+ "type": "object",
+ "additionalProperties": false,
+ "properties": {
+ "min": {
+ "type": "string"
+ }
+ }
+ },
+ "macos": {
+ "type": "object",
+ "additionalProperties": false,
+ "properties": {
+ "min": {
+ "type": "string"
+ }
+ }
+ }
+ }
}
},
"required": [
diff --git a/pkgs/ffigen/lib/src/config_provider/config.dart b/pkgs/ffigen/lib/src/config_provider/config.dart
index dbd9c04f23..2f410aee4f 100644
--- a/pkgs/ffigen/lib/src/config_provider/config.dart
+++ b/pkgs/ffigen/lib/src/config_provider/config.dart
@@ -167,6 +167,10 @@ abstract interface class Config {
/// Whether to format the output file.
bool get formatOutput;
+ /// Minimum target versions for ObjC APIs, per OS. APIs that were deprecated
+ /// before this version will not be generated.
+ ExternalVersions get externalVersions;
+
factory Config({
Uri? filename,
PackageConfig? packageConfig,
@@ -177,7 +181,7 @@ abstract interface class Config {
Language language = Language.c,
required List entryPoints,
bool Function(Uri header)? shouldIncludeHeaderFunc,
- List compilerOpts = const [],
+ List? compilerOpts,
Map> varArgFunctions =
const >{},
DeclarationFilters? functionDecl,
@@ -218,6 +222,7 @@ abstract interface class Config {
FfiNativeConfig ffiNativeConfig = const FfiNativeConfig(enabled: false),
bool ignoreSourceErrors = false,
bool formatOutput = true,
+ ExternalVersions externalVersions = const ExternalVersions(),
}) =>
ConfigImpl(
filename: filename == null ? null : Uri.file(filename.toFilePath()),
@@ -231,7 +236,7 @@ abstract interface class Config {
language: language,
entryPoints: entryPoints,
shouldIncludeHeaderFunc: shouldIncludeHeaderFunc ?? (_) => true,
- compilerOpts: compilerOpts,
+ compilerOpts: compilerOpts ?? defaultCompilerOpts(),
varArgFunctions: varArgFunctions,
functionDecl: functionDecl ?? DeclarationFilters.excludeAll,
structDecl: structDecl ?? DeclarationFilters.excludeAll,
@@ -286,6 +291,7 @@ abstract interface class Config {
ffiNativeConfig: ffiNativeConfig,
ignoreSourceErrors: ignoreSourceErrors,
formatOutput: formatOutput,
+ externalVersions: externalVersions,
);
}
@@ -318,4 +324,8 @@ abstract interface class DeclarationFilters {
static final excludeAll = DeclarationFilters();
static final includeAll = DeclarationFilters(shouldInclude: (_) => true);
+
+ static DeclarationFilters include(Set names) => DeclarationFilters(
+ shouldInclude: (Declaration decl) => names.contains(decl.originalName),
+ );
}
diff --git a/pkgs/ffigen/lib/src/config_provider/config_impl.dart b/pkgs/ffigen/lib/src/config_provider/config_impl.dart
index 44518ea8ea..8516b5bf3e 100644
--- a/pkgs/ffigen/lib/src/config_provider/config_impl.dart
+++ b/pkgs/ffigen/lib/src/config_provider/config_impl.dart
@@ -172,6 +172,9 @@ class ConfigImpl implements Config {
@override
final bool formatOutput;
+ @override
+ final ExternalVersions externalVersions;
+
ConfigImpl({
required this.filename,
required this.packageConfig,
@@ -222,6 +225,7 @@ class ConfigImpl implements Config {
required this.ffiNativeConfig,
required this.ignoreSourceErrors,
required this.formatOutput,
+ required this.externalVersions,
});
}
diff --git a/pkgs/ffigen/lib/src/config_provider/config_types.dart b/pkgs/ffigen/lib/src/config_provider/config_types.dart
index 657f93d190..cfe63f8422 100644
--- a/pkgs/ffigen/lib/src/config_provider/config_types.dart
+++ b/pkgs/ffigen/lib/src/config_provider/config_types.dart
@@ -7,6 +7,7 @@ library;
import 'dart:io';
+import 'package:pub_semver/pub_semver.dart';
import 'package:quiver/pattern.dart' as quiver;
import '../code_generator.dart';
@@ -432,3 +433,19 @@ class Declaration {
required this.originalName,
});
}
+
+class ExternalVersions {
+ final Versions? ios;
+ final Versions? macos;
+ const ExternalVersions({this.ios, this.macos});
+}
+
+class Versions {
+ final Version? min;
+
+ // TODO(https://github.com/dart-lang/native/issues/300): max isn't supported
+ // yet.
+ final Version? max;
+
+ const Versions({this.min, this.max});
+}
diff --git a/pkgs/ffigen/lib/src/config_provider/spec_utils.dart b/pkgs/ffigen/lib/src/config_provider/spec_utils.dart
index aa1505a575..ce7a68fd4f 100644
--- a/pkgs/ffigen/lib/src/config_provider/spec_utils.dart
+++ b/pkgs/ffigen/lib/src/config_provider/spec_utils.dart
@@ -9,6 +9,7 @@ import 'package:glob/glob.dart';
import 'package:logging/logging.dart';
import 'package:package_config/package_config.dart';
import 'package:path/path.dart' as p;
+import 'package:pub_semver/pub_semver.dart';
import 'package:quiver/pattern.dart' as quiver;
import 'package:yaml/yaml.dart';
@@ -631,3 +632,23 @@ FfiNativeConfig ffiNativeExtractor(dynamic yamlConfig) {
assetId: yamlMap?[strings.ffiNativeAsset] as String?,
);
}
+
+ExternalVersions externalVersionsExtractor(Map? yamlConfig) =>
+ ExternalVersions(
+ ios: versionsExtractor(yamlConfig?[strings.ios]),
+ macos: versionsExtractor(yamlConfig?[strings.macos]),
+ );
+
+Versions? versionsExtractor(dynamic yamlConfig) {
+ final yamlMap = yamlConfig as Map?;
+ if (yamlMap == null) return null;
+ return Versions(
+ min: versionExtractor(yamlMap[strings.externalVersionsMin]),
+ );
+}
+
+Version? versionExtractor(dynamic yamlVersion) {
+ final versionString = yamlVersion as String?;
+ if (versionString == null) return null;
+ return Version.parse(versionString);
+}
diff --git a/pkgs/ffigen/lib/src/config_provider/yaml_config.dart b/pkgs/ffigen/lib/src/config_provider/yaml_config.dart
index 185e57ae7f..dafedd7731 100644
--- a/pkgs/ffigen/lib/src/config_provider/yaml_config.dart
+++ b/pkgs/ffigen/lib/src/config_provider/yaml_config.dart
@@ -284,6 +284,12 @@ class YamlConfig implements Config {
@override
bool formatOutput = true;
+ /// Minimum target versions for ObjC APIs, per OS. APIs that were deprecated
+ /// before this version will not be generated.
+ @override
+ ExternalVersions get externalVersions => _externalVersions;
+ late ExternalVersions _externalVersions;
+
YamlConfig._({required this.filename, required this.packageConfig});
/// Create config from Yaml map.
@@ -828,6 +834,28 @@ class YamlConfig implements Config {
defaultValue: (node) => false,
resultOrDefault: (node) => _silenceEnumWarning = node.value as bool,
),
+ HeterogeneousMapEntry(
+ key: strings.externalVersions,
+ valueConfigSpec: HeterogeneousMapConfigSpec(
+ entries: strings.externalVersionsPlatforms
+ .map((plat) => HeterogeneousMapEntry(
+ key: plat,
+ valueConfigSpec: HeterogeneousMapConfigSpec(
+ entries: [
+ HeterogeneousMapEntry(
+ key: strings.externalVersionsMin,
+ valueConfigSpec: StringConfigSpec(),
+ ),
+ ],
+ ),
+ ))
+ .toList(),
+ transform: (node) => externalVersionsExtractor(node.value),
+ ),
+ defaultValue: (node) => const ExternalVersions(),
+ resultOrDefault: (node) =>
+ _externalVersions = (node.value) as ExternalVersions,
+ ),
],
);
}
diff --git a/pkgs/ffigen/lib/src/header_parser/clang_bindings/clang_bindings.dart b/pkgs/ffigen/lib/src/header_parser/clang_bindings/clang_bindings.dart
index 331b0c6d1b..6f60ab9cfb 100644
--- a/pkgs/ffigen/lib/src/header_parser/clang_bindings/clang_bindings.dart
+++ b/pkgs/ffigen/lib/src/header_parser/clang_bindings/clang_bindings.dart
@@ -455,6 +455,118 @@ class Clang {
late final _clang_Cursor_hasAttrs =
_clang_Cursor_hasAttrsPtr.asFunction();
+ /// Determine the availability of the entity that this cursor refers to,
+ /// taking the current target platform into account.
+ ///
+ /// \param cursor The cursor to query.
+ ///
+ /// \returns The availability of the cursor.
+ int clang_getCursorAvailability(
+ CXCursor cursor,
+ ) {
+ return _clang_getCursorAvailability(
+ cursor,
+ );
+ }
+
+ late final _clang_getCursorAvailabilityPtr =
+ _lookup>(
+ 'clang_getCursorAvailability');
+ late final _clang_getCursorAvailability =
+ _clang_getCursorAvailabilityPtr.asFunction();
+
+ /// Determine the availability of the entity that this cursor refers to
+ /// on any platforms for which availability information is known.
+ ///
+ /// \param cursor The cursor to query.
+ ///
+ /// \param always_deprecated If non-NULL, will be set to indicate whether the
+ /// entity is deprecated on all platforms.
+ ///
+ /// \param deprecated_message If non-NULL, will be set to the message text
+ /// provided along with the unconditional deprecation of this entity. The client
+ /// is responsible for deallocating this string.
+ ///
+ /// \param always_unavailable If non-NULL, will be set to indicate whether the
+ /// entity is unavailable on all platforms.
+ ///
+ /// \param unavailable_message If non-NULL, will be set to the message text
+ /// provided along with the unconditional unavailability of this entity. The
+ /// client is responsible for deallocating this string.
+ ///
+ /// \param availability If non-NULL, an array of CXPlatformAvailability instances
+ /// that will be populated with platform availability information, up to either
+ /// the number of platforms for which availability information is available (as
+ /// returned by this function) or \c availability_size, whichever is smaller.
+ ///
+ /// \param availability_size The number of elements available in the
+ /// \c availability array.
+ ///
+ /// \returns The number of platforms (N) for which availability information is
+ /// available (which is unrelated to \c availability_size).
+ ///
+ /// Note that the client is responsible for calling
+ /// \c clang_disposeCXPlatformAvailability to free each of the
+ /// platform-availability structures returned. There are
+ /// \c min(N, availability_size) such structures.
+ int clang_getCursorPlatformAvailability(
+ CXCursor cursor,
+ ffi.Pointer always_deprecated,
+ ffi.Pointer deprecated_message,
+ ffi.Pointer always_unavailable,
+ ffi.Pointer unavailable_message,
+ ffi.Pointer availability,
+ int availability_size,
+ ) {
+ return _clang_getCursorPlatformAvailability(
+ cursor,
+ always_deprecated,
+ deprecated_message,
+ always_unavailable,
+ unavailable_message,
+ availability,
+ availability_size,
+ );
+ }
+
+ late final _clang_getCursorPlatformAvailabilityPtr = _lookup<
+ ffi.NativeFunction<
+ ffi.Int Function(
+ CXCursor,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Int)>>('clang_getCursorPlatformAvailability');
+ late final _clang_getCursorPlatformAvailability =
+ _clang_getCursorPlatformAvailabilityPtr.asFunction<
+ int Function(
+ CXCursor,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Pointer,
+ ffi.Pointer,
+ int)>();
+
+ /// Free the memory associated with a \c CXPlatformAvailability structure.
+ void clang_disposeCXPlatformAvailability(
+ ffi.Pointer availability,
+ ) {
+ return _clang_disposeCXPlatformAvailability(
+ availability,
+ );
+ }
+
+ late final _clang_disposeCXPlatformAvailabilityPtr = _lookup<
+ ffi.NativeFunction<
+ ffi.Void Function(ffi.Pointer)>>(
+ 'clang_disposeCXPlatformAvailability');
+ late final _clang_disposeCXPlatformAvailability =
+ _clang_disposeCXPlatformAvailabilityPtr
+ .asFunction)>();
+
/// Retrieve the physical location of the source constructor referenced
/// by the given cursor.
///
@@ -1513,13 +1625,13 @@ abstract class CXDiagnosticDisplayOptions {
/// \endcode
///
/// This option corresponds to the clang flag \c -fshow-source-location.
- static const int CXDiagnostic_DisplaySourceLocation = 1;
+ static const CXDiagnostic_DisplaySourceLocation = 1;
/// If displaying the source-location information of the
/// diagnostic, also include the column number.
///
/// This option corresponds to the clang flag \c -fshow-column.
- static const int CXDiagnostic_DisplayColumn = 2;
+ static const CXDiagnostic_DisplayColumn = 2;
/// If displaying the source-location information of the
/// diagnostic, also include information about source ranges in a
@@ -1527,51 +1639,51 @@ abstract class CXDiagnosticDisplayOptions {
///
/// This option corresponds to the clang flag
/// \c -fdiagnostics-print-source-range-info.
- static const int CXDiagnostic_DisplaySourceRanges = 4;
+ static const CXDiagnostic_DisplaySourceRanges = 4;
/// Display the option name associated with this diagnostic, if any.
///
/// The option name displayed (e.g., -Wconversion) will be placed in brackets
/// after the diagnostic text. This option corresponds to the clang flag
/// \c -fdiagnostics-show-option.
- static const int CXDiagnostic_DisplayOption = 8;
+ static const CXDiagnostic_DisplayOption = 8;
/// Display the category number associated with this diagnostic, if any.
///
/// The category number is displayed within brackets after the diagnostic text.
/// This option corresponds to the clang flag
/// \c -fdiagnostics-show-category=id.
- static const int CXDiagnostic_DisplayCategoryId = 16;
+ static const CXDiagnostic_DisplayCategoryId = 16;
/// Display the category name associated with this diagnostic, if any.
///
/// The category name is displayed within brackets after the diagnostic text.
/// This option corresponds to the clang flag
/// \c -fdiagnostics-show-category=name.
- static const int CXDiagnostic_DisplayCategoryName = 32;
+ static const CXDiagnostic_DisplayCategoryName = 32;
}
/// Describes the severity of a particular diagnostic.
abstract class CXDiagnosticSeverity {
/// A diagnostic that has been suppressed, e.g., by a command-line
/// option.
- static const int CXDiagnostic_Ignored = 0;
+ static const CXDiagnostic_Ignored = 0;
/// This diagnostic is a note that should be attached to the
/// previous (non-note) diagnostic.
- static const int CXDiagnostic_Note = 1;
+ static const CXDiagnostic_Note = 1;
/// This diagnostic indicates suspicious code that may not be
/// wrong.
- static const int CXDiagnostic_Warning = 2;
+ static const CXDiagnostic_Warning = 2;
/// This diagnostic indicates that the code is ill-formed.
- static const int CXDiagnostic_Error = 3;
+ static const CXDiagnostic_Error = 3;
/// This diagnostic indicates that the code is ill-formed such
/// that future parser recovery is unlikely to produce useful
/// results.
- static const int CXDiagnostic_Fatal = 4;
+ static const CXDiagnostic_Fatal = 4;
}
/// Flags that control the creation of translation units.
@@ -1582,7 +1694,7 @@ abstract class CXDiagnosticSeverity {
abstract class CXTranslationUnit_Flags {
/// Used to indicate that no special translation-unit options are
/// needed.
- static const int CXTranslationUnit_None = 0;
+ static const CXTranslationUnit_None = 0;
/// Used to indicate that the parser should construct a "detailed"
/// preprocessing record, including all macro definitions and instantiations.
@@ -1592,7 +1704,7 @@ abstract class CXTranslationUnit_Flags {
/// is usually not retained. However, it can be useful for
/// applications that require more detailed information about the
/// behavior of the preprocessor.
- static const int CXTranslationUnit_DetailedPreprocessingRecord = 1;
+ static const CXTranslationUnit_DetailedPreprocessingRecord = 1;
/// Used to indicate that the translation unit is incomplete.
///
@@ -1603,7 +1715,7 @@ abstract class CXTranslationUnit_Flags {
/// instantiation of implicitly-instantiation function templates in
/// C++. This option is typically used when parsing a header with the
/// intent of producing a precompiled header.
- static const int CXTranslationUnit_Incomplete = 2;
+ static const CXTranslationUnit_Incomplete = 2;
/// Used to indicate that the translation unit should be built with an
/// implicit precompiled header for the preamble.
@@ -1617,7 +1729,7 @@ abstract class CXTranslationUnit_Flags {
/// preamble or the files in it have not changed, \c
/// clang_reparseTranslationUnit() will re-use the implicit
/// precompiled header to improve parsing performance.
- static const int CXTranslationUnit_PrecompiledPreamble = 4;
+ static const CXTranslationUnit_PrecompiledPreamble = 4;
/// Used to indicate that the translation unit should cache some
/// code-completion results with each reparse of the source file.
@@ -1625,38 +1737,38 @@ abstract class CXTranslationUnit_Flags {
/// Caching of code-completion results is a performance optimization that
/// introduces some overhead to reparsing but improves the performance of
/// code-completion operations.
- static const int CXTranslationUnit_CacheCompletionResults = 8;
+ static const CXTranslationUnit_CacheCompletionResults = 8;
/// Used to indicate that the translation unit will be serialized with
/// \c clang_saveTranslationUnit.
///
/// This option is typically used when parsing a header with the intent of
/// producing a precompiled header.
- static const int CXTranslationUnit_ForSerialization = 16;
+ static const CXTranslationUnit_ForSerialization = 16;
/// DEPRECATED: Enabled chained precompiled preambles in C++.
///
/// Note: this is a *temporary* option that is available only while
/// we are testing C++ precompiled preamble support. It is deprecated.
- static const int CXTranslationUnit_CXXChainedPCH = 32;
+ static const CXTranslationUnit_CXXChainedPCH = 32;
/// Used to indicate that function/method bodies should be skipped while
/// parsing.
///
/// This option can be used to search for declarations/definitions while
/// ignoring the usages.
- static const int CXTranslationUnit_SkipFunctionBodies = 64;
+ static const CXTranslationUnit_SkipFunctionBodies = 64;
/// Used to indicate that brief documentation comments should be
/// included into the set of code completions returned from this translation
/// unit.
- static const int CXTranslationUnit_IncludeBriefCommentsInCodeCompletion = 128;
+ static const CXTranslationUnit_IncludeBriefCommentsInCodeCompletion = 128;
/// Used to indicate that the precompiled preamble should be created on
/// the first parse. Otherwise it will be created on the first reparse. This
/// trades runtime on the first parse (serializing the preamble takes time) for
/// reduced runtime on the second parse (can now reuse the preamble).
- static const int CXTranslationUnit_CreatePreambleOnFirstParse = 256;
+ static const CXTranslationUnit_CreatePreambleOnFirstParse = 256;
/// Do not stop processing when fatal errors are encountered.
///
@@ -1665,22 +1777,22 @@ abstract class CXTranslationUnit_Flags {
/// source for fatal errors are unresolvable include files. For the
/// purposes of an IDE, this is undesirable behavior and as much information
/// as possible should be reported. Use this flag to enable this behavior.
- static const int CXTranslationUnit_KeepGoing = 512;
+ static const CXTranslationUnit_KeepGoing = 512;
/// Sets the preprocessor in a mode for parsing a single file only.
- static const int CXTranslationUnit_SingleFileParse = 1024;
+ static const CXTranslationUnit_SingleFileParse = 1024;
/// Used in combination with CXTranslationUnit_SkipFunctionBodies to
/// constrain the skipping of function bodies to the preamble.
///
/// The function bodies of the main file are not skipped.
- static const int CXTranslationUnit_LimitSkipFunctionBodiesToPreamble = 2048;
+ static const CXTranslationUnit_LimitSkipFunctionBodiesToPreamble = 2048;
/// Used to indicate that attributed types should be included in CXType.
- static const int CXTranslationUnit_IncludeAttributedTypes = 4096;
+ static const CXTranslationUnit_IncludeAttributedTypes = 4096;
/// Used to indicate that implicit attributes should be visited.
- static const int CXTranslationUnit_VisitImplicitAttributes = 8192;
+ static const CXTranslationUnit_VisitImplicitAttributes = 8192;
/// Used to indicate that non-errors from included files should be ignored.
///
@@ -1688,10 +1800,10 @@ abstract class CXTranslationUnit_Flags {
/// included files anymore. This speeds up clang_getDiagnosticSetFromTU() for
/// the case where these warnings are not of interest, as for an IDE for
/// example, which typically shows only the diagnostics in the main file.
- static const int CXTranslationUnit_IgnoreNonErrorsFromIncludedFiles = 16384;
+ static const CXTranslationUnit_IgnoreNonErrorsFromIncludedFiles = 16384;
/// Tells the preprocessor not to skip excluded conditional blocks.
- static const int CXTranslationUnit_RetainExcludedConditionalBlocks = 32768;
+ static const CXTranslationUnit_RetainExcludedConditionalBlocks = 32768;
}
/// Describes the kind of entity that a cursor refers to.
@@ -1703,128 +1815,128 @@ abstract class CXCursorKind {
/// of declaration; one can extract their location information,
/// spelling, find their definitions, etc. However, the specific kind
/// of the declaration is not reported.
- static const int CXCursor_UnexposedDecl = 1;
+ static const CXCursor_UnexposedDecl = 1;
/// A C or C++ struct.
- static const int CXCursor_StructDecl = 2;
+ static const CXCursor_StructDecl = 2;
/// A C or C++ union.
- static const int CXCursor_UnionDecl = 3;
+ static const CXCursor_UnionDecl = 3;
/// A C++ class.
- static const int CXCursor_ClassDecl = 4;
+ static const CXCursor_ClassDecl = 4;
/// An enumeration.
- static const int CXCursor_EnumDecl = 5;
+ static const CXCursor_EnumDecl = 5;
/// A field (in C) or non-static data member (in C++) in a
/// struct, union, or C++ class.
- static const int CXCursor_FieldDecl = 6;
+ static const CXCursor_FieldDecl = 6;
/// An enumerator constant.
- static const int CXCursor_EnumConstantDecl = 7;
+ static const CXCursor_EnumConstantDecl = 7;
/// A function.
- static const int CXCursor_FunctionDecl = 8;
+ static const CXCursor_FunctionDecl = 8;
/// A variable.
- static const int CXCursor_VarDecl = 9;
+ static const CXCursor_VarDecl = 9;
/// A function or method parameter.
- static const int CXCursor_ParmDecl = 10;
+ static const CXCursor_ParmDecl = 10;
/// An Objective-C \@interface.
- static const int CXCursor_ObjCInterfaceDecl = 11;
+ static const CXCursor_ObjCInterfaceDecl = 11;
/// An Objective-C \@interface for a category.
- static const int CXCursor_ObjCCategoryDecl = 12;
+ static const CXCursor_ObjCCategoryDecl = 12;
/// An Objective-C \@protocol declaration.
- static const int CXCursor_ObjCProtocolDecl = 13;
+ static const CXCursor_ObjCProtocolDecl = 13;
/// An Objective-C \@property declaration.
- static const int CXCursor_ObjCPropertyDecl = 14;
+ static const CXCursor_ObjCPropertyDecl = 14;
/// An Objective-C instance variable.
- static const int CXCursor_ObjCIvarDecl = 15;
+ static const CXCursor_ObjCIvarDecl = 15;
/// An Objective-C instance method.
- static const int CXCursor_ObjCInstanceMethodDecl = 16;
+ static const CXCursor_ObjCInstanceMethodDecl = 16;
/// An Objective-C class method.
- static const int CXCursor_ObjCClassMethodDecl = 17;
+ static const CXCursor_ObjCClassMethodDecl = 17;
/// An Objective-C \@implementation.
- static const int CXCursor_ObjCImplementationDecl = 18;
+ static const CXCursor_ObjCImplementationDecl = 18;
/// An Objective-C \@implementation for a category.
- static const int CXCursor_ObjCCategoryImplDecl = 19;
+ static const CXCursor_ObjCCategoryImplDecl = 19;
/// A typedef.
- static const int CXCursor_TypedefDecl = 20;
+ static const CXCursor_TypedefDecl = 20;
/// A C++ class method.
- static const int CXCursor_CXXMethod = 21;
+ static const CXCursor_CXXMethod = 21;
/// A C++ namespace.
- static const int CXCursor_Namespace = 22;
+ static const CXCursor_Namespace = 22;
/// A linkage specification, e.g. 'extern "C"'.
- static const int CXCursor_LinkageSpec = 23;
+ static const CXCursor_LinkageSpec = 23;
/// A C++ constructor.
- static const int CXCursor_Constructor = 24;
+ static const CXCursor_Constructor = 24;
/// A C++ destructor.
- static const int CXCursor_Destructor = 25;
+ static const CXCursor_Destructor = 25;
/// A C++ conversion function.
- static const int CXCursor_ConversionFunction = 26;
+ static const CXCursor_ConversionFunction = 26;
/// A C++ template type parameter.
- static const int CXCursor_TemplateTypeParameter = 27;
+ static const CXCursor_TemplateTypeParameter = 27;
/// A C++ non-type template parameter.
- static const int CXCursor_NonTypeTemplateParameter = 28;
+ static const CXCursor_NonTypeTemplateParameter = 28;
/// A C++ template template parameter.
- static const int CXCursor_TemplateTemplateParameter = 29;
+ static const CXCursor_TemplateTemplateParameter = 29;
/// A C++ function template.
- static const int CXCursor_FunctionTemplate = 30;
+ static const CXCursor_FunctionTemplate = 30;
/// A C++ class template.
- static const int CXCursor_ClassTemplate = 31;
+ static const CXCursor_ClassTemplate = 31;
/// A C++ class template partial specialization.
- static const int CXCursor_ClassTemplatePartialSpecialization = 32;
+ static const CXCursor_ClassTemplatePartialSpecialization = 32;
/// A C++ namespace alias declaration.
- static const int CXCursor_NamespaceAlias = 33;
+ static const CXCursor_NamespaceAlias = 33;
/// A C++ using directive.
- static const int CXCursor_UsingDirective = 34;
+ static const CXCursor_UsingDirective = 34;
/// A C++ using declaration.
- static const int CXCursor_UsingDeclaration = 35;
+ static const CXCursor_UsingDeclaration = 35;
/// A C++ alias declaration
- static const int CXCursor_TypeAliasDecl = 36;
+ static const CXCursor_TypeAliasDecl = 36;
/// An Objective-C \@synthesize definition.
- static const int CXCursor_ObjCSynthesizeDecl = 37;
+ static const CXCursor_ObjCSynthesizeDecl = 37;
/// An Objective-C \@dynamic definition.
- static const int CXCursor_ObjCDynamicDecl = 38;
+ static const CXCursor_ObjCDynamicDecl = 38;
/// An access specifier.
- static const int CXCursor_CXXAccessSpecifier = 39;
- static const int CXCursor_FirstDecl = 1;
- static const int CXCursor_LastDecl = 39;
- static const int CXCursor_FirstRef = 40;
- static const int CXCursor_ObjCSuperClassRef = 40;
- static const int CXCursor_ObjCProtocolRef = 41;
- static const int CXCursor_ObjCClassRef = 42;
+ static const CXCursor_CXXAccessSpecifier = 39;
+ static const CXCursor_FirstDecl = 1;
+ static const CXCursor_LastDecl = 39;
+ static const CXCursor_FirstRef = 40;
+ static const CXCursor_ObjCSuperClassRef = 40;
+ static const CXCursor_ObjCProtocolRef = 41;
+ static const CXCursor_ObjCClassRef = 42;
/// A reference to a type declaration.
///
@@ -1839,19 +1951,19 @@ abstract class CXCursorKind {
/// The typedef is a declaration of size_type (CXCursor_TypedefDecl),
/// while the type of the variable "size" is referenced. The cursor
/// referenced by the type of size is the typedef for size_type.
- static const int CXCursor_TypeRef = 43;
- static const int CXCursor_CXXBaseSpecifier = 44;
+ static const CXCursor_TypeRef = 43;
+ static const CXCursor_CXXBaseSpecifier = 44;
/// A reference to a class template, function template, template
/// template parameter, or class template partial specialization.
- static const int CXCursor_TemplateRef = 45;
+ static const CXCursor_TemplateRef = 45;
/// A reference to a namespace or namespace alias.
- static const int CXCursor_NamespaceRef = 46;
+ static const CXCursor_NamespaceRef = 46;
/// A reference to a member of a struct, union, or class that occurs in
/// some non-expression context, e.g., a designated initializer.
- static const int CXCursor_MemberRef = 47;
+ static const CXCursor_MemberRef = 47;
/// A reference to a labeled statement.
///
@@ -1866,7 +1978,7 @@ abstract class CXCursorKind {
/// \endcode
///
/// A label reference cursor refers to a label statement.
- static const int CXCursor_LabelRef = 48;
+ static const CXCursor_LabelRef = 48;
/// A reference to a set of overloaded functions or function templates
/// that has not yet been resolved to a specific function or function template.
@@ -1902,19 +2014,19 @@ abstract class CXCursorKind {
/// The functions \c clang_getNumOverloadedDecls() and
/// \c clang_getOverloadedDecl() can be used to retrieve the definitions
/// referenced by this cursor.
- static const int CXCursor_OverloadedDeclRef = 49;
+ static const CXCursor_OverloadedDeclRef = 49;
/// A reference to a variable that occurs in some non-expression
/// context, e.g., a C++ lambda capture list.
- static const int CXCursor_VariableRef = 50;
- static const int CXCursor_LastRef = 50;
- static const int CXCursor_FirstInvalid = 70;
- static const int CXCursor_InvalidFile = 70;
- static const int CXCursor_NoDeclFound = 71;
- static const int CXCursor_NotImplemented = 72;
- static const int CXCursor_InvalidCode = 73;
- static const int CXCursor_LastInvalid = 73;
- static const int CXCursor_FirstExpr = 100;
+ static const CXCursor_VariableRef = 50;
+ static const CXCursor_LastRef = 50;
+ static const CXCursor_FirstInvalid = 70;
+ static const CXCursor_InvalidFile = 70;
+ static const CXCursor_NoDeclFound = 71;
+ static const CXCursor_NotImplemented = 72;
+ static const CXCursor_InvalidCode = 73;
+ static const CXCursor_LastInvalid = 73;
+ static const CXCursor_FirstExpr = 100;
/// An expression whose specific kind is not exposed via this
/// interface.
@@ -1923,83 +2035,83 @@ abstract class CXCursorKind {
/// of expression; one can extract their location information,
/// spelling, children, etc. However, the specific kind of the
/// expression is not reported.
- static const int CXCursor_UnexposedExpr = 100;
+ static const CXCursor_UnexposedExpr = 100;
/// An expression that refers to some value declaration, such
/// as a function, variable, or enumerator.
- static const int CXCursor_DeclRefExpr = 101;
+ static const CXCursor_DeclRefExpr = 101;
/// An expression that refers to a member of a struct, union,
/// class, Objective-C class, etc.
- static const int CXCursor_MemberRefExpr = 102;
+ static const CXCursor_MemberRefExpr = 102;
/// An expression that calls a function.
- static const int CXCursor_CallExpr = 103;
+ static const CXCursor_CallExpr = 103;
/// An expression that sends a message to an Objective-C
/// object or class.
- static const int CXCursor_ObjCMessageExpr = 104;
+ static const CXCursor_ObjCMessageExpr = 104;
/// An expression that represents a block literal.
- static const int CXCursor_BlockExpr = 105;
+ static const CXCursor_BlockExpr = 105;
/// An integer literal.
- static const int CXCursor_IntegerLiteral = 106;
+ static const CXCursor_IntegerLiteral = 106;
/// A floating point number literal.
- static const int CXCursor_FloatingLiteral = 107;
+ static const CXCursor_FloatingLiteral = 107;
/// An imaginary number literal.
- static const int CXCursor_ImaginaryLiteral = 108;
+ static const CXCursor_ImaginaryLiteral = 108;
/// A string literal.
- static const int CXCursor_StringLiteral = 109;
+ static const CXCursor_StringLiteral = 109;
/// A character literal.
- static const int CXCursor_CharacterLiteral = 110;
+ static const CXCursor_CharacterLiteral = 110;
/// A parenthesized expression, e.g. "(1)".
///
/// This AST node is only formed if full location information is requested.
- static const int CXCursor_ParenExpr = 111;
+ static const CXCursor_ParenExpr = 111;
/// This represents the unary-expression's (except sizeof and
/// alignof).
- static const int CXCursor_UnaryOperator = 112;
+ static const CXCursor_UnaryOperator = 112;
/// [C99 6.5.2.1] Array Subscripting.
- static const int CXCursor_ArraySubscriptExpr = 113;
+ static const CXCursor_ArraySubscriptExpr = 113;
/// A builtin binary operation expression such as "x + y" or
/// "x <= y".
- static const int CXCursor_BinaryOperator = 114;
+ static const CXCursor_BinaryOperator = 114;
/// Compound assignment such as "+=".
- static const int CXCursor_CompoundAssignOperator = 115;
+ static const CXCursor_CompoundAssignOperator = 115;
/// The ?: ternary operator.
- static const int CXCursor_ConditionalOperator = 116;
+ static const CXCursor_ConditionalOperator = 116;
/// An explicit cast in C (C99 6.5.4) or a C-style cast in C++
/// (C++ [expr.cast]), which uses the syntax (Type)expr.
///
/// For example: (int)f.
- static const int CXCursor_CStyleCastExpr = 117;
+ static const CXCursor_CStyleCastExpr = 117;
/// [C99 6.5.2.5]
- static const int CXCursor_CompoundLiteralExpr = 118;
+ static const CXCursor_CompoundLiteralExpr = 118;
/// Describes an C or C++ initializer list.
- static const int CXCursor_InitListExpr = 119;
+ static const CXCursor_InitListExpr = 119;
/// The GNU address of label extension, representing &&label.
- static const int CXCursor_AddrLabelExpr = 120;
+ static const CXCursor_AddrLabelExpr = 120;
/// This is the GNU Statement Expression extension: ({int X=4; X;})
- static const int CXCursor_StmtExpr = 121;
+ static const CXCursor_StmtExpr = 121;
/// Represents a C11 generic selection.
- static const int CXCursor_GenericSelectionExpr = 122;
+ static const CXCursor_GenericSelectionExpr = 122;
/// Implements the GNU __null extension, which is a name for a null
/// pointer constant that has integral type (e.g., int or long) and is the same
@@ -2008,19 +2120,19 @@ abstract class CXCursorKind {
/// The __null extension is typically only used by system headers, which define
/// NULL as __null in C++ rather than using 0 (which is an integer that may not
/// match the size of a pointer).
- static const int CXCursor_GNUNullExpr = 123;
+ static const CXCursor_GNUNullExpr = 123;
/// C++'s static_cast<> expression.
- static const int CXCursor_CXXStaticCastExpr = 124;
+ static const CXCursor_CXXStaticCastExpr = 124;
/// C++'s dynamic_cast<> expression.
- static const int CXCursor_CXXDynamicCastExpr = 125;
+ static const CXCursor_CXXDynamicCastExpr = 125;
/// C++'s reinterpret_cast<> expression.
- static const int CXCursor_CXXReinterpretCastExpr = 126;
+ static const CXCursor_CXXReinterpretCastExpr = 126;
/// C++'s const_cast<> expression.
- static const int CXCursor_CXXConstCastExpr = 127;
+ static const CXCursor_CXXConstCastExpr = 127;
/// Represents an explicit C++ type conversion that uses "functional"
/// notion (C++ [expr.type.conv]).
@@ -2029,48 +2141,48 @@ abstract class CXCursorKind {
/// \code
/// x = int(0.5);
/// \endcode
- static const int CXCursor_CXXFunctionalCastExpr = 128;
+ static const CXCursor_CXXFunctionalCastExpr = 128;
/// A C++ typeid expression (C++ [expr.typeid]).
- static const int CXCursor_CXXTypeidExpr = 129;
+ static const CXCursor_CXXTypeidExpr = 129;
/// [C++ 2.13.5] C++ Boolean Literal.
- static const int CXCursor_CXXBoolLiteralExpr = 130;
+ static const CXCursor_CXXBoolLiteralExpr = 130;
/// [C++0x 2.14.7] C++ Pointer Literal.
- static const int CXCursor_CXXNullPtrLiteralExpr = 131;
+ static const CXCursor_CXXNullPtrLiteralExpr = 131;
/// Represents the "this" expression in C++
- static const int CXCursor_CXXThisExpr = 132;
+ static const CXCursor_CXXThisExpr = 132;
/// [C++ 15] C++ Throw Expression.
///
/// This handles 'throw' and 'throw' assignment-expression. When
/// assignment-expression isn't present, Op will be null.
- static const int CXCursor_CXXThrowExpr = 133;
+ static const CXCursor_CXXThrowExpr = 133;
/// A new expression for memory allocation and constructor calls, e.g:
/// "new CXXNewExpr(foo)".
- static const int CXCursor_CXXNewExpr = 134;
+ static const CXCursor_CXXNewExpr = 134;
/// A delete expression for memory deallocation and destructor calls,
/// e.g. "delete[] pArray".
- static const int CXCursor_CXXDeleteExpr = 135;
+ static const CXCursor_CXXDeleteExpr = 135;
/// A unary expression. (noexcept, sizeof, or other traits)
- static const int CXCursor_UnaryExpr = 136;
+ static const CXCursor_UnaryExpr = 136;
/// An Objective-C string literal i.e. @"foo".
- static const int CXCursor_ObjCStringLiteral = 137;
+ static const CXCursor_ObjCStringLiteral = 137;
/// An Objective-C \@encode expression.
- static const int CXCursor_ObjCEncodeExpr = 138;
+ static const CXCursor_ObjCEncodeExpr = 138;
/// An Objective-C \@selector expression.
- static const int CXCursor_ObjCSelectorExpr = 139;
+ static const CXCursor_ObjCSelectorExpr = 139;
/// An Objective-C \@protocol expression.
- static const int CXCursor_ObjCProtocolExpr = 140;
+ static const CXCursor_ObjCProtocolExpr = 140;
/// An Objective-C "bridged" cast expression, which casts between
/// Objective-C pointers and C pointers, transferring ownership in the process.
@@ -2078,7 +2190,7 @@ abstract class CXCursorKind {
/// \code
/// NSString *str = (__bridge_transfer NSString *)CFCreateString();
/// \endcode
- static const int CXCursor_ObjCBridgedCastExpr = 141;
+ static const CXCursor_ObjCBridgedCastExpr = 141;
/// Represents a C++0x pack expansion that produces a sequence of
/// expressions.
@@ -2092,7 +2204,7 @@ abstract class CXCursorKind {
/// f(static_cast(args)...);
/// }
/// \endcode
- static const int CXCursor_PackExpansionExpr = 142;
+ static const CXCursor_PackExpansionExpr = 142;
/// Represents an expression that computes the length of a parameter
/// pack.
@@ -2103,25 +2215,25 @@ abstract class CXCursorKind {
/// static const unsigned value = sizeof...(Types);
/// };
/// \endcode
- static const int CXCursor_SizeOfPackExpr = 143;
- static const int CXCursor_LambdaExpr = 144;
+ static const CXCursor_SizeOfPackExpr = 143;
+ static const CXCursor_LambdaExpr = 144;
/// Objective-c Boolean Literal.
- static const int CXCursor_ObjCBoolLiteralExpr = 145;
+ static const CXCursor_ObjCBoolLiteralExpr = 145;
/// Represents the "self" expression in an Objective-C method.
- static const int CXCursor_ObjCSelfExpr = 146;
+ static const CXCursor_ObjCSelfExpr = 146;
/// OpenMP 4.0 [2.4, Array Section].
- static const int CXCursor_OMPArraySectionExpr = 147;
+ static const CXCursor_OMPArraySectionExpr = 147;
/// Represents an @available(...) check.
- static const int CXCursor_ObjCAvailabilityCheckExpr = 148;
+ static const CXCursor_ObjCAvailabilityCheckExpr = 148;
/// Fixed point literal
- static const int CXCursor_FixedPointLiteral = 149;
- static const int CXCursor_LastExpr = 149;
- static const int CXCursor_FirstStmt = 200;
+ static const CXCursor_FixedPointLiteral = 149;
+ static const CXCursor_LastExpr = 149;
+ static const CXCursor_FirstStmt = 200;
/// A statement whose specific kind is not exposed via this
/// interface.
@@ -2130,7 +2242,7 @@ abstract class CXCursorKind {
/// statement; one can extract their location information, spelling,
/// children, etc. However, the specific kind of the statement is not
/// reported.
- static const int CXCursor_UnexposedStmt = 200;
+ static const CXCursor_UnexposedStmt = 200;
/// A labelled statement in a function.
///
@@ -2141,343 +2253,342 @@ abstract class CXCursorKind {
/// start_over:
/// ++counter;
/// \endcode
- static const int CXCursor_LabelStmt = 201;
+ static const CXCursor_LabelStmt = 201;
/// A group of statements like { stmt stmt }.
///
/// This cursor kind is used to describe compound statements, e.g. function
/// bodies.
- static const int CXCursor_CompoundStmt = 202;
+ static const CXCursor_CompoundStmt = 202;
/// A case statement.
- static const int CXCursor_CaseStmt = 203;
+ static const CXCursor_CaseStmt = 203;
/// A default statement.
- static const int CXCursor_DefaultStmt = 204;
+ static const CXCursor_DefaultStmt = 204;
/// An if statement
- static const int CXCursor_IfStmt = 205;
+ static const CXCursor_IfStmt = 205;
/// A switch statement.
- static const int CXCursor_SwitchStmt = 206;
+ static const CXCursor_SwitchStmt = 206;
/// A while statement.
- static const int CXCursor_WhileStmt = 207;
+ static const CXCursor_WhileStmt = 207;
/// A do statement.
- static const int CXCursor_DoStmt = 208;
+ static const CXCursor_DoStmt = 208;
/// A for statement.
- static const int CXCursor_ForStmt = 209;
+ static const CXCursor_ForStmt = 209;
/// A goto statement.
- static const int CXCursor_GotoStmt = 210;
+ static const CXCursor_GotoStmt = 210;
/// An indirect goto statement.
- static const int CXCursor_IndirectGotoStmt = 211;
+ static const CXCursor_IndirectGotoStmt = 211;
/// A continue statement.
- static const int CXCursor_ContinueStmt = 212;
+ static const CXCursor_ContinueStmt = 212;
/// A break statement.
- static const int CXCursor_BreakStmt = 213;
+ static const CXCursor_BreakStmt = 213;
/// A return statement.
- static const int CXCursor_ReturnStmt = 214;
+ static const CXCursor_ReturnStmt = 214;
/// A GCC inline assembly statement extension.
- static const int CXCursor_GCCAsmStmt = 215;
- static const int CXCursor_AsmStmt = 215;
+ static const CXCursor_GCCAsmStmt = 215;
+ static const CXCursor_AsmStmt = 215;
/// Objective-C's overall \@try-\@catch-\@finally statement.
- static const int CXCursor_ObjCAtTryStmt = 216;
+ static const CXCursor_ObjCAtTryStmt = 216;
/// Objective-C's \@catch statement.
- static const int CXCursor_ObjCAtCatchStmt = 217;
+ static const CXCursor_ObjCAtCatchStmt = 217;
/// Objective-C's \@finally statement.
- static const int CXCursor_ObjCAtFinallyStmt = 218;
+ static const CXCursor_ObjCAtFinallyStmt = 218;
/// Objective-C's \@throw statement.
- static const int CXCursor_ObjCAtThrowStmt = 219;
+ static const CXCursor_ObjCAtThrowStmt = 219;
/// Objective-C's \@synchronized statement.
- static const int CXCursor_ObjCAtSynchronizedStmt = 220;
+ static const CXCursor_ObjCAtSynchronizedStmt = 220;
/// Objective-C's autorelease pool statement.
- static const int CXCursor_ObjCAutoreleasePoolStmt = 221;
+ static const CXCursor_ObjCAutoreleasePoolStmt = 221;
/// Objective-C's collection statement.
- static const int CXCursor_ObjCForCollectionStmt = 222;
+ static const CXCursor_ObjCForCollectionStmt = 222;
/// C++'s catch statement.
- static const int CXCursor_CXXCatchStmt = 223;
+ static const CXCursor_CXXCatchStmt = 223;
/// C++'s try statement.
- static const int CXCursor_CXXTryStmt = 224;
+ static const CXCursor_CXXTryStmt = 224;
/// C++'s for (* : *) statement.
- static const int CXCursor_CXXForRangeStmt = 225;
+ static const CXCursor_CXXForRangeStmt = 225;
/// Windows Structured Exception Handling's try statement.
- static const int CXCursor_SEHTryStmt = 226;
+ static const CXCursor_SEHTryStmt = 226;
/// Windows Structured Exception Handling's except statement.
- static const int CXCursor_SEHExceptStmt = 227;
+ static const CXCursor_SEHExceptStmt = 227;
/// Windows Structured Exception Handling's finally statement.
- static const int CXCursor_SEHFinallyStmt = 228;
+ static const CXCursor_SEHFinallyStmt = 228;
/// A MS inline assembly statement extension.
- static const int CXCursor_MSAsmStmt = 229;
+ static const CXCursor_MSAsmStmt = 229;
/// The null statement ";": C99 6.8.3p3.
///
/// This cursor kind is used to describe the null statement.
- static const int CXCursor_NullStmt = 230;
+ static const CXCursor_NullStmt = 230;
/// Adaptor class for mixing declarations with statements and
/// expressions.
- static const int CXCursor_DeclStmt = 231;
+ static const CXCursor_DeclStmt = 231;
/// OpenMP parallel directive.
- static const int CXCursor_OMPParallelDirective = 232;
+ static const CXCursor_OMPParallelDirective = 232;
/// OpenMP SIMD directive.
- static const int CXCursor_OMPSimdDirective = 233;
+ static const CXCursor_OMPSimdDirective = 233;
/// OpenMP for directive.
- static const int CXCursor_OMPForDirective = 234;
+ static const CXCursor_OMPForDirective = 234;
/// OpenMP sections directive.
- static const int CXCursor_OMPSectionsDirective = 235;
+ static const CXCursor_OMPSectionsDirective = 235;
/// OpenMP section directive.
- static const int CXCursor_OMPSectionDirective = 236;
+ static const CXCursor_OMPSectionDirective = 236;
/// OpenMP single directive.
- static const int CXCursor_OMPSingleDirective = 237;
+ static const CXCursor_OMPSingleDirective = 237;
/// OpenMP parallel for directive.
- static const int CXCursor_OMPParallelForDirective = 238;
+ static const CXCursor_OMPParallelForDirective = 238;
/// OpenMP parallel sections directive.
- static const int CXCursor_OMPParallelSectionsDirective = 239;
+ static const CXCursor_OMPParallelSectionsDirective = 239;
/// OpenMP task directive.
- static const int CXCursor_OMPTaskDirective = 240;
+ static const CXCursor_OMPTaskDirective = 240;
/// OpenMP master directive.
- static const int CXCursor_OMPMasterDirective = 241;
+ static const CXCursor_OMPMasterDirective = 241;
/// OpenMP critical directive.
- static const int CXCursor_OMPCriticalDirective = 242;
+ static const CXCursor_OMPCriticalDirective = 242;
/// OpenMP taskyield directive.
- static const int CXCursor_OMPTaskyieldDirective = 243;
+ static const CXCursor_OMPTaskyieldDirective = 243;
/// OpenMP barrier directive.
- static const int CXCursor_OMPBarrierDirective = 244;
+ static const CXCursor_OMPBarrierDirective = 244;
/// OpenMP taskwait directive.
- static const int CXCursor_OMPTaskwaitDirective = 245;
+ static const CXCursor_OMPTaskwaitDirective = 245;
/// OpenMP flush directive.
- static const int CXCursor_OMPFlushDirective = 246;
+ static const CXCursor_OMPFlushDirective = 246;
/// Windows Structured Exception Handling's leave statement.
- static const int CXCursor_SEHLeaveStmt = 247;
+ static const CXCursor_SEHLeaveStmt = 247;
/// OpenMP ordered directive.
- static const int CXCursor_OMPOrderedDirective = 248;
+ static const CXCursor_OMPOrderedDirective = 248;
/// OpenMP atomic directive.
- static const int CXCursor_OMPAtomicDirective = 249;
+ static const CXCursor_OMPAtomicDirective = 249;
/// OpenMP for SIMD directive.
- static const int CXCursor_OMPForSimdDirective = 250;
+ static const CXCursor_OMPForSimdDirective = 250;
/// OpenMP parallel for SIMD directive.
- static const int CXCursor_OMPParallelForSimdDirective = 251;
+ static const CXCursor_OMPParallelForSimdDirective = 251;
/// OpenMP target directive.
- static const int CXCursor_OMPTargetDirective = 252;
+ static const CXCursor_OMPTargetDirective = 252;
/// OpenMP teams directive.
- static const int CXCursor_OMPTeamsDirective = 253;
+ static const CXCursor_OMPTeamsDirective = 253;
/// OpenMP taskgroup directive.
- static const int CXCursor_OMPTaskgroupDirective = 254;
+ static const CXCursor_OMPTaskgroupDirective = 254;
/// OpenMP cancellation point directive.
- static const int CXCursor_OMPCancellationPointDirective = 255;
+ static const CXCursor_OMPCancellationPointDirective = 255;
/// OpenMP cancel directive.
- static const int CXCursor_OMPCancelDirective = 256;
+ static const CXCursor_OMPCancelDirective = 256;
/// OpenMP target data directive.
- static const int CXCursor_OMPTargetDataDirective = 257;
+ static const CXCursor_OMPTargetDataDirective = 257;
/// OpenMP taskloop directive.
- static const int CXCursor_OMPTaskLoopDirective = 258;
+ static const CXCursor_OMPTaskLoopDirective = 258;
/// OpenMP taskloop simd directive.
- static const int CXCursor_OMPTaskLoopSimdDirective = 259;
+ static const CXCursor_OMPTaskLoopSimdDirective = 259;
/// OpenMP distribute directive.
- static const int CXCursor_OMPDistributeDirective = 260;
+ static const CXCursor_OMPDistributeDirective = 260;
/// OpenMP target enter data directive.
- static const int CXCursor_OMPTargetEnterDataDirective = 261;
+ static const CXCursor_OMPTargetEnterDataDirective = 261;
/// OpenMP target exit data directive.
- static const int CXCursor_OMPTargetExitDataDirective = 262;
+ static const CXCursor_OMPTargetExitDataDirective = 262;
/// OpenMP target parallel directive.
- static const int CXCursor_OMPTargetParallelDirective = 263;
+ static const CXCursor_OMPTargetParallelDirective = 263;
/// OpenMP target parallel for directive.
- static const int CXCursor_OMPTargetParallelForDirective = 264;
+ static const CXCursor_OMPTargetParallelForDirective = 264;
/// OpenMP target update directive.
- static const int CXCursor_OMPTargetUpdateDirective = 265;
+ static const CXCursor_OMPTargetUpdateDirective = 265;
/// OpenMP distribute parallel for directive.
- static const int CXCursor_OMPDistributeParallelForDirective = 266;
+ static const CXCursor_OMPDistributeParallelForDirective = 266;
/// OpenMP distribute parallel for simd directive.
- static const int CXCursor_OMPDistributeParallelForSimdDirective = 267;
+ static const CXCursor_OMPDistributeParallelForSimdDirective = 267;
/// OpenMP distribute simd directive.
- static const int CXCursor_OMPDistributeSimdDirective = 268;
+ static const CXCursor_OMPDistributeSimdDirective = 268;
/// OpenMP target parallel for simd directive.
- static const int CXCursor_OMPTargetParallelForSimdDirective = 269;
+ static const CXCursor_OMPTargetParallelForSimdDirective = 269;
/// OpenMP target simd directive.
- static const int CXCursor_OMPTargetSimdDirective = 270;
+ static const CXCursor_OMPTargetSimdDirective = 270;
/// OpenMP teams distribute directive.
- static const int CXCursor_OMPTeamsDistributeDirective = 271;
+ static const CXCursor_OMPTeamsDistributeDirective = 271;
/// OpenMP teams distribute simd directive.
- static const int CXCursor_OMPTeamsDistributeSimdDirective = 272;
+ static const CXCursor_OMPTeamsDistributeSimdDirective = 272;
/// OpenMP teams distribute parallel for simd directive.
- static const int CXCursor_OMPTeamsDistributeParallelForSimdDirective = 273;
+ static const CXCursor_OMPTeamsDistributeParallelForSimdDirective = 273;
/// OpenMP teams distribute parallel for directive.
- static const int CXCursor_OMPTeamsDistributeParallelForDirective = 274;
+ static const CXCursor_OMPTeamsDistributeParallelForDirective = 274;
/// OpenMP target teams directive.
- static const int CXCursor_OMPTargetTeamsDirective = 275;
+ static const CXCursor_OMPTargetTeamsDirective = 275;
/// OpenMP target teams distribute directive.
- static const int CXCursor_OMPTargetTeamsDistributeDirective = 276;
+ static const CXCursor_OMPTargetTeamsDistributeDirective = 276;
/// OpenMP target teams distribute parallel for directive.
- static const int CXCursor_OMPTargetTeamsDistributeParallelForDirective = 277;
+ static const CXCursor_OMPTargetTeamsDistributeParallelForDirective = 277;
/// OpenMP target teams distribute parallel for simd directive.
- static const int CXCursor_OMPTargetTeamsDistributeParallelForSimdDirective =
- 278;
+ static const CXCursor_OMPTargetTeamsDistributeParallelForSimdDirective = 278;
/// OpenMP target teams distribute simd directive.
- static const int CXCursor_OMPTargetTeamsDistributeSimdDirective = 279;
+ static const CXCursor_OMPTargetTeamsDistributeSimdDirective = 279;
/// C++2a std::bit_cast expression.
- static const int CXCursor_BuiltinBitCastExpr = 280;
+ static const CXCursor_BuiltinBitCastExpr = 280;
/// OpenMP master taskloop directive.
- static const int CXCursor_OMPMasterTaskLoopDirective = 281;
+ static const CXCursor_OMPMasterTaskLoopDirective = 281;
/// OpenMP parallel master taskloop directive.
- static const int CXCursor_OMPParallelMasterTaskLoopDirective = 282;
+ static const CXCursor_OMPParallelMasterTaskLoopDirective = 282;
/// OpenMP master taskloop simd directive.
- static const int CXCursor_OMPMasterTaskLoopSimdDirective = 283;
+ static const CXCursor_OMPMasterTaskLoopSimdDirective = 283;
/// OpenMP parallel master taskloop simd directive.
- static const int CXCursor_OMPParallelMasterTaskLoopSimdDirective = 284;
+ static const CXCursor_OMPParallelMasterTaskLoopSimdDirective = 284;
/// OpenMP parallel master directive.
- static const int CXCursor_OMPParallelMasterDirective = 285;
- static const int CXCursor_LastStmt = 285;
+ static const CXCursor_OMPParallelMasterDirective = 285;
+ static const CXCursor_LastStmt = 285;
/// Cursor that represents the translation unit itself.
///
/// The translation unit cursor exists primarily to act as the root
/// cursor for traversing the contents of a translation unit.
- static const int CXCursor_TranslationUnit = 300;
- static const int CXCursor_FirstAttr = 400;
+ static const CXCursor_TranslationUnit = 300;
+ static const CXCursor_FirstAttr = 400;
/// An attribute whose specific kind is not exposed via this
/// interface.
- static const int CXCursor_UnexposedAttr = 400;
- static const int CXCursor_IBActionAttr = 401;
- static const int CXCursor_IBOutletAttr = 402;
- static const int CXCursor_IBOutletCollectionAttr = 403;
- static const int CXCursor_CXXFinalAttr = 404;
- static const int CXCursor_CXXOverrideAttr = 405;
- static const int CXCursor_AnnotateAttr = 406;
- static const int CXCursor_AsmLabelAttr = 407;
- static const int CXCursor_PackedAttr = 408;
- static const int CXCursor_PureAttr = 409;
- static const int CXCursor_ConstAttr = 410;
- static const int CXCursor_NoDuplicateAttr = 411;
- static const int CXCursor_CUDAConstantAttr = 412;
- static const int CXCursor_CUDADeviceAttr = 413;
- static const int CXCursor_CUDAGlobalAttr = 414;
- static const int CXCursor_CUDAHostAttr = 415;
- static const int CXCursor_CUDASharedAttr = 416;
- static const int CXCursor_VisibilityAttr = 417;
- static const int CXCursor_DLLExport = 418;
- static const int CXCursor_DLLImport = 419;
- static const int CXCursor_NSReturnsRetained = 420;
- static const int CXCursor_NSReturnsNotRetained = 421;
- static const int CXCursor_NSReturnsAutoreleased = 422;
- static const int CXCursor_NSConsumesSelf = 423;
- static const int CXCursor_NSConsumed = 424;
- static const int CXCursor_ObjCException = 425;
- static const int CXCursor_ObjCNSObject = 426;
- static const int CXCursor_ObjCIndependentClass = 427;
- static const int CXCursor_ObjCPreciseLifetime = 428;
- static const int CXCursor_ObjCReturnsInnerPointer = 429;
- static const int CXCursor_ObjCRequiresSuper = 430;
- static const int CXCursor_ObjCRootClass = 431;
- static const int CXCursor_ObjCSubclassingRestricted = 432;
- static const int CXCursor_ObjCExplicitProtocolImpl = 433;
- static const int CXCursor_ObjCDesignatedInitializer = 434;
- static const int CXCursor_ObjCRuntimeVisible = 435;
- static const int CXCursor_ObjCBoxable = 436;
- static const int CXCursor_FlagEnum = 437;
- static const int CXCursor_ConvergentAttr = 438;
- static const int CXCursor_WarnUnusedAttr = 439;
- static const int CXCursor_WarnUnusedResultAttr = 440;
- static const int CXCursor_AlignedAttr = 441;
- static const int CXCursor_LastAttr = 441;
- static const int CXCursor_PreprocessingDirective = 500;
- static const int CXCursor_MacroDefinition = 501;
- static const int CXCursor_MacroExpansion = 502;
- static const int CXCursor_MacroInstantiation = 502;
- static const int CXCursor_InclusionDirective = 503;
- static const int CXCursor_FirstPreprocessing = 500;
- static const int CXCursor_LastPreprocessing = 503;
+ static const CXCursor_UnexposedAttr = 400;
+ static const CXCursor_IBActionAttr = 401;
+ static const CXCursor_IBOutletAttr = 402;
+ static const CXCursor_IBOutletCollectionAttr = 403;
+ static const CXCursor_CXXFinalAttr = 404;
+ static const CXCursor_CXXOverrideAttr = 405;
+ static const CXCursor_AnnotateAttr = 406;
+ static const CXCursor_AsmLabelAttr = 407;
+ static const CXCursor_PackedAttr = 408;
+ static const CXCursor_PureAttr = 409;
+ static const CXCursor_ConstAttr = 410;
+ static const CXCursor_NoDuplicateAttr = 411;
+ static const CXCursor_CUDAConstantAttr = 412;
+ static const CXCursor_CUDADeviceAttr = 413;
+ static const CXCursor_CUDAGlobalAttr = 414;
+ static const CXCursor_CUDAHostAttr = 415;
+ static const CXCursor_CUDASharedAttr = 416;
+ static const CXCursor_VisibilityAttr = 417;
+ static const CXCursor_DLLExport = 418;
+ static const CXCursor_DLLImport = 419;
+ static const CXCursor_NSReturnsRetained = 420;
+ static const CXCursor_NSReturnsNotRetained = 421;
+ static const CXCursor_NSReturnsAutoreleased = 422;
+ static const CXCursor_NSConsumesSelf = 423;
+ static const CXCursor_NSConsumed = 424;
+ static const CXCursor_ObjCException = 425;
+ static const CXCursor_ObjCNSObject = 426;
+ static const CXCursor_ObjCIndependentClass = 427;
+ static const CXCursor_ObjCPreciseLifetime = 428;
+ static const CXCursor_ObjCReturnsInnerPointer = 429;
+ static const CXCursor_ObjCRequiresSuper = 430;
+ static const CXCursor_ObjCRootClass = 431;
+ static const CXCursor_ObjCSubclassingRestricted = 432;
+ static const CXCursor_ObjCExplicitProtocolImpl = 433;
+ static const CXCursor_ObjCDesignatedInitializer = 434;
+ static const CXCursor_ObjCRuntimeVisible = 435;
+ static const CXCursor_ObjCBoxable = 436;
+ static const CXCursor_FlagEnum = 437;
+ static const CXCursor_ConvergentAttr = 438;
+ static const CXCursor_WarnUnusedAttr = 439;
+ static const CXCursor_WarnUnusedResultAttr = 440;
+ static const CXCursor_AlignedAttr = 441;
+ static const CXCursor_LastAttr = 441;
+ static const CXCursor_PreprocessingDirective = 500;
+ static const CXCursor_MacroDefinition = 501;
+ static const CXCursor_MacroExpansion = 502;
+ static const CXCursor_MacroInstantiation = 502;
+ static const CXCursor_InclusionDirective = 503;
+ static const CXCursor_FirstPreprocessing = 500;
+ static const CXCursor_LastPreprocessing = 503;
/// A module import declaration.
- static const int CXCursor_ModuleImportDecl = 600;
- static const int CXCursor_TypeAliasTemplateDecl = 601;
+ static const CXCursor_ModuleImportDecl = 600;
+ static const CXCursor_TypeAliasTemplateDecl = 601;
/// A static_assert or _Static_assert node
- static const int CXCursor_StaticAssert = 602;
+ static const CXCursor_StaticAssert = 602;
/// a friend declaration.
- static const int CXCursor_FriendDecl = 603;
- static const int CXCursor_FirstExtraDecl = 600;
- static const int CXCursor_LastExtraDecl = 603;
+ static const CXCursor_FriendDecl = 603;
+ static const CXCursor_FirstExtraDecl = 600;
+ static const CXCursor_LastExtraDecl = 603;
/// A code completion overload candidate.
- static const int CXCursor_OverloadCandidate = 700;
+ static const CXCursor_OverloadCandidate = 700;
}
/// A cursor representing some element in the abstract syntax tree for
@@ -2507,134 +2618,202 @@ final class CXCursor extends ffi.Struct {
external ffi.Array> data;
}
+/// Describes the availability of a particular entity, which indicates
+/// whether the use of this entity will result in a warning or error due to
+/// it being deprecated or unavailable.
+abstract class CXAvailabilityKind {
+ /// The entity is available.
+ static const CXAvailability_Available = 0;
+
+ /// The entity is available, but has been deprecated (and its use is
+ /// not recommended).
+ static const CXAvailability_Deprecated = 1;
+
+ /// The entity is not available; any use of it will be an error.
+ static const CXAvailability_NotAvailable = 2;
+
+ /// The entity is available, but not accessible; any use of it will be
+ /// an error.
+ static const CXAvailability_NotAccessible = 3;
+}
+
+/// Describes the availability of a given entity on a particular platform, e.g.,
+/// a particular class might only be available on Mac OS 10.7 or newer.
+final class CXPlatformAvailability extends ffi.Struct {
+ /// A string that describes the platform for which this structure
+ /// provides availability information.
+ ///
+ /// Possible values are "ios" or "macos".
+ external CXString Platform;
+
+ /// The version number in which this entity was introduced.
+ external CXVersion Introduced;
+
+ /// The version number in which this entity was deprecated (but is
+ /// still available).
+ external CXVersion Deprecated;
+
+ /// The version number in which this entity was obsoleted, and therefore
+ /// is no longer available.
+ external CXVersion Obsoleted;
+
+ /// Whether the entity is unconditionally unavailable on this platform.
+ @ffi.Int()
+ external int Unavailable;
+
+ /// An optional message to provide to a user of this API, e.g., to
+ /// suggest replacement APIs.
+ external CXString Message;
+}
+
+/// Describes a version number of the form major.minor.subminor.
+final class CXVersion extends ffi.Struct {
+ /// The major version number, e.g., the '10' in '10.7.3'. A negative
+ /// value indicates that there is no version number at all.
+ @ffi.Int()
+ external int Major;
+
+ /// The minor version number, e.g., the '7' in '10.7.3'. This value
+ /// will be negative if no minor version number was provided, e.g., for
+ /// version '10'.
+ @ffi.Int()
+ external int Minor;
+
+ /// The subminor version number, e.g., the '3' in '10.7.3'. This value
+ /// will be negative if no minor or subminor version number was provided,
+ /// e.g., in version '10' or '10.7'.
+ @ffi.Int()
+ external int Subminor;
+}
+
/// Describes the kind of type
abstract class CXTypeKind {
/// Represents an invalid type (e.g., where no type is available).
- static const int CXType_Invalid = 0;
+ static const CXType_Invalid = 0;
/// A type whose specific kind is not exposed via this
/// interface.
- static const int CXType_Unexposed = 1;
- static const int CXType_Void = 2;
- static const int CXType_Bool = 3;
- static const int CXType_Char_U = 4;
- static const int CXType_UChar = 5;
- static const int CXType_Char16 = 6;
- static const int CXType_Char32 = 7;
- static const int CXType_UShort = 8;
- static const int CXType_UInt = 9;
- static const int CXType_ULong = 10;
- static const int CXType_ULongLong = 11;
- static const int CXType_UInt128 = 12;
- static const int CXType_Char_S = 13;
- static const int CXType_SChar = 14;
- static const int CXType_WChar = 15;
- static const int CXType_Short = 16;
- static const int CXType_Int = 17;
- static const int CXType_Long = 18;
- static const int CXType_LongLong = 19;
- static const int CXType_Int128 = 20;
- static const int CXType_Float = 21;
- static const int CXType_Double = 22;
- static const int CXType_LongDouble = 23;
- static const int CXType_NullPtr = 24;
- static const int CXType_Overload = 25;
- static const int CXType_Dependent = 26;
- static const int CXType_ObjCId = 27;
- static const int CXType_ObjCClass = 28;
- static const int CXType_ObjCSel = 29;
- static const int CXType_Float128 = 30;
- static const int CXType_Half = 31;
- static const int CXType_Float16 = 32;
- static const int CXType_ShortAccum = 33;
- static const int CXType_Accum = 34;
- static const int CXType_LongAccum = 35;
- static const int CXType_UShortAccum = 36;
- static const int CXType_UAccum = 37;
- static const int CXType_ULongAccum = 38;
- static const int CXType_FirstBuiltin = 2;
- static const int CXType_LastBuiltin = 38;
- static const int CXType_Complex = 100;
- static const int CXType_Pointer = 101;
- static const int CXType_BlockPointer = 102;
- static const int CXType_LValueReference = 103;
- static const int CXType_RValueReference = 104;
- static const int CXType_Record = 105;
- static const int CXType_Enum = 106;
- static const int CXType_Typedef = 107;
- static const int CXType_ObjCInterface = 108;
- static const int CXType_ObjCObjectPointer = 109;
- static const int CXType_FunctionNoProto = 110;
- static const int CXType_FunctionProto = 111;
- static const int CXType_ConstantArray = 112;
- static const int CXType_Vector = 113;
- static const int CXType_IncompleteArray = 114;
- static const int CXType_VariableArray = 115;
- static const int CXType_DependentSizedArray = 116;
- static const int CXType_MemberPointer = 117;
- static const int CXType_Auto = 118;
+ static const CXType_Unexposed = 1;
+ static const CXType_Void = 2;
+ static const CXType_Bool = 3;
+ static const CXType_Char_U = 4;
+ static const CXType_UChar = 5;
+ static const CXType_Char16 = 6;
+ static const CXType_Char32 = 7;
+ static const CXType_UShort = 8;
+ static const CXType_UInt = 9;
+ static const CXType_ULong = 10;
+ static const CXType_ULongLong = 11;
+ static const CXType_UInt128 = 12;
+ static const CXType_Char_S = 13;
+ static const CXType_SChar = 14;
+ static const CXType_WChar = 15;
+ static const CXType_Short = 16;
+ static const CXType_Int = 17;
+ static const CXType_Long = 18;
+ static const CXType_LongLong = 19;
+ static const CXType_Int128 = 20;
+ static const CXType_Float = 21;
+ static const CXType_Double = 22;
+ static const CXType_LongDouble = 23;
+ static const CXType_NullPtr = 24;
+ static const CXType_Overload = 25;
+ static const CXType_Dependent = 26;
+ static const CXType_ObjCId = 27;
+ static const CXType_ObjCClass = 28;
+ static const CXType_ObjCSel = 29;
+ static const CXType_Float128 = 30;
+ static const CXType_Half = 31;
+ static const CXType_Float16 = 32;
+ static const CXType_ShortAccum = 33;
+ static const CXType_Accum = 34;
+ static const CXType_LongAccum = 35;
+ static const CXType_UShortAccum = 36;
+ static const CXType_UAccum = 37;
+ static const CXType_ULongAccum = 38;
+ static const CXType_FirstBuiltin = 2;
+ static const CXType_LastBuiltin = 38;
+ static const CXType_Complex = 100;
+ static const CXType_Pointer = 101;
+ static const CXType_BlockPointer = 102;
+ static const CXType_LValueReference = 103;
+ static const CXType_RValueReference = 104;
+ static const CXType_Record = 105;
+ static const CXType_Enum = 106;
+ static const CXType_Typedef = 107;
+ static const CXType_ObjCInterface = 108;
+ static const CXType_ObjCObjectPointer = 109;
+ static const CXType_FunctionNoProto = 110;
+ static const CXType_FunctionProto = 111;
+ static const CXType_ConstantArray = 112;
+ static const CXType_Vector = 113;
+ static const CXType_IncompleteArray = 114;
+ static const CXType_VariableArray = 115;
+ static const CXType_DependentSizedArray = 116;
+ static const CXType_MemberPointer = 117;
+ static const CXType_Auto = 118;
/// Represents a type that was referred to using an elaborated type keyword.
///
/// E.g., struct S, or via a qualified name, e.g., N::M::type, or both.
- static const int CXType_Elaborated = 119;
- static const int CXType_Pipe = 120;
- static const int CXType_OCLImage1dRO = 121;
- static const int CXType_OCLImage1dArrayRO = 122;
- static const int CXType_OCLImage1dBufferRO = 123;
- static const int CXType_OCLImage2dRO = 124;
- static const int CXType_OCLImage2dArrayRO = 125;
- static const int CXType_OCLImage2dDepthRO = 126;
- static const int CXType_OCLImage2dArrayDepthRO = 127;
- static const int CXType_OCLImage2dMSAARO = 128;
- static const int CXType_OCLImage2dArrayMSAARO = 129;
- static const int CXType_OCLImage2dMSAADepthRO = 130;
- static const int CXType_OCLImage2dArrayMSAADepthRO = 131;
- static const int CXType_OCLImage3dRO = 132;
- static const int CXType_OCLImage1dWO = 133;
- static const int CXType_OCLImage1dArrayWO = 134;
- static const int CXType_OCLImage1dBufferWO = 135;
- static const int CXType_OCLImage2dWO = 136;
- static const int CXType_OCLImage2dArrayWO = 137;
- static const int CXType_OCLImage2dDepthWO = 138;
- static const int CXType_OCLImage2dArrayDepthWO = 139;
- static const int CXType_OCLImage2dMSAAWO = 140;
- static const int CXType_OCLImage2dArrayMSAAWO = 141;
- static const int CXType_OCLImage2dMSAADepthWO = 142;
- static const int CXType_OCLImage2dArrayMSAADepthWO = 143;
- static const int CXType_OCLImage3dWO = 144;
- static const int CXType_OCLImage1dRW = 145;
- static const int CXType_OCLImage1dArrayRW = 146;
- static const int CXType_OCLImage1dBufferRW = 147;
- static const int CXType_OCLImage2dRW = 148;
- static const int CXType_OCLImage2dArrayRW = 149;
- static const int CXType_OCLImage2dDepthRW = 150;
- static const int CXType_OCLImage2dArrayDepthRW = 151;
- static const int CXType_OCLImage2dMSAARW = 152;
- static const int CXType_OCLImage2dArrayMSAARW = 153;
- static const int CXType_OCLImage2dMSAADepthRW = 154;
- static const int CXType_OCLImage2dArrayMSAADepthRW = 155;
- static const int CXType_OCLImage3dRW = 156;
- static const int CXType_OCLSampler = 157;
- static const int CXType_OCLEvent = 158;
- static const int CXType_OCLQueue = 159;
- static const int CXType_OCLReserveID = 160;
- static const int CXType_ObjCObject = 161;
- static const int CXType_ObjCTypeParam = 162;
- static const int CXType_Attributed = 163;
- static const int CXType_OCLIntelSubgroupAVCMcePayload = 164;
- static const int CXType_OCLIntelSubgroupAVCImePayload = 165;
- static const int CXType_OCLIntelSubgroupAVCRefPayload = 166;
- static const int CXType_OCLIntelSubgroupAVCSicPayload = 167;
- static const int CXType_OCLIntelSubgroupAVCMceResult = 168;
- static const int CXType_OCLIntelSubgroupAVCImeResult = 169;
- static const int CXType_OCLIntelSubgroupAVCRefResult = 170;
- static const int CXType_OCLIntelSubgroupAVCSicResult = 171;
- static const int CXType_OCLIntelSubgroupAVCImeResultSingleRefStreamout = 172;
- static const int CXType_OCLIntelSubgroupAVCImeResultDualRefStreamout = 173;
- static const int CXType_OCLIntelSubgroupAVCImeSingleRefStreamin = 174;
- static const int CXType_OCLIntelSubgroupAVCImeDualRefStreamin = 175;
- static const int CXType_ExtVector = 176;
+ static const CXType_Elaborated = 119;
+ static const CXType_Pipe = 120;
+ static const CXType_OCLImage1dRO = 121;
+ static const CXType_OCLImage1dArrayRO = 122;
+ static const CXType_OCLImage1dBufferRO = 123;
+ static const CXType_OCLImage2dRO = 124;
+ static const CXType_OCLImage2dArrayRO = 125;
+ static const CXType_OCLImage2dDepthRO = 126;
+ static const CXType_OCLImage2dArrayDepthRO = 127;
+ static const CXType_OCLImage2dMSAARO = 128;
+ static const CXType_OCLImage2dArrayMSAARO = 129;
+ static const CXType_OCLImage2dMSAADepthRO = 130;
+ static const CXType_OCLImage2dArrayMSAADepthRO = 131;
+ static const CXType_OCLImage3dRO = 132;
+ static const CXType_OCLImage1dWO = 133;
+ static const CXType_OCLImage1dArrayWO = 134;
+ static const CXType_OCLImage1dBufferWO = 135;
+ static const CXType_OCLImage2dWO = 136;
+ static const CXType_OCLImage2dArrayWO = 137;
+ static const CXType_OCLImage2dDepthWO = 138;
+ static const CXType_OCLImage2dArrayDepthWO = 139;
+ static const CXType_OCLImage2dMSAAWO = 140;
+ static const CXType_OCLImage2dArrayMSAAWO = 141;
+ static const CXType_OCLImage2dMSAADepthWO = 142;
+ static const CXType_OCLImage2dArrayMSAADepthWO = 143;
+ static const CXType_OCLImage3dWO = 144;
+ static const CXType_OCLImage1dRW = 145;
+ static const CXType_OCLImage1dArrayRW = 146;
+ static const CXType_OCLImage1dBufferRW = 147;
+ static const CXType_OCLImage2dRW = 148;
+ static const CXType_OCLImage2dArrayRW = 149;
+ static const CXType_OCLImage2dDepthRW = 150;
+ static const CXType_OCLImage2dArrayDepthRW = 151;
+ static const CXType_OCLImage2dMSAARW = 152;
+ static const CXType_OCLImage2dArrayMSAARW = 153;
+ static const CXType_OCLImage2dMSAADepthRW = 154;
+ static const CXType_OCLImage2dArrayMSAADepthRW = 155;
+ static const CXType_OCLImage3dRW = 156;
+ static const CXType_OCLSampler = 157;
+ static const CXType_OCLEvent = 158;
+ static const CXType_OCLQueue = 159;
+ static const CXType_OCLReserveID = 160;
+ static const CXType_ObjCObject = 161;
+ static const CXType_ObjCTypeParam = 162;
+ static const CXType_Attributed = 163;
+ static const CXType_OCLIntelSubgroupAVCMcePayload = 164;
+ static const CXType_OCLIntelSubgroupAVCImePayload = 165;
+ static const CXType_OCLIntelSubgroupAVCRefPayload = 166;
+ static const CXType_OCLIntelSubgroupAVCSicPayload = 167;
+ static const CXType_OCLIntelSubgroupAVCMceResult = 168;
+ static const CXType_OCLIntelSubgroupAVCImeResult = 169;
+ static const CXType_OCLIntelSubgroupAVCRefResult = 170;
+ static const CXType_OCLIntelSubgroupAVCSicResult = 171;
+ static const CXType_OCLIntelSubgroupAVCImeResultSingleRefStreamout = 172;
+ static const CXType_OCLIntelSubgroupAVCImeResultDualRefStreamout = 173;
+ static const CXType_OCLIntelSubgroupAVCImeSingleRefStreamin = 174;
+ static const CXType_OCLIntelSubgroupAVCImeDualRefStreamin = 175;
+ static const CXType_ExtVector = 176;
}
/// The type of an element in the abstract syntax tree.
@@ -2648,19 +2827,19 @@ final class CXType extends ffi.Struct {
abstract class CXTypeNullabilityKind {
/// Values of this type can never be null.
- static const int CXTypeNullability_NonNull = 0;
+ static const CXTypeNullability_NonNull = 0;
/// Values of this type can be null.
- static const int CXTypeNullability_Nullable = 1;
+ static const CXTypeNullability_Nullable = 1;
/// Whether values of this type can be null is (explicitly)
/// unspecified. This captures a (fairly rare) case where we
/// can't conclude anything about the nullability of the type even
/// though it has been considered.
- static const int CXTypeNullability_Unspecified = 2;
+ static const CXTypeNullability_Unspecified = 2;
/// Nullability is not applicable to this type.
- static const int CXTypeNullability_Invalid = 3;
+ static const CXTypeNullability_Invalid = 3;
}
/// List the possible error codes for \c clang_Type_getSizeOf,
@@ -2671,35 +2850,35 @@ abstract class CXTypeNullabilityKind {
/// a valid argument to sizeof, alignof or offsetof.
abstract class CXTypeLayoutError {
/// Type is of kind CXType_Invalid.
- static const int CXTypeLayoutError_Invalid = -1;
+ static const CXTypeLayoutError_Invalid = -1;
/// The type is an incomplete Type.
- static const int CXTypeLayoutError_Incomplete = -2;
+ static const CXTypeLayoutError_Incomplete = -2;
/// The type is a dependent Type.
- static const int CXTypeLayoutError_Dependent = -3;
+ static const CXTypeLayoutError_Dependent = -3;
/// The type is not a constant size type.
- static const int CXTypeLayoutError_NotConstantSize = -4;
+ static const CXTypeLayoutError_NotConstantSize = -4;
/// The Field name is not valid for this record.
- static const int CXTypeLayoutError_InvalidFieldName = -5;
+ static const CXTypeLayoutError_InvalidFieldName = -5;
/// The type is undeduced.
- static const int CXTypeLayoutError_Undeduced = -6;
+ static const CXTypeLayoutError_Undeduced = -6;
}
/// Represents the storage classes as declared in the source. CX_SC_Invalid
/// was added for the case that the passed cursor in not a declaration.
abstract class CX_StorageClass {
- static const int CX_SC_Invalid = 0;
- static const int CX_SC_None = 1;
- static const int CX_SC_Extern = 2;
- static const int CX_SC_Static = 3;
- static const int CX_SC_PrivateExtern = 4;
- static const int CX_SC_OpenCLWorkGroupLocal = 5;
- static const int CX_SC_Auto = 6;
- static const int CX_SC_Register = 7;
+ static const CX_SC_Invalid = 0;
+ static const CX_SC_None = 1;
+ static const CX_SC_Extern = 2;
+ static const CX_SC_Static = 3;
+ static const CX_SC_PrivateExtern = 4;
+ static const CX_SC_OpenCLWorkGroupLocal = 5;
+ static const CX_SC_Auto = 6;
+ static const CX_SC_Register = 7;
}
/// Describes how the traversal of the children of a particular
@@ -2709,15 +2888,15 @@ abstract class CX_StorageClass {
/// \c CXCursorVisitor to indicate how clang_visitChildren() proceed.
abstract class CXChildVisitResult {
/// Terminates the cursor traversal.
- static const int CXChildVisit_Break = 0;
+ static const CXChildVisit_Break = 0;
/// Continues the cursor traversal with the next sibling of
/// the cursor just visited, without visiting its children.
- static const int CXChildVisit_Continue = 1;
+ static const CXChildVisit_Continue = 1;
/// Recursively traverse the children of this cursor, using
/// the same visitor and client data.
- static const int CXChildVisit_Recurse = 2;
+ static const CXChildVisit_Recurse = 2;
}
/// Visitor invoked for each cursor found by a traversal.
@@ -2734,7 +2913,7 @@ typedef CXCursorVisitor
= ffi.Pointer>;
typedef CXCursorVisitorFunction = ffi.UnsignedInt Function(
CXCursor cursor, CXCursor parent, CXClientData client_data);
-typedef DartCXCursorVisitorFunction = int Function(
+typedef DartCXCursorVisitorFunction = CXChildVisitResult Function(
CXCursor cursor, CXCursor parent, CXClientData client_data);
/// Opaque pointer representing client data that will be passed through
@@ -2743,30 +2922,30 @@ typedef CXClientData = ffi.Pointer;
/// Property attributes for a \c CXCursor_ObjCPropertyDecl.
abstract class CXObjCPropertyAttrKind {
- static const int CXObjCPropertyAttr_noattr = 0;
- static const int CXObjCPropertyAttr_readonly = 1;
- static const int CXObjCPropertyAttr_getter = 2;
- static const int CXObjCPropertyAttr_assign = 4;
- static const int CXObjCPropertyAttr_readwrite = 8;
- static const int CXObjCPropertyAttr_retain = 16;
- static const int CXObjCPropertyAttr_copy = 32;
- static const int CXObjCPropertyAttr_nonatomic = 64;
- static const int CXObjCPropertyAttr_setter = 128;
- static const int CXObjCPropertyAttr_atomic = 256;
- static const int CXObjCPropertyAttr_weak = 512;
- static const int CXObjCPropertyAttr_strong = 1024;
- static const int CXObjCPropertyAttr_unsafe_unretained = 2048;
- static const int CXObjCPropertyAttr_class = 4096;
+ static const CXObjCPropertyAttr_noattr = 0;
+ static const CXObjCPropertyAttr_readonly = 1;
+ static const CXObjCPropertyAttr_getter = 2;
+ static const CXObjCPropertyAttr_assign = 4;
+ static const CXObjCPropertyAttr_readwrite = 8;
+ static const CXObjCPropertyAttr_retain = 16;
+ static const CXObjCPropertyAttr_copy = 32;
+ static const CXObjCPropertyAttr_nonatomic = 64;
+ static const CXObjCPropertyAttr_setter = 128;
+ static const CXObjCPropertyAttr_atomic = 256;
+ static const CXObjCPropertyAttr_weak = 512;
+ static const CXObjCPropertyAttr_strong = 1024;
+ static const CXObjCPropertyAttr_unsafe_unretained = 2048;
+ static const CXObjCPropertyAttr_class = 4096;
}
abstract class CXEvalResultKind {
- static const int CXEval_Int = 1;
- static const int CXEval_Float = 2;
- static const int CXEval_ObjCStrLiteral = 3;
- static const int CXEval_StrLiteral = 4;
- static const int CXEval_CFStr = 5;
- static const int CXEval_Other = 6;
- static const int CXEval_UnExposed = 0;
+ static const CXEval_Int = 1;
+ static const CXEval_Float = 2;
+ static const CXEval_ObjCStrLiteral = 3;
+ static const CXEval_StrLiteral = 4;
+ static const CXEval_CFStr = 5;
+ static const CXEval_Other = 6;
+ static const CXEval_UnExposed = 0;
}
/// Evaluation result of a cursor
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/api_availability.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/api_availability.dart
new file mode 100644
index 0000000000..69746b64bf
--- /dev/null
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/api_availability.dart
@@ -0,0 +1,155 @@
+// Copyright (c) 2024, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+import 'dart:ffi';
+
+import 'package:ffi/ffi.dart';
+import 'package:pub_semver/pub_semver.dart';
+
+import '../../config_provider/config_types.dart';
+import '../clang_bindings/clang_bindings.dart' as clang_types;
+import '../data.dart';
+import '../utils.dart';
+
+bool isApiAvailable(clang_types.CXCursor cursor) {
+ final api = ApiAvailability.fromCursor(cursor);
+ return api.isAvailable(config.externalVersions);
+}
+
+class ApiAvailability {
+ final bool alwaysDeprecated;
+ final bool alwaysUnavailable;
+ PlatformAvailability? ios;
+ PlatformAvailability? macos;
+
+ ApiAvailability({
+ this.alwaysDeprecated = false,
+ this.alwaysUnavailable = false,
+ this.ios,
+ this.macos,
+ });
+
+ static ApiAvailability fromCursor(clang_types.CXCursor cursor) {
+ final platformsLength = clang.clang_getCursorPlatformAvailability(
+ cursor, nullptr, nullptr, nullptr, nullptr, nullptr, 0);
+
+ final alwaysDeprecated = calloc();
+ final alwaysUnavailable = calloc();
+ final platforms =
+ calloc(platformsLength);
+
+ clang.clang_getCursorPlatformAvailability(cursor, alwaysDeprecated, nullptr,
+ alwaysUnavailable, nullptr, platforms, platformsLength);
+
+ PlatformAvailability? ios;
+ PlatformAvailability? macos;
+
+ for (var i = 0; i < platformsLength; ++i) {
+ final platform = platforms[i];
+ final platformAvailability = PlatformAvailability(
+ introduced: platform.Introduced.triple,
+ deprecated: platform.Deprecated.triple,
+ obsoleted: platform.Obsoleted.triple,
+ unavailable: platform.Unavailable != 0,
+ );
+ switch (platform.Platform.string()) {
+ case 'ios':
+ ios = platformAvailability;
+ break;
+ case 'macos':
+ macos = platformAvailability;
+ break;
+ }
+ }
+
+ final api = ApiAvailability(
+ alwaysDeprecated: alwaysDeprecated.value != 0,
+ alwaysUnavailable: alwaysUnavailable.value != 0,
+ ios: ios,
+ macos: macos,
+ );
+
+ for (var i = 0; i < platformsLength; ++i) {
+ clang.clang_disposeCXPlatformAvailability(platforms + i);
+ }
+ calloc.free(alwaysDeprecated);
+ calloc.free(alwaysUnavailable);
+ calloc.free(platforms);
+
+ return api;
+ }
+
+ bool isAvailable(ExternalVersions extVers) {
+ final macosVer = extVers.macos?.min;
+ final iosVer = extVers.ios?.min;
+
+ // If no versions are specified, everything is available.
+ if (iosVer == null && macosVer == null) {
+ return true;
+ }
+
+ if (alwaysDeprecated || alwaysUnavailable) {
+ return false;
+ }
+
+ for (final (plat, minVer) in [(ios, iosVer), (macos, macosVer)]) {
+ // If the user hasn't specified a minimum version for this platform, defer
+ // to the other platforms.
+ if (minVer == null) {
+ continue;
+ }
+ // If the API is available on any platform, return that it's available.
+ if (_platformAvailable(plat, minVer)) {
+ return true;
+ }
+ }
+ // The API is not available on any of the platforms the user cares about.
+ return false;
+ }
+
+ bool _platformAvailable(PlatformAvailability? plat, Version minVer) {
+ if (plat == null) {
+ // Clang's availability info has nothing to say about the given platform,
+ // so assume the API is available.
+ return true;
+ }
+ if (plat.unavailable) {
+ return false;
+ }
+ if (_unavailableByVersion(minVer, plat.deprecated) ||
+ _unavailableByVersion(minVer, plat.obsoleted)) {
+ return false;
+ }
+ return true;
+ }
+
+ bool _unavailableByVersion(Version minVer, Version? deprecated) =>
+ deprecated != null && minVer >= deprecated;
+
+ @override
+ String toString() => '''Availability {
+ alwaysDeprecated: $alwaysDeprecated
+ alwaysUnavailable: $alwaysUnavailable
+ ios: $ios
+ macos: $macos
+}''';
+}
+
+class PlatformAvailability {
+ Version? introduced;
+ Version? deprecated;
+ Version? obsoleted;
+ bool unavailable;
+
+ PlatformAvailability({
+ this.introduced,
+ this.deprecated,
+ this.obsoleted,
+ this.unavailable = false,
+ });
+
+ @override
+ String toString() => 'introduced: $introduced, deprecated: $deprecated, '
+ 'obsoleted: $obsoleted, unavailable: $unavailable';
+}
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/compounddecl_parser.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/compounddecl_parser.dart
index 1aaf4365dd..0635a50c12 100644
--- a/pkgs/ffigen/lib/src/header_parser/sub_parsers/compounddecl_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/compounddecl_parser.dart
@@ -12,6 +12,7 @@ import '../clang_bindings/clang_bindings.dart' as clang_types;
import '../data.dart';
import '../includer.dart';
import '../utils.dart';
+import 'api_availability.dart';
final _logger = Logger('ffigen.header_parser.compounddecl_parser');
@@ -114,6 +115,11 @@ Compound? parseCompoundDeclaration(
declName = '';
}
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated $className $declName');
+ return null;
+ }
+
final decl = Declaration(usr: declUsr, originalName: declName);
if (declName.isEmpty) {
if (ignoreFilter) {
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/enumdecl_parser.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/enumdecl_parser.dart
index d60ebe861c..2d979271f6 100644
--- a/pkgs/ffigen/lib/src/header_parser/sub_parsers/enumdecl_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/enumdecl_parser.dart
@@ -11,6 +11,7 @@ import '../data.dart';
import '../includer.dart';
import '../type_extractor/cxtypekindmap.dart';
import '../utils.dart';
+import 'api_availability.dart';
import 'unnamed_enumdecl_parser.dart';
final _logger = Logger('ffigen.header_parser.enumdecl_parser');
@@ -43,6 +44,11 @@ final _logger = Logger('ffigen.header_parser.enumdecl_parser');
nativeType = signedToUnsignedNativeIntType[nativeType] ?? nativeType;
var hasNegativeEnumConstants = false;
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated enum $enumName');
+ return (null, nativeType);
+ }
+
final decl = Declaration(usr: enumUsr, originalName: enumName);
if (enumName.isEmpty) {
_logger.fine('Saving anonymous enum.');
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/functiondecl_parser.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/functiondecl_parser.dart
index d39ba40d5f..4f819f138c 100644
--- a/pkgs/ffigen/lib/src/header_parser/sub_parsers/functiondecl_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/functiondecl_parser.dart
@@ -10,17 +10,24 @@ import '../clang_bindings/clang_bindings.dart' as clang_types;
import '../data.dart';
import '../includer.dart';
import '../utils.dart';
+import 'api_availability.dart';
final _logger = Logger('ffigen.header_parser.functiondecl_parser');
/// Parses a function declaration.
-List? parseFunctionDeclaration(clang_types.CXCursor cursor) {
+List parseFunctionDeclaration(clang_types.CXCursor cursor) {
/// Multiple values are since there may be more than one instance of the
/// same base C function with different variadic arguments.
final funcs = [];
final funcUsr = cursor.usr();
final funcName = cursor.spelling();
+
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated function $funcName');
+ return funcs;
+ }
+
final decl = Declaration(usr: funcUsr, originalName: funcName);
if (shouldIncludeFunc(decl)) {
_logger.fine('++++ Adding Function: ${cursor.completeStringRepr()}');
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcinterfacedecl_parser.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcinterfacedecl_parser.dart
index 5f16525102..3f3a392a0e 100644
--- a/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcinterfacedecl_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcinterfacedecl_parser.dart
@@ -10,6 +10,7 @@ import '../clang_bindings/clang_bindings.dart' as clang_types;
import '../data.dart';
import '../includer.dart';
import '../utils.dart';
+import 'api_availability.dart';
final _logger = Logger('ffigen.header_parser.objcinterfacedecl_parser');
@@ -29,6 +30,11 @@ Type? parseObjCInterfaceDeclaration(
return null;
}
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated interface $itfName');
+ return null;
+ }
+
_logger.fine('++++ Adding ObjC interface: '
'Name: $itfName, ${cursor.completeStringRepr()}');
@@ -108,6 +114,11 @@ void _parseProperty(clang_types.CXCursor cursor, ObjCInterface itf) {
final fieldName = cursor.spelling();
final fieldType = cursor.type().toCodeGenType();
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated property ${itf.originalName}.$fieldName');
+ return;
+ }
+
if (fieldType.isIncompleteCompound) {
_logger.warning('Property "$fieldName" in instance "${itf.originalName}" '
'has incomplete type: $fieldType.');
@@ -180,6 +191,12 @@ ObjCMethod? parseObjCMethod(clang_types.CXCursor cursor, String itfName) {
'return type: $returnType.');
return null;
}
+
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated method $itfName.$methodName');
+ return null;
+ }
+
final method = ObjCMethod(
originalName: methodName,
dartDoc: getCursorDocComment(cursor),
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcprotocoldecl_parser.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcprotocoldecl_parser.dart
index 4ab32a3b32..7b9dccb74e 100644
--- a/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcprotocoldecl_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/objcprotocoldecl_parser.dart
@@ -10,6 +10,7 @@ import '../clang_bindings/clang_bindings.dart' as clang_types;
import '../data.dart';
import '../includer.dart';
import '../utils.dart';
+import 'api_availability.dart';
import 'objcinterfacedecl_parser.dart';
final _logger = Logger('ffigen.header_parser.objcprotocoldecl_parser');
@@ -33,6 +34,11 @@ ObjCProtocol? parseObjCProtocolDeclaration(clang_types.CXCursor cursor,
return null;
}
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated protocol $name');
+ return null;
+ }
+
_logger.fine('++++ Adding ObjC protocol: '
'Name: $name, ${cursor.completeStringRepr()}');
diff --git a/pkgs/ffigen/lib/src/header_parser/sub_parsers/unnamed_enumdecl_parser.dart b/pkgs/ffigen/lib/src/header_parser/sub_parsers/unnamed_enumdecl_parser.dart
index 971bb37fd6..e2ac4cb898 100644
--- a/pkgs/ffigen/lib/src/header_parser/sub_parsers/unnamed_enumdecl_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/sub_parsers/unnamed_enumdecl_parser.dart
@@ -10,6 +10,7 @@ import '../clang_bindings/clang_bindings.dart' as clang_types;
import '../data.dart';
import '../includer.dart';
import '../utils.dart';
+import 'api_availability.dart';
final _logger = Logger('ffigen.header_parser.unnamed_enumdecl_parser');
@@ -24,7 +25,10 @@ List saveUnNamedEnum(clang_types.CXCursor cursor) {
case clang_types.CXCursorKind.CXCursor_EnumConstantDecl:
if (shouldIncludeUnnamedEnumConstant(
Declaration(usr: child.usr(), originalName: child.spelling()))) {
- addedConstants.add(_addUnNamedEnumConstant(child));
+ final value = _addUnNamedEnumConstant(child);
+ if (value != null) {
+ addedConstants.add(value);
+ }
}
break;
case clang_types.CXCursorKind.CXCursor_UnexposedAttr:
@@ -43,7 +47,12 @@ List saveUnNamedEnum(clang_types.CXCursor cursor) {
}
/// Adds the parameter to func in functiondecl_parser.dart.
-Constant _addUnNamedEnumConstant(clang_types.CXCursor cursor) {
+Constant? _addUnNamedEnumConstant(clang_types.CXCursor cursor) {
+ if (!isApiAvailable(cursor)) {
+ _logger.info('Omitting deprecated unnamed enum value ${cursor.spelling()}');
+ return null;
+ }
+
_logger.fine(
'++++ Adding Constant from unnamed enum: ${cursor.completeStringRepr()}');
final constant = Constant(
diff --git a/pkgs/ffigen/lib/src/header_parser/translation_unit_parser.dart b/pkgs/ffigen/lib/src/header_parser/translation_unit_parser.dart
index bf89dd76b5..3e7645534d 100644
--- a/pkgs/ffigen/lib/src/header_parser/translation_unit_parser.dart
+++ b/pkgs/ffigen/lib/src/header_parser/translation_unit_parser.dart
@@ -29,7 +29,7 @@ Set parseTranslationUnit(clang_types.CXCursor translationUnitCursor) {
_logger.finest('rootCursorVisitor: ${cursor.completeStringRepr()}');
switch (clang.clang_getCursorKind(cursor)) {
case clang_types.CXCursorKind.CXCursor_FunctionDecl:
- bindings.addAll(parseFunctionDeclaration(cursor) as List);
+ bindings.addAll(parseFunctionDeclaration(cursor));
break;
case clang_types.CXCursorKind.CXCursor_StructDecl:
case clang_types.CXCursorKind.CXCursor_UnionDecl:
diff --git a/pkgs/ffigen/lib/src/header_parser/utils.dart b/pkgs/ffigen/lib/src/header_parser/utils.dart
index 739da02a7e..52fff376e8 100644
--- a/pkgs/ffigen/lib/src/header_parser/utils.dart
+++ b/pkgs/ffigen/lib/src/header_parser/utils.dart
@@ -6,6 +6,7 @@ import 'dart:ffi';
import 'package:ffi/ffi.dart';
import 'package:logging/logging.dart';
+import 'package:pub_semver/pub_semver.dart';
import '../code_generator.dart';
import '../config_provider/config_types.dart';
@@ -382,6 +383,20 @@ extension CXStringExt on clang_types.CXString {
}
}
+extension CXVersionExt on clang_types.CXVersion {
+ Version? get triple {
+ // -1 can appear in a CXVersion, and has various meanings.
+ // Whenever one of the fields is -1, the subsequent fields are also -1 (eg
+ // you can't have Minor=-1 and Subminor=4). If all 3 fields are -1, it means
+ // "no version", and we return null. Otherwise, we treat a -1 in any field
+ // as a 0.
+ if (Major < 0) return null;
+ return Version(Major, Minor < 0 ? 0 : Minor, Subminor < 0 ? 0 : Subminor);
+ }
+
+ String string() => '$Major.$Minor.$Subminor';
+}
+
/// Converts a [List] to [Pointer>].
Pointer> createDynamicStringArray(List list) {
final nativeCmdArgs = calloc>(list.length);
diff --git a/pkgs/ffigen/lib/src/strings.dart b/pkgs/ffigen/lib/src/strings.dart
index f07af5f9c3..94fbc1dd25 100644
--- a/pkgs/ffigen/lib/src/strings.dart
+++ b/pkgs/ffigen/lib/src/strings.dart
@@ -56,10 +56,15 @@ const includeDirectives = 'include-directives';
const compilerOpts = 'compiler-opts';
-const compilerOptsAuto = 'compiler-opts-automatic';
-// Sub-fields of compilerOptsAuto.
const macos = 'macos';
-// Sub-fields of macos.
+const ios = 'ios';
+
+const externalVersions = 'external-versions';
+const externalVersionsPlatforms = [ios, macos];
+const externalVersionsMin = 'min';
+
+const compilerOptsAuto = 'compiler-opts-automatic';
+// Sub-fields of compilerOptsAuto.macos
const includeCStdLib = 'include-c-standard-library';
// Declarations.
diff --git a/pkgs/ffigen/pubspec.yaml b/pkgs/ffigen/pubspec.yaml
index ca3fc882a4..5e92e789a1 100644
--- a/pkgs/ffigen/pubspec.yaml
+++ b/pkgs/ffigen/pubspec.yaml
@@ -26,6 +26,7 @@ dependencies:
logging: ^1.0.0
package_config: ^2.1.0
path: ^1.8.0
+ pub_semver: ^2.1.4
quiver: ^3.0.0
yaml: ^3.0.0
yaml_edit: ^2.0.3
diff --git a/pkgs/ffigen/test/native_objc_test/deprecated_test.dart b/pkgs/ffigen/test/native_objc_test/deprecated_test.dart
new file mode 100644
index 0000000000..d3f6e07705
--- /dev/null
+++ b/pkgs/ffigen/test/native_objc_test/deprecated_test.dart
@@ -0,0 +1,421 @@
+// Copyright (c) 2022, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+// Objective C support is only available on mac.
+@TestOn('mac-os')
+
+import 'dart:ffi';
+import 'dart:io';
+
+import 'package:ffi/ffi.dart';
+import 'package:ffigen/ffigen.dart';
+import 'package:ffigen/src/config_provider/config.dart';
+import 'package:ffigen/src/config_provider/config_types.dart';
+import 'package:logging/logging.dart';
+import 'package:pub_semver/pub_semver.dart';
+import 'package:test/test.dart';
+import '../test_utils.dart';
+import 'util.dart';
+
+String bindingsForVersion({Version? iosMinVer, Version? macosMinVer}) {
+ final config = Config(
+ wrapperName: 'DeprecatedTestObjCLibrary',
+ wrapperDocComment: 'Tests API deprecation',
+ language: Language.objc,
+ output: Uri.file('test/native_objc_test/deprecated_bindings.dart'),
+ entryPoints: [Uri.file('test/native_objc_test/deprecated_test.m')],
+ formatOutput: false,
+ objcInterfaces: DeclarationFilters.include(
+ {'DeprecatedInterfaceMethods', 'DeprecatedInterface'}),
+ objcProtocols: DeclarationFilters.include(
+ {'DeprecatedProtocolMethods', 'DeprecatedProtocol'}),
+ functionDecl:
+ DeclarationFilters.include({'normalFunction', 'deprecatedFunction'}),
+ structDecl:
+ DeclarationFilters.include({'NormalStruct', 'DeprecatedStruct'}),
+ unionDecl: DeclarationFilters.include({'NormalUnion', 'DeprecatedUnion'}),
+ enumClassDecl: DeclarationFilters.include({'NormalEnum', 'DeprecatedEnum'}),
+ unnamedEnumConstants: DeclarationFilters.include(
+ {'normalUnnamedEnum', 'deprecatedUnnamedEnum'}),
+ externalVersions: ExternalVersions(
+ ios: Versions(min: iosMinVer),
+ macos: Versions(min: macosMinVer),
+ ),
+ );
+ FfiGen(logLevel: Level.SEVERE).run(config);
+ return File('test/native_objc_test/deprecated_bindings.dart')
+ .readAsStringSync();
+}
+
+void main() {
+ group('deprecated', () {
+ group('no version info', () {
+ late final String bindings;
+ setUpAll(() {
+ bindings = bindingsForVersion();
+ });
+
+ test('interfaces', () {
+ expect(bindings, contains('DeprecatedInterface '));
+ expect(bindings, contains('DeprecatedInterfaceMethods '));
+ });
+
+ test('protocols', () {
+ expect(bindings, contains('DeprecatedProtocol '));
+ expect(bindings, contains('DeprecatedProtocolMethods '));
+ });
+
+ test('interface methods', () {
+ expect(bindings, contains('normalMethod'));
+ expect(bindings, contains('unavailableMac'));
+ expect(bindings, contains('unavailableIos'));
+ expect(bindings, contains('unavailableBoth'));
+ expect(bindings, contains('depMac2'));
+ expect(bindings, contains('depMac3'));
+ expect(bindings, contains('depIos2'));
+ expect(bindings, contains('depIos2Mac2'));
+ expect(bindings, contains('depIos2Mac3'));
+ expect(bindings, contains('depIos3'));
+ expect(bindings, contains('depIos3Mac2'));
+ expect(bindings, contains('depIos3Mac3'));
+ expect(bindings, contains('alwaysDeprecated'));
+ expect(bindings, contains('alwaysUnavailable'));
+ });
+
+ test('interface properties', () {
+ expect(bindings, contains('get normalProperty'));
+ expect(bindings, contains('set normalProperty'));
+ expect(bindings, contains('get deprecatedProperty'));
+ expect(bindings, contains('set deprecatedProperty'));
+ });
+
+ test('protocol methods', () {
+ expect(bindings, contains('protNormalMethod'));
+ expect(bindings, contains('protUnavailableMac'));
+ expect(bindings, contains('protUnavailableIos'));
+ expect(bindings, contains('protUnavailableBoth'));
+ expect(bindings, contains('protDepMac2'));
+ expect(bindings, contains('protDepMac3'));
+ expect(bindings, contains('protDepIos2'));
+ expect(bindings, contains('protDepIos2Mac2'));
+ expect(bindings, contains('protDepIos2Mac3'));
+ expect(bindings, contains('protDepIos3'));
+ expect(bindings, contains('protDepIos3Mac2'));
+ expect(bindings, contains('protDepIos3Mac3'));
+ expect(bindings, contains('protAlwaysDeprecated'));
+ expect(bindings, contains('protAlwaysUnavailable'));
+ });
+
+ test('protocol properties', () {
+ expect(bindings, contains('protNormalProperty'));
+ expect(bindings, contains('setProtNormalProperty'));
+ expect(bindings, contains('protDeprecatedProperty'));
+ expect(bindings, contains('setProtDeprecatedProperty'));
+ });
+
+ test('functions', () {
+ expect(bindings, contains('normalFunction'));
+ expect(bindings, contains('deprecatedFunction'));
+ });
+
+ test('structs', () {
+ expect(bindings, contains('NormalStruct'));
+ expect(bindings, contains('DeprecatedStruct'));
+ });
+
+ test('unions', () {
+ expect(bindings, contains('NormalUnion'));
+ expect(bindings, contains('DeprecatedUnion'));
+ });
+
+ test('enums', () {
+ expect(bindings, contains('NormalEnum'));
+ expect(bindings, contains('DeprecatedEnum'));
+ });
+
+ test('unnamed enums', () {
+ expect(bindings, contains('normalUnnamedEnum'));
+ expect(bindings, contains('deprecatedUnnamedEnum'));
+ });
+ });
+
+ group('ios 2.5, no macos version', () {
+ late final String bindings;
+ setUpAll(() {
+ bindings = bindingsForVersion(
+ iosMinVer: Version(2, 5, 0),
+ );
+ });
+
+ test('interfaces', () {
+ expect(bindings, isNot(contains('DeprecatedInterface ')));
+ expect(bindings, contains('DeprecatedInterfaceMethods '));
+ });
+
+ test('protocols', () {
+ expect(bindings, isNot(contains('DeprecatedProtocol ')));
+ expect(bindings, contains('DeprecatedProtocolMethods '));
+ });
+
+ test('interface methods', () {
+ expect(bindings, contains('normalMethod'));
+ expect(bindings, contains('unavailableMac'));
+ expect(bindings, isNot(contains('unavailableIos')));
+ expect(bindings, isNot(contains('unavailableBoth')));
+ expect(bindings, contains('depMac2'));
+ expect(bindings, contains('depMac3'));
+ expect(bindings, isNot(contains('depIos2')));
+ expect(bindings, isNot(contains('depIos2Mac2')));
+ expect(bindings, isNot(contains('depIos2Mac3')));
+ expect(bindings, contains('depIos3'));
+ expect(bindings, contains('depIos3Mac2'));
+ expect(bindings, contains('depIos3Mac3'));
+ expect(bindings, isNot(contains('alwaysDeprecated')));
+ expect(bindings, isNot(contains('alwaysUnavailable')));
+ });
+
+ test('interface properties', () {
+ expect(bindings, contains('get normalProperty'));
+ expect(bindings, contains('set normalProperty'));
+ expect(bindings, isNot(contains('get deprecatedProperty')));
+ expect(bindings, isNot(contains('set deprecatedProperty')));
+ });
+
+ test('protocol methods', () {
+ expect(bindings, contains('protNormalMethod'));
+ expect(bindings, contains('protUnavailableMac'));
+ expect(bindings, isNot(contains('protUnavailableIos')));
+ expect(bindings, isNot(contains('protUnavailableBoth')));
+ expect(bindings, contains('protDepMac2'));
+ expect(bindings, contains('protDepMac3'));
+ expect(bindings, isNot(contains('protDepIos2')));
+ expect(bindings, isNot(contains('protDepIos2Mac2')));
+ expect(bindings, isNot(contains('protDepIos2Mac3')));
+ expect(bindings, contains('protDepIos3'));
+ expect(bindings, contains('protDepIos3Mac2'));
+ expect(bindings, contains('protDepIos3Mac3'));
+ expect(bindings, isNot(contains('protAlwaysDeprecated')));
+ expect(bindings, isNot(contains('protAlwaysUnavailable')));
+ });
+
+ test('protocol properties', () {
+ expect(bindings, contains('protNormalProperty'));
+ expect(bindings, contains('setProtNormalProperty'));
+ expect(bindings, isNot(contains('protDeprecatedProperty')));
+ expect(bindings, isNot(contains('setProtDeprecatedProperty')));
+ });
+
+ test('functions', () {
+ expect(bindings, contains('normalFunction'));
+ expect(bindings, isNot(contains('deprecatedFunction')));
+ });
+
+ test('structs', () {
+ expect(bindings, contains('NormalStruct'));
+ expect(bindings, isNot(contains('DeprecatedStruct')));
+ });
+
+ test('unions', () {
+ expect(bindings, contains('NormalUnion'));
+ expect(bindings, isNot(contains('DeprecatedUnion')));
+ });
+
+ test('enums', () {
+ expect(bindings, contains('NormalEnum'));
+ expect(bindings, isNot(contains('DeprecatedEnum')));
+ });
+
+ test('unnamed enums', () {
+ expect(bindings, contains('normalUnnamedEnum'));
+ expect(bindings, isNot(contains('deprecatedUnnamedEnum')));
+ });
+ });
+
+ group('ios 2.5, macos 2.5', () {
+ late final String bindings;
+ setUpAll(() {
+ bindings = bindingsForVersion(
+ iosMinVer: Version(2, 5, 0),
+ macosMinVer: Version(2, 5, 0),
+ );
+ });
+
+ test('interfaces', () {
+ expect(bindings, isNot(contains('DeprecatedInterface ')));
+ expect(bindings, contains('DeprecatedInterfaceMethods '));
+ });
+
+ test('protocols', () {
+ expect(bindings, isNot(contains('DeprecatedProtocol ')));
+ expect(bindings, contains('DeprecatedProtocolMethods '));
+ });
+
+ test('interface methods', () {
+ expect(bindings, contains('normalMethod'));
+ expect(bindings, contains('unavailableMac'));
+ expect(bindings, contains('unavailableIos'));
+ expect(bindings, isNot(contains('unavailableBoth')));
+ expect(bindings, contains('depMac2'));
+ expect(bindings, contains('depMac3'));
+ expect(bindings, contains('depIos2'));
+ expect(bindings, isNot(contains('depIos2Mac2')));
+ expect(bindings, contains('depIos2Mac3'));
+ expect(bindings, contains('depIos3'));
+ expect(bindings, contains('depIos3Mac2'));
+ expect(bindings, contains('depIos3Mac3'));
+ expect(bindings, isNot(contains('alwaysDeprecated')));
+ expect(bindings, isNot(contains('alwaysUnavailable')));
+ });
+
+ test('interface properties', () {
+ expect(bindings, contains('get normalProperty'));
+ expect(bindings, contains('set normalProperty'));
+ expect(bindings, isNot(contains('get deprecatedProperty')));
+ expect(bindings, isNot(contains('set deprecatedProperty')));
+ });
+
+ test('protocol methods', () {
+ expect(bindings, contains('protNormalMethod'));
+ expect(bindings, contains('protUnavailableMac'));
+ expect(bindings, contains('protUnavailableIos'));
+ expect(bindings, isNot(contains('protUnavailableBoth')));
+ expect(bindings, contains('protDepMac2'));
+ expect(bindings, contains('protDepMac3'));
+ expect(bindings, contains('protDepIos2'));
+ expect(bindings, isNot(contains('protDepIos2Mac2')));
+ expect(bindings, contains('protDepIos2Mac3'));
+ expect(bindings, contains('protDepIos3'));
+ expect(bindings, contains('protDepIos3Mac2'));
+ expect(bindings, contains('protDepIos3Mac3'));
+ expect(bindings, isNot(contains('protAlwaysDeprecated')));
+ expect(bindings, isNot(contains('protAlwaysUnavailable')));
+ });
+
+ test('protocol properties', () {
+ expect(bindings, contains('protNormalProperty'));
+ expect(bindings, contains('setProtNormalProperty'));
+ expect(bindings, isNot(contains('protDeprecatedProperty')));
+ expect(bindings, isNot(contains('setProtDeprecatedProperty')));
+ });
+
+ test('functions', () {
+ expect(bindings, contains('normalFunction'));
+ expect(bindings, isNot(contains('deprecatedFunction')));
+ });
+
+ test('structs', () {
+ expect(bindings, contains('NormalStruct'));
+ expect(bindings, isNot(contains('DeprecatedStruct')));
+ });
+
+ test('unions', () {
+ expect(bindings, contains('NormalUnion'));
+ expect(bindings, isNot(contains('DeprecatedUnion')));
+ });
+
+ test('enums', () {
+ expect(bindings, contains('NormalEnum'));
+ expect(bindings, isNot(contains('DeprecatedEnum')));
+ });
+
+ test('unnamed enums', () {
+ expect(bindings, contains('normalUnnamedEnum'));
+ expect(bindings, isNot(contains('deprecatedUnnamedEnum')));
+ });
+ });
+
+ group('ios 3.5, macos 3.5', () {
+ late final String bindings;
+ setUpAll(() {
+ bindings = bindingsForVersion(
+ iosMinVer: Version(3, 5, 0),
+ macosMinVer: Version(3, 5, 0),
+ );
+ });
+
+ test('interfaces', () {
+ expect(bindings, isNot(contains('DeprecatedInterface ')));
+ expect(bindings, contains('DeprecatedInterfaceMethods '));
+ });
+
+ test('protocols', () {
+ expect(bindings, isNot(contains('DeprecatedProtocol ')));
+ expect(bindings, contains('DeprecatedProtocolMethods '));
+ });
+
+ test('interface methods', () {
+ expect(bindings, contains('normalMethod'));
+ expect(bindings, contains('unavailableMac'));
+ expect(bindings, contains('unavailableIos'));
+ expect(bindings, isNot(contains('unavailableBoth')));
+ expect(bindings, contains('depMac2'));
+ expect(bindings, contains('depMac3'));
+ expect(bindings, contains('depIos2'));
+ expect(bindings, isNot(contains('depIos2Mac2')));
+ expect(bindings, isNot(contains('depIos2Mac3')));
+ expect(bindings, contains('depIos3'));
+ expect(bindings, isNot(contains('depIos3Mac2')));
+ expect(bindings, isNot(contains('depIos3Mac3')));
+ expect(bindings, isNot(contains('alwaysDeprecated')));
+ expect(bindings, isNot(contains('alwaysUnavailable')));
+ });
+
+ test('interface properties', () {
+ expect(bindings, contains('get normalProperty'));
+ expect(bindings, contains('set normalProperty'));
+ expect(bindings, isNot(contains('get deprecatedProperty')));
+ expect(bindings, isNot(contains('set deprecatedProperty')));
+ });
+
+ test('protocol methods', () {
+ expect(bindings, contains('protNormalMethod'));
+ expect(bindings, contains('protUnavailableMac'));
+ expect(bindings, contains('protUnavailableIos'));
+ expect(bindings, isNot(contains('protUnavailableBoth')));
+ expect(bindings, contains('protDepMac2'));
+ expect(bindings, contains('protDepMac3'));
+ expect(bindings, contains('protDepIos2'));
+ expect(bindings, isNot(contains('protDepIos2Mac2')));
+ expect(bindings, isNot(contains('protDepIos2Mac3')));
+ expect(bindings, contains('protDepIos3'));
+ expect(bindings, isNot(contains('protDepIos3Mac2')));
+ expect(bindings, isNot(contains('protDepIos3Mac3')));
+ expect(bindings, isNot(contains('protAlwaysDeprecated')));
+ expect(bindings, isNot(contains('protAlwaysUnavailable')));
+ });
+
+ test('protocol properties', () {
+ expect(bindings, contains('protNormalProperty'));
+ expect(bindings, contains('setProtNormalProperty'));
+ expect(bindings, isNot(contains('protDeprecatedProperty')));
+ expect(bindings, isNot(contains('setProtDeprecatedProperty')));
+ });
+
+ test('functions', () {
+ expect(bindings, contains('normalFunction'));
+ expect(bindings, isNot(contains('deprecatedFunction')));
+ });
+
+ test('structs', () {
+ expect(bindings, contains('NormalStruct'));
+ expect(bindings, isNot(contains('DeprecatedStruct')));
+ });
+
+ test('unions', () {
+ expect(bindings, contains('NormalUnion'));
+ expect(bindings, isNot(contains('DeprecatedUnion')));
+ });
+
+ test('enums', () {
+ expect(bindings, contains('NormalEnum'));
+ expect(bindings, isNot(contains('DeprecatedEnum')));
+ });
+
+ test('unnamed enums', () {
+ expect(bindings, contains('normalUnnamedEnum'));
+ expect(bindings, isNot(contains('deprecatedUnnamedEnum')));
+ });
+ });
+ });
+}
diff --git a/pkgs/ffigen/test/native_objc_test/deprecated_test.m b/pkgs/ffigen/test/native_objc_test/deprecated_test.m
new file mode 100644
index 0000000000..51a99f63c2
--- /dev/null
+++ b/pkgs/ffigen/test/native_objc_test/deprecated_test.m
@@ -0,0 +1,94 @@
+#import
+
+API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0))
+@interface DeprecatedInterface : NSObject;
+@end
+
+API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0))
+@protocol DeprecatedProtocol
+@end
+
+@interface DeprecatedInterfaceMethods : NSObject;
+
+-(int)normalMethod;
+
+// If an API is available in either OS, it is code-genned normally. So the only
+// method that is omitted is unavailableBoth.
+-(int)unavailableMac API_UNAVAILABLE(macos);
+-(int)unavailableIos API_UNAVAILABLE(ios);
+-(int)unavailableBoth API_UNAVAILABLE(ios, macos);
+
+// deprecated_config.yaml targets v2.5 for both APIs. For an API to be omitted
+// it needs to be deprecated before that version in both OSs. Of the methods
+// below, the only one that fits that condition is depIos2Mac2. The rest are
+// code-genned normally.
+-(int)depMac2 API_DEPRECATED("test", macos(1.0, 2.0));
+-(int)depMac3 API_DEPRECATED("test", macos(1.0, 3.0));
+-(int)depIos2 API_DEPRECATED("test", ios(1.0, 2.0));
+-(int)depIos2Mac2 API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+-(int)depIos2Mac3 API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 3.0));
+-(int)depIos3 API_DEPRECATED("test", ios(1.0, 3.0));
+-(int)depIos3Mac2 API_DEPRECATED("test", ios(1.0, 3.0), macos(1.0, 2.0));
+-(int)depIos3Mac3 API_DEPRECATED("test", ios(1.0, 3.0), macos(1.0, 3.0));
+
+// Methods deprecated/unavailable using __attribute__ set the alwaysDeprecated
+// and alwaysUnavailable flags. These are always omitted, regardless of the
+// min targeted versions.
+-(int)alwaysDeprecated __attribute__((deprecated));
+-(int)alwaysUnavailable __attribute__((unavailable));
+
+@property int normalProperty;
+@property int deprecatedProperty API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+
+@end
+
+@protocol DeprecatedProtocolMethods
+-(int)protNormalMethod;
+-(int)protUnavailableMac API_UNAVAILABLE(macos);
+-(int)protUnavailableIos API_UNAVAILABLE(ios);
+-(int)protUnavailableBoth API_UNAVAILABLE(ios, macos);
+-(int)protDepMac2 API_DEPRECATED("test", macos(1.0, 2.0));
+-(int)protDepMac3 API_DEPRECATED("test", macos(1.0, 3.0));
+-(int)protDepIos2 API_DEPRECATED("test", ios(1.0, 2.0));
+-(int)protDepIos2Mac2 API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+-(int)protDepIos2Mac3 API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 3.0));
+-(int)protDepIos3 API_DEPRECATED("test", ios(1.0, 3.0));
+-(int)protDepIos3Mac2 API_DEPRECATED("test", ios(1.0, 3.0), macos(1.0, 2.0));
+-(int)protDepIos3Mac3 API_DEPRECATED("test", ios(1.0, 3.0), macos(1.0, 3.0));
+-(int)protAlwaysDeprecated __attribute__((deprecated));
+-(int)protAlwaysUnavailable __attribute__((unavailable));
+@property int protNormalProperty;
+@property int protDeprecatedProperty API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+@end
+
+int normalFunction();
+int deprecatedFunction() API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+
+struct NormalStruct {
+ int x;
+};
+
+struct DeprecatedStruct {
+ int x;
+} API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+
+union NormalUnion {
+ int x;
+};
+
+union DeprecatedUnion {
+ int x;
+} API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+
+enum NormalEnum {
+ x
+};
+
+enum DeprecatedEnum {
+ y
+} API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0));
+
+enum {
+ normalUnnamedEnum,
+ deprecatedUnnamedEnum API_DEPRECATED("test", ios(1.0, 2.0), macos(1.0, 2.0)),
+};
diff --git a/pkgs/ffigen/test/unit_tests/api_availability_test.dart b/pkgs/ffigen/test/unit_tests/api_availability_test.dart
new file mode 100644
index 0000000000..0ce642662f
--- /dev/null
+++ b/pkgs/ffigen/test/unit_tests/api_availability_test.dart
@@ -0,0 +1,356 @@
+// Copyright (c) 2024, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+import 'package:ffigen/src/config_provider/config_types.dart';
+import 'package:ffigen/src/header_parser/sub_parsers/api_availability.dart';
+import 'package:pub_semver/pub_semver.dart';
+import 'package:test/test.dart';
+
+void main() {
+ group('API availability', () {
+ test('empty', () {
+ final api = ApiAvailability();
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 2, 3)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(1, 2, 3)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 2, 3)),
+ macos: Versions(min: Version(1, 2, 3)),
+ )),
+ true);
+ });
+
+ test('always deprecated', () {
+ final api = ApiAvailability(alwaysDeprecated: true);
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 2, 3)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(1, 2, 3)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 2, 3)),
+ macos: Versions(min: Version(1, 2, 3)),
+ )),
+ false);
+ });
+
+ test('always unavailable', () {
+ final api = ApiAvailability(alwaysUnavailable: true);
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 2, 3)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(1, 2, 3)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 2, 3)),
+ macos: Versions(min: Version(1, 2, 3)),
+ )),
+ false);
+ });
+
+ test('ios', () {
+ final api = ApiAvailability(
+ ios: PlatformAvailability(
+ introduced: Version(1, 2, 3),
+ deprecated: Version(4, 5, 6),
+ obsoleted: Version(7, 8, 9),
+ ),
+ );
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(5, 0, 0)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ false);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(5, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ });
+
+ test('ios, empty PlatformAvailability', () {
+ final api = ApiAvailability(
+ ios: PlatformAvailability(),
+ );
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ });
+
+ test('ios, unavailable', () {
+ final api = ApiAvailability(
+ ios: PlatformAvailability(
+ unavailable: true,
+ ),
+ );
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ });
+
+ test('macos', () {
+ final api = ApiAvailability(
+ macos: PlatformAvailability(
+ introduced: Version(1, 2, 3),
+ deprecated: Version(4, 5, 6),
+ obsoleted: Version(7, 8, 9),
+ ),
+ );
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(1, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(5, 0, 0)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ false);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(1, 0, 0)),
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(5, 0, 0)),
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ });
+
+ test('macos, empty PlatformAvailability', () {
+ final api = ApiAvailability(
+ macos: PlatformAvailability(),
+ );
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ });
+
+ test('macos, unavailable', () {
+ final api = ApiAvailability(
+ macos: PlatformAvailability(
+ unavailable: true,
+ ),
+ );
+
+ expect(api.isAvailable(const ExternalVersions()), true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ macos: Versions(min: Version(10, 0, 0)),
+ ios: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ });
+
+ test('both', () {
+ final api = ApiAvailability(
+ ios: PlatformAvailability(
+ introduced: Version(1, 2, 3),
+ deprecated: Version(4, 5, 6),
+ obsoleted: Version(7, 8, 9),
+ ),
+ macos: PlatformAvailability(
+ introduced: Version(2, 3, 4),
+ deprecated: Version(5, 6, 7),
+ obsoleted: Version(8, 9, 10),
+ ),
+ );
+
+ expect(
+ api.isAvailable(const ExternalVersions(
+ ios: null,
+ macos: null,
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 0, 0)),
+ macos: null,
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ macos: null,
+ )),
+ false);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: null,
+ macos: Versions(min: Version(1, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 0, 0)),
+ macos: Versions(min: Version(1, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ macos: Versions(min: Version(1, 0, 0)),
+ )),
+ true);
+
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: null,
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ false);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(1, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ true);
+ expect(
+ api.isAvailable(ExternalVersions(
+ ios: Versions(min: Version(10, 0, 0)),
+ macos: Versions(min: Version(10, 0, 0)),
+ )),
+ false);
+ });
+ });
+}
diff --git a/pkgs/ffigen/tool/libclang_config.yaml b/pkgs/ffigen/tool/libclang_config.yaml
index 804d3861c4..4b305df54c 100644
--- a/pkgs/ffigen/tool/libclang_config.yaml
+++ b/pkgs/ffigen/tool/libclang_config.yaml
@@ -43,6 +43,9 @@ enums:
- CXObjCPropertyAttrKind
- CXTypeNullabilityKind
- CXTypeLayoutError
+ as-int:
+ include:
+ - .*
structs:
include:
@@ -117,6 +120,9 @@ functions:
- clang_getFieldDeclBitWidth
- clang_Cursor_isFunctionInlined
- clang_getCursorDefinition
+ - clang_getCursorAvailability
+ - clang_getCursorPlatformAvailability
+ - clang_disposeCXPlatformAvailability
- clang_Cursor_isNull
- clang_Cursor_hasAttrs
- clang_Type_getObjCObjectBaseType
diff --git a/pkgs/objective_c/CHANGELOG.md b/pkgs/objective_c/CHANGELOG.md
index 47d06c8af9..0affec501c 100644
--- a/pkgs/objective_c/CHANGELOG.md
+++ b/pkgs/objective_c/CHANGELOG.md
@@ -1,3 +1,8 @@
+## 1.2.0-wip
+
+- Drop API methods that are deprecated in the oldest versions of iOS and macOS
+ that flutter supports.
+
## 1.1.0
- Add `DartProxy`, which is an implementation of `NSProxy` that enables
diff --git a/pkgs/objective_c/ffigen_objc.yaml b/pkgs/objective_c/ffigen_objc.yaml
index ea88b0f902..b19f3b8704 100644
--- a/pkgs/objective_c/ffigen_objc.yaml
+++ b/pkgs/objective_c/ffigen_objc.yaml
@@ -10,6 +10,12 @@ headers:
ffi-native:
exclude-all-by-default: true
generate-for-package-objective-c: true
+external-versions:
+ # See https://docs.flutter.dev/reference/supported-platforms.
+ ios:
+ min: 12.0.0
+ macos:
+ min: 10.14.0
objc-interfaces:
# Keep in sync with ffigen's ObjCBuiltInFunctions.builtInInterfaces.
include:
diff --git a/pkgs/objective_c/lib/src/objective_c_bindings_generated.dart b/pkgs/objective_c/lib/src/objective_c_bindings_generated.dart
index 29e0a05ce9..fb8f8a60d2 100644
--- a/pkgs/objective_c/lib/src/objective_c_bindings_generated.dart
+++ b/pkgs/objective_c/lib/src/objective_c_bindings_generated.dart
@@ -78,11 +78,6 @@ class NSObject extends objc.ObjCObjectBase {
_objc_msgSend_1(this.pointer, _sel_dealloc);
}
- /// finalize
- void finalize() {
- _objc_msgSend_1(this.pointer, _sel_finalize);
- }
-
/// copy
objc.ObjCObjectBase copy() {
final _ret = _objc_msgSend_2(this.pointer, _sel_copy);
@@ -156,7 +151,7 @@ class NSObject extends objc.ObjCObjectBase {
/// methodSignatureForSelector:
NSMethodSignature methodSignatureForSelector_(
ffi.Pointer aSelector) {
- final _ret = _objc_msgSend_260(
+ final _ret = _objc_msgSend_240(
this.pointer, _sel_methodSignatureForSelector_, aSelector);
return NSMethodSignature.castFromPointer(_ret, retain: true, release: true);
}
@@ -164,21 +159,11 @@ class NSObject extends objc.ObjCObjectBase {
/// instanceMethodSignatureForSelector:
static NSMethodSignature instanceMethodSignatureForSelector_(
ffi.Pointer aSelector) {
- final _ret = _objc_msgSend_260(
+ final _ret = _objc_msgSend_240(
_class_NSObject, _sel_instanceMethodSignatureForSelector_, aSelector);
return NSMethodSignature.castFromPointer(_ret, retain: true, release: true);
}
- /// allowsWeakReference
- bool allowsWeakReference() {
- return _objc_msgSend_13(this.pointer, _sel_allowsWeakReference);
- }
-
- /// retainWeakReference
- bool retainWeakReference() {
- return _objc_msgSend_13(this.pointer, _sel_retainWeakReference);
- }
-
/// isSubclassOfClass:
static bool isSubclassOfClass_(objc.ObjCObjectBase aClass) {
return _objc_msgSend_0(
@@ -226,12 +211,12 @@ class NSObject extends objc.ObjCObjectBase {
/// version
static int version() {
- return _objc_msgSend_80(_class_NSObject, _sel_version);
+ return _objc_msgSend_79(_class_NSObject, _sel_version);
}
/// setVersion:
static void setVersion_(int aVersion) {
- _objc_msgSend_261(_class_NSObject, _sel_setVersion_, aVersion);
+ _objc_msgSend_241(_class_NSObject, _sel_setVersion_, aVersion);
}
/// classForCoder
@@ -258,11 +243,6 @@ class NSObject extends objc.ObjCObjectBase {
: objc.ObjCObjectBase(_ret, retain: false, release: true);
}
- /// poseAsClass:
- static void poseAsClass_(objc.ObjCObjectBase aClass) {
- _objc_msgSend_179(_class_NSObject, _sel_poseAsClass_, aClass.pointer);
- }
-
/// autoContentAccessingProxy
objc.ObjCObjectBase get autoContentAccessingProxy {
final _ret = _objc_msgSend_2(this.pointer, _sel_autoContentAccessingProxy);
@@ -277,7 +257,7 @@ class NSObject extends objc.ObjCObjectBase {
objc.ObjCObjectBase? delegate,
ffi.Pointer didRecoverSelector,
ffi.Pointer contextInfo) {
- _objc_msgSend_262(
+ _objc_msgSend_242(
this.pointer,
_sel_attemptRecoveryFromError_optionIndex_delegate_didRecoverSelector_contextInfo_,
error.pointer,
@@ -290,7 +270,7 @@ class NSObject extends objc.ObjCObjectBase {
/// attemptRecoveryFromError:optionIndex:
bool attemptRecoveryFromError_optionIndex_(
NSError error, int recoveryOptionIndex) {
- return _objc_msgSend_263(
+ return _objc_msgSend_243(
this.pointer,
_sel_attemptRecoveryFromError_optionIndex_,
error.pointer,
@@ -303,7 +283,7 @@ class NSObject extends objc.ObjCObjectBase {
objc.ObjCObjectBase? object,
NSDictionary? change,
ffi.Pointer context) {
- _objc_msgSend_264(
+ _objc_msgSend_244(
this.pointer,
_sel_observeValueForKeyPath_ofObject_change_context_,
keyPath?.pointer ?? ffi.nullptr,
@@ -318,7 +298,7 @@ class NSObject extends objc.ObjCObjectBase {
NSString keyPath,
NSKeyValueObservingOptions options,
ffi.Pointer context) {
- _objc_msgSend_141(
+ _objc_msgSend_138(
this.pointer,
_sel_addObserver_forKeyPath_options_context_,
observer.pointer,
@@ -330,44 +310,44 @@ class NSObject extends objc.ObjCObjectBase {
/// removeObserver:forKeyPath:context:
void removeObserver_forKeyPath_context_(
NSObject observer, NSString keyPath, ffi.Pointer context) {
- _objc_msgSend_142(this.pointer, _sel_removeObserver_forKeyPath_context_,
+ _objc_msgSend_139(this.pointer, _sel_removeObserver_forKeyPath_context_,
observer.pointer, keyPath.pointer, context);
}
/// removeObserver:forKeyPath:
void removeObserver_forKeyPath_(NSObject observer, NSString keyPath) {
- _objc_msgSend_143(this.pointer, _sel_removeObserver_forKeyPath_,
+ _objc_msgSend_140(this.pointer, _sel_removeObserver_forKeyPath_,
observer.pointer, keyPath.pointer);
}
/// willChangeValueForKey:
void willChangeValueForKey_(NSString key) {
- _objc_msgSend_151(this.pointer, _sel_willChangeValueForKey_, key.pointer);
+ _objc_msgSend_148(this.pointer, _sel_willChangeValueForKey_, key.pointer);
}
/// didChangeValueForKey:
void didChangeValueForKey_(NSString key) {
- _objc_msgSend_151(this.pointer, _sel_didChangeValueForKey_, key.pointer);
+ _objc_msgSend_148(this.pointer, _sel_didChangeValueForKey_, key.pointer);
}
/// willChange:valuesAtIndexes:forKey:
void willChange_valuesAtIndexes_forKey_(
NSKeyValueChange changeKind, NSIndexSet indexes, NSString key) {
- _objc_msgSend_265(this.pointer, _sel_willChange_valuesAtIndexes_forKey_,
+ _objc_msgSend_245(this.pointer, _sel_willChange_valuesAtIndexes_forKey_,
changeKind.value, indexes.pointer, key.pointer);
}
/// didChange:valuesAtIndexes:forKey:
void didChange_valuesAtIndexes_forKey_(
NSKeyValueChange changeKind, NSIndexSet indexes, NSString key) {
- _objc_msgSend_265(this.pointer, _sel_didChange_valuesAtIndexes_forKey_,
+ _objc_msgSend_245(this.pointer, _sel_didChange_valuesAtIndexes_forKey_,
changeKind.value, indexes.pointer, key.pointer);
}
/// willChangeValueForKey:withSetMutation:usingObjects:
void willChangeValueForKey_withSetMutation_usingObjects_(
NSString key, NSKeyValueSetMutationKind mutationKind, NSSet objects) {
- _objc_msgSend_266(
+ _objc_msgSend_246(
this.pointer,
_sel_willChangeValueForKey_withSetMutation_usingObjects_,
key.pointer,
@@ -378,7 +358,7 @@ class NSObject extends objc.ObjCObjectBase {
/// didChangeValueForKey:withSetMutation:usingObjects:
void didChangeValueForKey_withSetMutation_usingObjects_(
NSString key, NSKeyValueSetMutationKind mutationKind, NSSet objects) {
- _objc_msgSend_266(
+ _objc_msgSend_246(
this.pointer,
_sel_didChangeValueForKey_withSetMutation_usingObjects_,
key.pointer,
@@ -388,7 +368,7 @@ class NSObject extends objc.ObjCObjectBase {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSObject,
+ final _ret = _objc_msgSend_95(_class_NSObject,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -406,41 +386,7 @@ class NSObject extends objc.ObjCObjectBase {
/// setObservationInfo:
set observationInfo(ffi.Pointer value) {
- return _objc_msgSend_267(this.pointer, _sel_setObservationInfo_, value);
- }
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSObject,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
-
- /// URL:resourceDataDidBecomeAvailable:
- void URL_resourceDataDidBecomeAvailable_(NSURL sender, NSData newBytes) {
- _objc_msgSend_268(this.pointer, _sel_URL_resourceDataDidBecomeAvailable_,
- sender.pointer, newBytes.pointer);
- }
-
- /// URLResourceDidFinishLoading:
- void URLResourceDidFinishLoading_(NSURL sender) {
- _objc_msgSend_269(
- this.pointer, _sel_URLResourceDidFinishLoading_, sender.pointer);
- }
-
- /// URLResourceDidCancelLoading:
- void URLResourceDidCancelLoading_(NSURL sender) {
- _objc_msgSend_269(
- this.pointer, _sel_URLResourceDidCancelLoading_, sender.pointer);
- }
-
- /// URL:resourceDidFailLoadingWithReason:
- void URL_resourceDidFailLoadingWithReason_(NSURL sender, NSString reason) {
- _objc_msgSend_270(this.pointer, _sel_URL_resourceDidFailLoadingWithReason_,
- sender.pointer, reason.pointer);
+ return _objc_msgSend_247(this.pointer, _sel_setObservationInfo_, value);
}
}
@@ -481,7 +427,6 @@ final _objc_msgSend_3 = objc.msgSendPointer
ffi.Pointer, ffi.Pointer<_NSZone>)>();
late final _sel_alloc = objc.registerName("alloc");
late final _sel_dealloc = objc.registerName("dealloc");
-late final _sel_finalize = objc.registerName("finalize");
late final _sel_copy = objc.registerName("copy");
late final _sel_mutableCopy = objc.registerName("mutableCopy");
late final _sel_copyWithZone_ = objc.registerName("copyWithZone:");
@@ -710,7 +655,7 @@ class NSMethodSignature extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSMethodSignature,
+ final _ret = _objc_msgSend_95(_class_NSMethodSignature,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -720,16 +665,6 @@ class NSMethodSignature extends NSObject {
return _objc_msgSend_26(_class_NSMethodSignature,
_sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSMethodSignature,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSMethodSignature = objc.getClass("NSMethodSignature");
@@ -818,7 +753,7 @@ class NSSet extends NSObject {
/// objectEnumerator
NSEnumerator objectEnumerator() {
- final _ret = _objc_msgSend_108(this.pointer, _sel_objectEnumerator);
+ final _ret = _objc_msgSend_110(this.pointer, _sel_objectEnumerator);
return NSEnumerator.castFromPointer(_ret, retain: true, release: true);
}
@@ -831,7 +766,7 @@ class NSSet extends NSObject {
/// initWithObjects:count:
NSSet initWithObjects_count_(
ffi.Pointer> objects, int cnt) {
- final _ret = _objc_msgSend_98(
+ final _ret = _objc_msgSend_100(
this.pointer, _sel_initWithObjects_count_, objects, cnt);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -847,7 +782,7 @@ class NSSet extends NSObject {
/// allObjects
NSArray get allObjects {
- final _ret = _objc_msgSend_115(this.pointer, _sel_allObjects);
+ final _ret = _objc_msgSend_142(this.pointer, _sel_allObjects);
return NSArray.castFromPointer(_ret, retain: true, release: true);
}
@@ -873,26 +808,26 @@ class NSSet extends NSObject {
/// descriptionWithLocale:
NSString descriptionWithLocale_(objc.ObjCObjectBase? locale) {
- final _ret = _objc_msgSend_87(this.pointer, _sel_descriptionWithLocale_,
+ final _ret = _objc_msgSend_86(this.pointer, _sel_descriptionWithLocale_,
locale?.pointer ?? ffi.nullptr);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// intersectsSet:
bool intersectsSet_(NSSet otherSet) {
- return _objc_msgSend_254(
+ return _objc_msgSend_234(
this.pointer, _sel_intersectsSet_, otherSet.pointer);
}
/// isEqualToSet:
bool isEqualToSet_(NSSet otherSet) {
- return _objc_msgSend_254(
+ return _objc_msgSend_234(
this.pointer, _sel_isEqualToSet_, otherSet.pointer);
}
/// isSubsetOfSet:
bool isSubsetOfSet_(NSSet otherSet) {
- return _objc_msgSend_254(
+ return _objc_msgSend_234(
this.pointer, _sel_isSubsetOfSet_, otherSet.pointer);
}
@@ -904,27 +839,27 @@ class NSSet extends NSObject {
/// makeObjectsPerformSelector:withObject:
void makeObjectsPerformSelector_withObject_(
ffi.Pointer aSelector, objc.ObjCObjectBase? argument) {
- _objc_msgSend_118(this.pointer, _sel_makeObjectsPerformSelector_withObject_,
+ _objc_msgSend_116(this.pointer, _sel_makeObjectsPerformSelector_withObject_,
aSelector, argument?.pointer ?? ffi.nullptr);
}
/// setByAddingObject:
NSSet setByAddingObject_(objc.ObjCObjectBase anObject) {
- final _ret = _objc_msgSend_255(
+ final _ret = _objc_msgSend_235(
this.pointer, _sel_setByAddingObject_, anObject.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// setByAddingObjectsFromSet:
NSSet setByAddingObjectsFromSet_(NSSet other) {
- final _ret = _objc_msgSend_256(
+ final _ret = _objc_msgSend_236(
this.pointer, _sel_setByAddingObjectsFromSet_, other.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// setByAddingObjectsFromArray:
NSSet setByAddingObjectsFromArray_(NSArray other) {
- final _ret = _objc_msgSend_257(
+ final _ret = _objc_msgSend_237(
this.pointer, _sel_setByAddingObjectsFromArray_, other.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -938,14 +873,14 @@ class NSSet extends NSObject {
/// setWithObject:
static NSSet setWithObject_(objc.ObjCObjectBase object) {
final _ret =
- _objc_msgSend_128(_class_NSSet, _sel_setWithObject_, object.pointer);
+ _objc_msgSend_126(_class_NSSet, _sel_setWithObject_, object.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// setWithObjects:count:
static NSSet setWithObjects_count_(
ffi.Pointer> objects, int cnt) {
- final _ret = _objc_msgSend_98(
+ final _ret = _objc_msgSend_100(
_class_NSSet, _sel_setWithObjects_count_, objects, cnt);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -953,26 +888,26 @@ class NSSet extends NSObject {
/// setWithObjects:
static NSSet setWithObjects_(objc.ObjCObjectBase firstObj) {
final _ret =
- _objc_msgSend_128(_class_NSSet, _sel_setWithObjects_, firstObj.pointer);
+ _objc_msgSend_126(_class_NSSet, _sel_setWithObjects_, firstObj.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// setWithSet:
static NSSet setWithSet_(NSSet set) {
- final _ret = _objc_msgSend_258(_class_NSSet, _sel_setWithSet_, set.pointer);
+ final _ret = _objc_msgSend_238(_class_NSSet, _sel_setWithSet_, set.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// setWithArray:
static NSSet setWithArray_(NSArray array) {
final _ret =
- _objc_msgSend_129(_class_NSSet, _sel_setWithArray_, array.pointer);
+ _objc_msgSend_127(_class_NSSet, _sel_setWithArray_, array.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// initWithObjects:
NSSet initWithObjects_(objc.ObjCObjectBase firstObj) {
- final _ret = _objc_msgSend_128(
+ final _ret = _objc_msgSend_126(
this.pointer, _sel_initWithObjects_, firstObj.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -980,13 +915,13 @@ class NSSet extends NSObject {
/// initWithSet:
NSSet initWithSet_(NSSet set) {
final _ret =
- _objc_msgSend_258(this.pointer, _sel_initWithSet_, set.pointer);
+ _objc_msgSend_238(this.pointer, _sel_initWithSet_, set.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
/// initWithSet:copyItems:
NSSet initWithSet_copyItems_(NSSet set, bool flag) {
- final _ret = _objc_msgSend_259(
+ final _ret = _objc_msgSend_239(
this.pointer, _sel_initWithSet_copyItems_, set.pointer, flag);
return NSSet.castFromPointer(_ret, retain: false, release: true);
}
@@ -994,7 +929,7 @@ class NSSet extends NSObject {
/// initWithArray:
NSSet initWithArray_(NSArray array) {
final _ret =
- _objc_msgSend_129(this.pointer, _sel_initWithArray_, array.pointer);
+ _objc_msgSend_127(this.pointer, _sel_initWithArray_, array.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -1004,7 +939,7 @@ class NSSet extends NSObject {
NSString keyPath,
NSKeyValueObservingOptions options,
ffi.Pointer context) {
- _objc_msgSend_141(
+ _objc_msgSend_138(
this.pointer,
_sel_addObserver_forKeyPath_options_context_,
observer.pointer,
@@ -1016,13 +951,13 @@ class NSSet extends NSObject {
/// removeObserver:forKeyPath:context:
void removeObserver_forKeyPath_context_(
NSObject observer, NSString keyPath, ffi.Pointer context) {
- _objc_msgSend_142(this.pointer, _sel_removeObserver_forKeyPath_context_,
+ _objc_msgSend_139(this.pointer, _sel_removeObserver_forKeyPath_context_,
observer.pointer, keyPath.pointer, context);
}
/// removeObserver:forKeyPath:
void removeObserver_forKeyPath_(NSObject observer, NSString keyPath) {
- _objc_msgSend_143(this.pointer, _sel_removeObserver_forKeyPath_,
+ _objc_msgSend_140(this.pointer, _sel_removeObserver_forKeyPath_,
observer.pointer, keyPath.pointer);
}
@@ -1046,7 +981,7 @@ class NSSet extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(
+ final _ret = _objc_msgSend_95(
_class_NSSet, _sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -1056,16 +991,6 @@ class NSSet extends NSObject {
return _objc_msgSend_26(
_class_NSSet, _sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSSet,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSSet = objc.getClass("NSSet");
@@ -1144,7 +1069,7 @@ class NSEnumerator extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSEnumerator,
+ final _ret = _objc_msgSend_95(_class_NSEnumerator,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -1154,16 +1079,6 @@ class NSEnumerator extends NSObject {
return _objc_msgSend_26(_class_NSEnumerator,
_sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSEnumerator,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSEnumerator = objc.getClass("NSEnumerator");
@@ -1449,9 +1364,9 @@ class NSString extends NSObject {
void rangeOfCharacterFromSet_(
ffi.Pointer stret, NSCharacterSet searchSet) {
objc.useMsgSendVariants
- ? _objc_msgSend_208Stret(stret, this.pointer,
+ ? _objc_msgSend_193Stret(stret, this.pointer,
_sel_rangeOfCharacterFromSet_, searchSet.pointer)
- : stret.ref = _objc_msgSend_208(
+ : stret.ref = _objc_msgSend_193(
this.pointer, _sel_rangeOfCharacterFromSet_, searchSet.pointer);
}
@@ -1459,13 +1374,13 @@ class NSString extends NSObject {
void rangeOfCharacterFromSet_options_(ffi.Pointer stret,
NSCharacterSet searchSet, NSStringCompareOptions mask) {
objc.useMsgSendVariants
- ? _objc_msgSend_209Stret(
+ ? _objc_msgSend_194Stret(
stret,
this.pointer,
_sel_rangeOfCharacterFromSet_options_,
searchSet.pointer,
mask.value)
- : stret.ref = _objc_msgSend_209(
+ : stret.ref = _objc_msgSend_194(
this.pointer,
_sel_rangeOfCharacterFromSet_options_,
searchSet.pointer,
@@ -1479,14 +1394,14 @@ class NSString extends NSObject {
NSStringCompareOptions mask,
NSRange rangeOfReceiverToSearch) {
objc.useMsgSendVariants
- ? _objc_msgSend_210Stret(
+ ? _objc_msgSend_195Stret(
stret,
this.pointer,
_sel_rangeOfCharacterFromSet_options_range_,
searchSet.pointer,
mask.value,
rangeOfReceiverToSearch)
- : stret.ref = _objc_msgSend_210(
+ : stret.ref = _objc_msgSend_195(
this.pointer,
_sel_rangeOfCharacterFromSet_options_range_,
searchSet.pointer,
@@ -1498,9 +1413,9 @@ class NSString extends NSObject {
void rangeOfComposedCharacterSequenceAtIndex_(
ffi.Pointer stret, int index) {
objc.useMsgSendVariants
- ? _objc_msgSend_211Stret(stret, this.pointer,
+ ? _objc_msgSend_196Stret(stret, this.pointer,
_sel_rangeOfComposedCharacterSequenceAtIndex_, index)
- : stret.ref = _objc_msgSend_211(
+ : stret.ref = _objc_msgSend_196(
this.pointer, _sel_rangeOfComposedCharacterSequenceAtIndex_, index);
}
@@ -1508,22 +1423,22 @@ class NSString extends NSObject {
void rangeOfComposedCharacterSequencesForRange_(
ffi.Pointer stret, NSRange range) {
objc.useMsgSendVariants
- ? _objc_msgSend_212Stret(stret, this.pointer,
+ ? _objc_msgSend_197Stret(stret, this.pointer,
_sel_rangeOfComposedCharacterSequencesForRange_, range)
- : stret.ref = _objc_msgSend_212(this.pointer,
+ : stret.ref = _objc_msgSend_197(this.pointer,
_sel_rangeOfComposedCharacterSequencesForRange_, range);
}
/// stringByAppendingString:
NSString stringByAppendingString_(NSString aString) {
- final _ret = _objc_msgSend_101(
+ final _ret = _objc_msgSend_103(
this.pointer, _sel_stringByAppendingString_, aString.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// stringByAppendingFormat:
NSString stringByAppendingFormat_(NSString format) {
- final _ret = _objc_msgSend_101(
+ final _ret = _objc_msgSend_103(
this.pointer, _sel_stringByAppendingFormat_, format.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -1531,30 +1446,30 @@ class NSString extends NSObject {
/// doubleValue
double get doubleValue {
return objc.useMsgSendVariants
- ? _objc_msgSend_84Fpret(this.pointer, _sel_doubleValue)
- : _objc_msgSend_84(this.pointer, _sel_doubleValue);
+ ? _objc_msgSend_83Fpret(this.pointer, _sel_doubleValue)
+ : _objc_msgSend_83(this.pointer, _sel_doubleValue);
}
/// floatValue
double get floatValue {
return objc.useMsgSendVariants
- ? _objc_msgSend_83Fpret(this.pointer, _sel_floatValue)
- : _objc_msgSend_83(this.pointer, _sel_floatValue);
+ ? _objc_msgSend_82Fpret(this.pointer, _sel_floatValue)
+ : _objc_msgSend_82(this.pointer, _sel_floatValue);
}
/// intValue
int get intValue {
- return _objc_msgSend_78(this.pointer, _sel_intValue);
+ return _objc_msgSend_77(this.pointer, _sel_intValue);
}
/// integerValue
int get integerValue {
- return _objc_msgSend_80(this.pointer, _sel_integerValue);
+ return _objc_msgSend_79(this.pointer, _sel_integerValue);
}
/// longLongValue
int get longLongValue {
- return _objc_msgSend_81(this.pointer, _sel_longLongValue);
+ return _objc_msgSend_80(this.pointer, _sel_longLongValue);
}
/// boolValue
@@ -1601,21 +1516,21 @@ class NSString extends NSObject {
/// uppercaseStringWithLocale:
NSString uppercaseStringWithLocale_(NSLocale? locale) {
- final _ret = _objc_msgSend_213(this.pointer,
+ final _ret = _objc_msgSend_198(this.pointer,
_sel_uppercaseStringWithLocale_, locale?.pointer ?? ffi.nullptr);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// lowercaseStringWithLocale:
NSString lowercaseStringWithLocale_(NSLocale? locale) {
- final _ret = _objc_msgSend_213(this.pointer,
+ final _ret = _objc_msgSend_198(this.pointer,
_sel_lowercaseStringWithLocale_, locale?.pointer ?? ffi.nullptr);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// capitalizedStringWithLocale:
NSString capitalizedStringWithLocale_(NSLocale? locale) {
- final _ret = _objc_msgSend_213(this.pointer,
+ final _ret = _objc_msgSend_198(this.pointer,
_sel_capitalizedStringWithLocale_, locale?.pointer ?? ffi.nullptr);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -1626,17 +1541,17 @@ class NSString extends NSObject {
ffi.Pointer lineEndPtr,
ffi.Pointer contentsEndPtr,
NSRange range) {
- _objc_msgSend_214(this.pointer, _sel_getLineStart_end_contentsEnd_forRange_,
+ _objc_msgSend_199(this.pointer, _sel_getLineStart_end_contentsEnd_forRange_,
startPtr, lineEndPtr, contentsEndPtr, range);
}
/// lineRangeForRange:
void lineRangeForRange_(ffi.Pointer stret, NSRange range) {
objc.useMsgSendVariants
- ? _objc_msgSend_212Stret(
+ ? _objc_msgSend_197Stret(
stret, this.pointer, _sel_lineRangeForRange_, range)
: stret.ref =
- _objc_msgSend_212(this.pointer, _sel_lineRangeForRange_, range);
+ _objc_msgSend_197(this.pointer, _sel_lineRangeForRange_, range);
}
/// getParagraphStart:end:contentsEnd:forRange:
@@ -1645,7 +1560,7 @@ class NSString extends NSObject {
ffi.Pointer parEndPtr,
ffi.Pointer contentsEndPtr,
NSRange range) {
- _objc_msgSend_214(
+ _objc_msgSend_199(
this.pointer,
_sel_getParagraphStart_end_contentsEnd_forRange_,
startPtr,
@@ -1657,9 +1572,9 @@ class NSString extends NSObject {
/// paragraphRangeForRange:
void paragraphRangeForRange_(ffi.Pointer stret, NSRange range) {
objc.useMsgSendVariants
- ? _objc_msgSend_212Stret(
+ ? _objc_msgSend_197Stret(
stret, this.pointer, _sel_paragraphRangeForRange_, range)
- : stret.ref = _objc_msgSend_212(
+ : stret.ref = _objc_msgSend_197(
this.pointer, _sel_paragraphRangeForRange_, range);
}
@@ -1680,7 +1595,7 @@ class NSString extends NSObject {
/// dataUsingEncoding:allowLossyConversion:
NSData? dataUsingEncoding_allowLossyConversion_(int encoding, bool lossy) {
- final _ret = _objc_msgSend_215(this.pointer,
+ final _ret = _objc_msgSend_200(this.pointer,
_sel_dataUsingEncoding_allowLossyConversion_, encoding, lossy);
return _ret.address == 0
? null
@@ -1690,7 +1605,7 @@ class NSString extends NSObject {
/// dataUsingEncoding:
NSData? dataUsingEncoding_(int encoding) {
final _ret =
- _objc_msgSend_216(this.pointer, _sel_dataUsingEncoding_, encoding);
+ _objc_msgSend_201(this.pointer, _sel_dataUsingEncoding_, encoding);
return _ret.address == 0
? null
: NSData.castFromPointer(_ret, retain: true, release: true);
@@ -1698,7 +1613,7 @@ class NSString extends NSObject {
/// canBeConvertedToEncoding:
bool canBeConvertedToEncoding_(int encoding) {
- return _objc_msgSend_125(
+ return _objc_msgSend_123(
this.pointer, _sel_canBeConvertedToEncoding_, encoding);
}
@@ -1710,7 +1625,7 @@ class NSString extends NSObject {
/// getCString:maxLength:encoding:
bool getCString_maxLength_encoding_(
ffi.Pointer buffer, int maxBufferCount, int encoding) {
- return _objc_msgSend_217(this.pointer, _sel_getCString_maxLength_encoding_,
+ return _objc_msgSend_202(this.pointer, _sel_getCString_maxLength_encoding_,
buffer, maxBufferCount, encoding);
}
@@ -1723,7 +1638,7 @@ class NSString extends NSObject {
NSStringEncodingConversionOptions options,
NSRange range,
ffi.Pointer leftover) {
- return _objc_msgSend_218(
+ return _objc_msgSend_203(
this.pointer,
_sel_getBytes_maxLength_usedLength_encoding_options_range_remainingRange_,
buffer,
@@ -1737,19 +1652,19 @@ class NSString extends NSObject {
/// maximumLengthOfBytesUsingEncoding:
int maximumLengthOfBytesUsingEncoding_(int enc) {
- return _objc_msgSend_122(
+ return _objc_msgSend_120(
this.pointer, _sel_maximumLengthOfBytesUsingEncoding_, enc);
}
/// lengthOfBytesUsingEncoding:
int lengthOfBytesUsingEncoding_(int enc) {
- return _objc_msgSend_122(
+ return _objc_msgSend_120(
this.pointer, _sel_lengthOfBytesUsingEncoding_, enc);
}
/// availableStringEncodings
static ffi.Pointer getAvailableStringEncodings() {
- return _objc_msgSend_219(_class_NSString, _sel_availableStringEncodings);
+ return _objc_msgSend_204(_class_NSString, _sel_availableStringEncodings);
}
/// localizedNameOfStringEncoding:
@@ -1794,21 +1709,21 @@ class NSString extends NSObject {
/// componentsSeparatedByString:
NSArray componentsSeparatedByString_(NSString separator) {
- final _ret = _objc_msgSend_220(
+ final _ret = _objc_msgSend_205(
this.pointer, _sel_componentsSeparatedByString_, separator.pointer);
return NSArray.castFromPointer(_ret, retain: true, release: true);
}
/// componentsSeparatedByCharactersInSet:
NSArray componentsSeparatedByCharactersInSet_(NSCharacterSet separator) {
- final _ret = _objc_msgSend_221(this.pointer,
+ final _ret = _objc_msgSend_206(this.pointer,
_sel_componentsSeparatedByCharactersInSet_, separator.pointer);
return NSArray.castFromPointer(_ret, retain: true, release: true);
}
/// stringByTrimmingCharactersInSet:
NSString stringByTrimmingCharactersInSet_(NSCharacterSet set) {
- final _ret = _objc_msgSend_222(
+ final _ret = _objc_msgSend_207(
this.pointer, _sel_stringByTrimmingCharactersInSet_, set.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -1816,7 +1731,7 @@ class NSString extends NSObject {
/// stringByPaddingToLength:withString:startingAtIndex:
NSString stringByPaddingToLength_withString_startingAtIndex_(
int newLength, NSString padString, int padIndex) {
- final _ret = _objc_msgSend_223(
+ final _ret = _objc_msgSend_208(
this.pointer,
_sel_stringByPaddingToLength_withString_startingAtIndex_,
newLength,
@@ -1828,7 +1743,7 @@ class NSString extends NSObject {
/// stringByFoldingWithOptions:locale:
NSString stringByFoldingWithOptions_locale_(
NSStringCompareOptions options, NSLocale? locale) {
- final _ret = _objc_msgSend_224(
+ final _ret = _objc_msgSend_209(
this.pointer,
_sel_stringByFoldingWithOptions_locale_,
options.value,
@@ -1842,7 +1757,7 @@ class NSString extends NSObject {
NSString replacement,
NSStringCompareOptions options,
NSRange searchRange) {
- final _ret = _objc_msgSend_225(
+ final _ret = _objc_msgSend_210(
this.pointer,
_sel_stringByReplacingOccurrencesOfString_withString_options_range_,
target.pointer,
@@ -1855,7 +1770,7 @@ class NSString extends NSObject {
/// stringByReplacingOccurrencesOfString:withString:
NSString stringByReplacingOccurrencesOfString_withString_(
NSString target, NSString replacement) {
- final _ret = _objc_msgSend_226(
+ final _ret = _objc_msgSend_211(
this.pointer,
_sel_stringByReplacingOccurrencesOfString_withString_,
target.pointer,
@@ -1866,7 +1781,7 @@ class NSString extends NSObject {
/// stringByReplacingCharactersInRange:withString:
NSString stringByReplacingCharactersInRange_withString_(
NSRange range, NSString replacement) {
- final _ret = _objc_msgSend_227(
+ final _ret = _objc_msgSend_212(
this.pointer,
_sel_stringByReplacingCharactersInRange_withString_,
range,
@@ -1877,7 +1792,7 @@ class NSString extends NSObject {
/// stringByApplyingTransform:reverse:
NSString? stringByApplyingTransform_reverse_(
NSString transform, bool reverse) {
- final _ret = _objc_msgSend_228(this.pointer,
+ final _ret = _objc_msgSend_213(this.pointer,
_sel_stringByApplyingTransform_reverse_, transform.pointer, reverse);
return _ret.address == 0
? null
@@ -1887,7 +1802,7 @@ class NSString extends NSObject {
/// writeToURL:atomically:encoding:error:
bool writeToURL_atomically_encoding_error_(NSURL url, bool useAuxiliaryFile,
int enc, ffi.Pointer> error) {
- return _objc_msgSend_229(
+ return _objc_msgSend_214(
this.pointer,
_sel_writeToURL_atomically_encoding_error_,
url.pointer,
@@ -1902,7 +1817,7 @@ class NSString extends NSObject {
bool useAuxiliaryFile,
int enc,
ffi.Pointer> error) {
- return _objc_msgSend_230(
+ return _objc_msgSend_215(
this.pointer,
_sel_writeToFile_atomically_encoding_error_,
path.pointer,
@@ -1925,7 +1840,7 @@ class NSString extends NSObject {
/// initWithCharactersNoCopy:length:freeWhenDone:
NSString initWithCharactersNoCopy_length_freeWhenDone_(
ffi.Pointer characters, int length, bool freeBuffer) {
- final _ret = _objc_msgSend_231(
+ final _ret = _objc_msgSend_216(
this.pointer,
_sel_initWithCharactersNoCopy_length_freeWhenDone_,
characters,
@@ -1937,14 +1852,14 @@ class NSString extends NSObject {
/// initWithCharacters:length:
NSString initWithCharacters_length_(
ffi.Pointer characters, int length) {
- final _ret = _objc_msgSend_232(
+ final _ret = _objc_msgSend_217(
this.pointer, _sel_initWithCharacters_length_, characters, length);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUTF8String:
NSString? initWithUTF8String_(ffi.Pointer nullTerminatedCString) {
- final _ret = _objc_msgSend_233(
+ final _ret = _objc_msgSend_218(
this.pointer, _sel_initWithUTF8String_, nullTerminatedCString);
return _ret.address == 0
? null
@@ -1954,21 +1869,21 @@ class NSString extends NSObject {
/// initWithString:
NSString initWithString_(NSString aString) {
final _ret =
- _objc_msgSend_46(this.pointer, _sel_initWithString_, aString.pointer);
+ _objc_msgSend_45(this.pointer, _sel_initWithString_, aString.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// initWithFormat:
NSString initWithFormat_(NSString format) {
final _ret =
- _objc_msgSend_46(this.pointer, _sel_initWithFormat_, format.pointer);
+ _objc_msgSend_45(this.pointer, _sel_initWithFormat_, format.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// initWithFormat:locale:
NSString initWithFormat_locale_(
NSString format, objc.ObjCObjectBase? locale) {
- final _ret = _objc_msgSend_234(this.pointer, _sel_initWithFormat_locale_,
+ final _ret = _objc_msgSend_219(this.pointer, _sel_initWithFormat_locale_,
format.pointer, locale?.pointer ?? ffi.nullptr);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -1978,7 +1893,7 @@ class NSString extends NSObject {
NSString format,
NSString validFormatSpecifiers,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_235(
+ final _ret = _objc_msgSend_220(
this.pointer,
_sel_initWithValidatedFormat_validFormatSpecifiers_error_,
format.pointer,
@@ -1995,7 +1910,7 @@ class NSString extends NSObject {
NSString validFormatSpecifiers,
objc.ObjCObjectBase? locale,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_236(
+ final _ret = _objc_msgSend_221(
this.pointer,
_sel_initWithValidatedFormat_validFormatSpecifiers_locale_error_,
format.pointer,
@@ -2009,7 +1924,7 @@ class NSString extends NSObject {
/// initWithData:encoding:
NSString? initWithData_encoding_(NSData data, int encoding) {
- final _ret = _objc_msgSend_237(
+ final _ret = _objc_msgSend_222(
this.pointer, _sel_initWithData_encoding_, data.pointer, encoding);
return _ret.address == 0
? null
@@ -2019,7 +1934,7 @@ class NSString extends NSObject {
/// initWithBytes:length:encoding:
NSString? initWithBytes_length_encoding_(
ffi.Pointer bytes, int len, int encoding) {
- final _ret = _objc_msgSend_238(this.pointer,
+ final _ret = _objc_msgSend_223(this.pointer,
_sel_initWithBytes_length_encoding_, bytes, len, encoding);
return _ret.address == 0
? null
@@ -2029,7 +1944,7 @@ class NSString extends NSObject {
/// initWithBytesNoCopy:length:encoding:freeWhenDone:
NSString? initWithBytesNoCopy_length_encoding_freeWhenDone_(
ffi.Pointer bytes, int len, int encoding, bool freeBuffer) {
- final _ret = _objc_msgSend_239(
+ final _ret = _objc_msgSend_224(
this.pointer,
_sel_initWithBytesNoCopy_length_encoding_freeWhenDone_,
bytes,
@@ -2049,7 +1964,7 @@ class NSString extends NSObject {
/// stringWithString:
static NSString stringWithString_(NSString string) {
- final _ret = _objc_msgSend_46(
+ final _ret = _objc_msgSend_45(
_class_NSString, _sel_stringWithString_, string.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -2057,7 +1972,7 @@ class NSString extends NSObject {
/// stringWithCharacters:length:
static NSString stringWithCharacters_length_(
ffi.Pointer characters, int length) {
- final _ret = _objc_msgSend_232(
+ final _ret = _objc_msgSend_217(
_class_NSString, _sel_stringWithCharacters_length_, characters, length);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -2065,7 +1980,7 @@ class NSString extends NSObject {
/// stringWithUTF8String:
static NSString? stringWithUTF8String_(
ffi.Pointer nullTerminatedCString) {
- final _ret = _objc_msgSend_233(
+ final _ret = _objc_msgSend_218(
_class_NSString, _sel_stringWithUTF8String_, nullTerminatedCString);
return _ret.address == 0
? null
@@ -2074,14 +1989,14 @@ class NSString extends NSObject {
/// stringWithFormat:
static NSString stringWithFormat_(NSString format) {
- final _ret = _objc_msgSend_46(
+ final _ret = _objc_msgSend_45(
_class_NSString, _sel_stringWithFormat_, format.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// localizedStringWithFormat:
static NSString localizedStringWithFormat_(NSString format) {
- final _ret = _objc_msgSend_46(
+ final _ret = _objc_msgSend_45(
_class_NSString, _sel_localizedStringWithFormat_, format.pointer);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -2091,7 +2006,7 @@ class NSString extends NSObject {
NSString format,
NSString validFormatSpecifiers,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_235(
+ final _ret = _objc_msgSend_220(
_class_NSString,
_sel_stringWithValidatedFormat_validFormatSpecifiers_error_,
format.pointer,
@@ -2108,7 +2023,7 @@ class NSString extends NSObject {
NSString format,
NSString validFormatSpecifiers,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_235(
+ final _ret = _objc_msgSend_220(
_class_NSString,
_sel_localizedStringWithValidatedFormat_validFormatSpecifiers_error_,
format.pointer,
@@ -2122,7 +2037,7 @@ class NSString extends NSObject {
/// initWithCString:encoding:
NSString? initWithCString_encoding_(
ffi.Pointer nullTerminatedCString, int encoding) {
- final _ret = _objc_msgSend_240(this.pointer, _sel_initWithCString_encoding_,
+ final _ret = _objc_msgSend_225(this.pointer, _sel_initWithCString_encoding_,
nullTerminatedCString, encoding);
return _ret.address == 0
? null
@@ -2132,7 +2047,7 @@ class NSString extends NSObject {
/// stringWithCString:encoding:
static NSString? stringWithCString_encoding_(
ffi.Pointer cString, int enc) {
- final _ret = _objc_msgSend_240(
+ final _ret = _objc_msgSend_225(
_class_NSString, _sel_stringWithCString_encoding_, cString, enc);
return _ret.address == 0
? null
@@ -2142,7 +2057,7 @@ class NSString extends NSObject {
/// initWithContentsOfURL:encoding:error:
NSString? initWithContentsOfURL_encoding_error_(
NSURL url, int enc, ffi.Pointer> error) {
- final _ret = _objc_msgSend_241(this.pointer,
+ final _ret = _objc_msgSend_226(this.pointer,
_sel_initWithContentsOfURL_encoding_error_, url.pointer, enc, error);
return _ret.address == 0
? null
@@ -2152,7 +2067,7 @@ class NSString extends NSObject {
/// initWithContentsOfFile:encoding:error:
NSString? initWithContentsOfFile_encoding_error_(
NSString path, int enc, ffi.Pointer> error) {
- final _ret = _objc_msgSend_242(this.pointer,
+ final _ret = _objc_msgSend_227(this.pointer,
_sel_initWithContentsOfFile_encoding_error_, path.pointer, enc, error);
return _ret.address == 0
? null
@@ -2162,7 +2077,7 @@ class NSString extends NSObject {
/// stringWithContentsOfURL:encoding:error:
static NSString? stringWithContentsOfURL_encoding_error_(
NSURL url, int enc, ffi.Pointer> error) {
- final _ret = _objc_msgSend_241(_class_NSString,
+ final _ret = _objc_msgSend_226(_class_NSString,
_sel_stringWithContentsOfURL_encoding_error_, url.pointer, enc, error);
return _ret.address == 0
? null
@@ -2172,7 +2087,7 @@ class NSString extends NSObject {
/// stringWithContentsOfFile:encoding:error:
static NSString? stringWithContentsOfFile_encoding_error_(
NSString path, int enc, ffi.Pointer> error) {
- final _ret = _objc_msgSend_242(
+ final _ret = _objc_msgSend_227(
_class_NSString,
_sel_stringWithContentsOfFile_encoding_error_,
path.pointer,
@@ -2188,7 +2103,7 @@ class NSString extends NSObject {
NSURL url,
ffi.Pointer enc,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_243(
+ final _ret = _objc_msgSend_228(
this.pointer,
_sel_initWithContentsOfURL_usedEncoding_error_,
url.pointer,
@@ -2204,7 +2119,7 @@ class NSString extends NSObject {
NSString path,
ffi.Pointer enc,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_244(
+ final _ret = _objc_msgSend_229(
this.pointer,
_sel_initWithContentsOfFile_usedEncoding_error_,
path.pointer,
@@ -2220,7 +2135,7 @@ class NSString extends NSObject {
NSURL url,
ffi.Pointer enc,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_243(
+ final _ret = _objc_msgSend_228(
_class_NSString,
_sel_stringWithContentsOfURL_usedEncoding_error_,
url.pointer,
@@ -2236,7 +2151,7 @@ class NSString extends NSObject {
NSString path,
ffi.Pointer enc,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_244(
+ final _ret = _objc_msgSend_229(
_class_NSString,
_sel_stringWithContentsOfFile_usedEncoding_error_,
path.pointer,
@@ -2254,7 +2169,7 @@ class NSString extends NSObject {
NSDictionary? opts,
ffi.Pointer> string,
ffi.Pointer usedLossyConversion) {
- return _objc_msgSend_245(
+ return _objc_msgSend_230(
_class_NSString,
_sel_stringEncodingForData_encodingOptions_convertedString_usedLossyConversion_,
data.pointer,
@@ -2272,158 +2187,21 @@ class NSString extends NSObject {
/// propertyListFromStringsFileFormat
NSDictionary? propertyListFromStringsFileFormat() {
final _ret =
- _objc_msgSend_246(this.pointer, _sel_propertyListFromStringsFileFormat);
+ _objc_msgSend_231(this.pointer, _sel_propertyListFromStringsFileFormat);
return _ret.address == 0
? null
: NSDictionary.castFromPointer(_ret, retain: true, release: true);
}
- /// cString
- ffi.Pointer cString() {
- return _objc_msgSend_14(this.pointer, _sel_cString);
- }
-
- /// lossyCString
- ffi.Pointer lossyCString() {
- return _objc_msgSend_14(this.pointer, _sel_lossyCString);
- }
-
- /// cStringLength
- int cStringLength() {
- return _objc_msgSend_11(this.pointer, _sel_cStringLength);
- }
-
- /// getCString:
- void getCString_(ffi.Pointer bytes) {
- _objc_msgSend_247(this.pointer, _sel_getCString_, bytes);
- }
-
- /// getCString:maxLength:
- void getCString_maxLength_(ffi.Pointer bytes, int maxLength) {
- _objc_msgSend_248(
- this.pointer, _sel_getCString_maxLength_, bytes, maxLength);
- }
-
- /// getCString:maxLength:range:remainingRange:
- void getCString_maxLength_range_remainingRange_(ffi.Pointer bytes,
- int maxLength, NSRange aRange, ffi.Pointer leftoverRange) {
- _objc_msgSend_249(
- this.pointer,
- _sel_getCString_maxLength_range_remainingRange_,
- bytes,
- maxLength,
- aRange,
- leftoverRange);
- }
-
- /// writeToFile:atomically:
- bool writeToFile_atomically_(NSString path, bool useAuxiliaryFile) {
- return _objc_msgSend_41(this.pointer, _sel_writeToFile_atomically_,
- path.pointer, useAuxiliaryFile);
- }
-
- /// writeToURL:atomically:
- bool writeToURL_atomically_(NSURL url, bool atomically) {
- return _objc_msgSend_137(
- this.pointer, _sel_writeToURL_atomically_, url.pointer, atomically);
- }
-
- /// initWithContentsOfFile:
- objc.ObjCObjectBase? initWithContentsOfFile_(NSString path) {
- final _ret = _objc_msgSend_53(
- this.pointer, _sel_initWithContentsOfFile_, path.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// initWithContentsOfURL:
- objc.ObjCObjectBase? initWithContentsOfURL_(NSURL url) {
- final _ret = _objc_msgSend_194(
- this.pointer, _sel_initWithContentsOfURL_, url.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// stringWithContentsOfFile:
- static objc.ObjCObjectBase? stringWithContentsOfFile_(NSString path) {
- final _ret = _objc_msgSend_53(
- _class_NSString, _sel_stringWithContentsOfFile_, path.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// stringWithContentsOfURL:
- static objc.ObjCObjectBase? stringWithContentsOfURL_(NSURL url) {
- final _ret = _objc_msgSend_194(
- _class_NSString, _sel_stringWithContentsOfURL_, url.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// initWithCStringNoCopy:length:freeWhenDone:
- objc.ObjCObjectBase? initWithCStringNoCopy_length_freeWhenDone_(
- ffi.Pointer bytes, int length, bool freeBuffer) {
- final _ret = _objc_msgSend_250(
- this.pointer,
- _sel_initWithCStringNoCopy_length_freeWhenDone_,
- bytes,
- length,
- freeBuffer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: false, release: true);
- }
-
- /// initWithCString:length:
- objc.ObjCObjectBase? initWithCString_length_(
- ffi.Pointer bytes, int length) {
- final _ret = _objc_msgSend_240(
- this.pointer, _sel_initWithCString_length_, bytes, length);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// initWithCString:
- objc.ObjCObjectBase? initWithCString_(ffi.Pointer bytes) {
- final _ret = _objc_msgSend_233(this.pointer, _sel_initWithCString_, bytes);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// stringWithCString:length:
- static objc.ObjCObjectBase? stringWithCString_length_(
- ffi.Pointer bytes, int length) {
- final _ret = _objc_msgSend_240(
- _class_NSString, _sel_stringWithCString_length_, bytes, length);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// stringWithCString:
- static objc.ObjCObjectBase? stringWithCString_(ffi.Pointer bytes) {
- final _ret =
- _objc_msgSend_233(_class_NSString, _sel_stringWithCString_, bytes);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
/// getCharacters:
void getCharacters_(ffi.Pointer buffer) {
- _objc_msgSend_251(this.pointer, _sel_getCharacters_, buffer);
+ _objc_msgSend_232(this.pointer, _sel_getCharacters_, buffer);
}
/// stringByAddingPercentEncodingWithAllowedCharacters:
NSString? stringByAddingPercentEncodingWithAllowedCharacters_(
NSCharacterSet allowedCharacters) {
- final _ret = _objc_msgSend_252(
+ final _ret = _objc_msgSend_233(
this.pointer,
_sel_stringByAddingPercentEncodingWithAllowedCharacters_,
allowedCharacters.pointer);
@@ -2435,25 +2213,7 @@ class NSString extends NSObject {
/// stringByRemovingPercentEncoding
NSString? get stringByRemovingPercentEncoding {
final _ret =
- _objc_msgSend_59(this.pointer, _sel_stringByRemovingPercentEncoding);
- return _ret.address == 0
- ? null
- : NSString.castFromPointer(_ret, retain: true, release: true);
- }
-
- /// stringByAddingPercentEscapesUsingEncoding:
- NSString? stringByAddingPercentEscapesUsingEncoding_(int enc) {
- final _ret = _objc_msgSend_253(
- this.pointer, _sel_stringByAddingPercentEscapesUsingEncoding_, enc);
- return _ret.address == 0
- ? null
- : NSString.castFromPointer(_ret, retain: true, release: true);
- }
-
- /// stringByReplacingPercentEscapesUsingEncoding:
- NSString? stringByReplacingPercentEscapesUsingEncoding_(int enc) {
- final _ret = _objc_msgSend_253(
- this.pointer, _sel_stringByReplacingPercentEscapesUsingEncoding_, enc);
+ _objc_msgSend_58(this.pointer, _sel_stringByRemovingPercentEncoding);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -2479,7 +2239,7 @@ class NSString extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSString,
+ final _ret = _objc_msgSend_95(_class_NSString,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -2489,16 +2249,6 @@ class NSString extends NSObject {
return _objc_msgSend_26(_class_NSString,
_sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSString,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSString = objc.getClass("NSString");
@@ -3041,14 +2791,14 @@ class NSCharacterSet extends NSObject {
/// characterSetWithBitmapRepresentation:
static NSCharacterSet characterSetWithBitmapRepresentation_(NSData data) {
- final _ret = _objc_msgSend_201(_class_NSCharacterSet,
+ final _ret = _objc_msgSend_186(_class_NSCharacterSet,
_sel_characterSetWithBitmapRepresentation_, data.pointer);
return NSCharacterSet.castFromPointer(_ret, retain: true, release: true);
}
/// characterSetWithContentsOfFile:
static NSCharacterSet? characterSetWithContentsOfFile_(NSString fName) {
- final _ret = _objc_msgSend_202(_class_NSCharacterSet,
+ final _ret = _objc_msgSend_187(_class_NSCharacterSet,
_sel_characterSetWithContentsOfFile_, fName.pointer);
return _ret.address == 0
? null
@@ -3058,18 +2808,18 @@ class NSCharacterSet extends NSObject {
/// initWithCoder:
NSCharacterSet initWithCoder_(NSCoder coder) {
final _ret =
- _objc_msgSend_203(this.pointer, _sel_initWithCoder_, coder.pointer);
+ _objc_msgSend_188(this.pointer, _sel_initWithCoder_, coder.pointer);
return NSCharacterSet.castFromPointer(_ret, retain: true, release: true);
}
/// characterIsMember:
bool characterIsMember_(int aCharacter) {
- return _objc_msgSend_204(this.pointer, _sel_characterIsMember_, aCharacter);
+ return _objc_msgSend_189(this.pointer, _sel_characterIsMember_, aCharacter);
}
/// bitmapRepresentation
NSData get bitmapRepresentation {
- final _ret = _objc_msgSend_58(this.pointer, _sel_bitmapRepresentation);
+ final _ret = _objc_msgSend_57(this.pointer, _sel_bitmapRepresentation);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
@@ -3081,19 +2831,19 @@ class NSCharacterSet extends NSObject {
/// longCharacterIsMember:
bool longCharacterIsMember_(int theLongChar) {
- return _objc_msgSend_205(
+ return _objc_msgSend_190(
this.pointer, _sel_longCharacterIsMember_, theLongChar);
}
/// isSupersetOfSet:
bool isSupersetOfSet_(NSCharacterSet theOtherSet) {
- return _objc_msgSend_206(
+ return _objc_msgSend_191(
this.pointer, _sel_isSupersetOfSet_, theOtherSet.pointer);
}
/// hasMemberInPlane:
bool hasMemberInPlane_(int thePlane) {
- return _objc_msgSend_207(this.pointer, _sel_hasMemberInPlane_, thePlane);
+ return _objc_msgSend_192(this.pointer, _sel_hasMemberInPlane_, thePlane);
}
/// URLUserAllowedCharacterSet
@@ -3165,7 +2915,7 @@ class NSCharacterSet extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSCharacterSet,
+ final _ret = _objc_msgSend_95(_class_NSCharacterSet,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -3175,16 +2925,6 @@ class NSCharacterSet extends NSObject {
return _objc_msgSend_26(_class_NSCharacterSet,
_sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSCharacterSet,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSCharacterSet = objc.getClass("NSCharacterSet");
@@ -3308,7 +3048,7 @@ class NSData extends NSObject {
/// writeToURL:atomically:
bool writeToURL_atomically_(NSURL url, bool atomically) {
- return _objc_msgSend_137(
+ return _objc_msgSend_134(
this.pointer, _sel_writeToURL_atomically_, url.pointer, atomically);
}
@@ -3317,7 +3057,7 @@ class NSData extends NSObject {
NSString path,
NSDataWritingOptions writeOptionsMask,
ffi.Pointer> errorPtr) {
- return _objc_msgSend_187(this.pointer, _sel_writeToFile_options_error_,
+ return _objc_msgSend_172(this.pointer, _sel_writeToFile_options_error_,
path.pointer, writeOptionsMask.value, errorPtr);
}
@@ -3326,7 +3066,7 @@ class NSData extends NSObject {
NSURL url,
NSDataWritingOptions writeOptionsMask,
ffi.Pointer> errorPtr) {
- return _objc_msgSend_188(this.pointer, _sel_writeToURL_options_error_,
+ return _objc_msgSend_173(this.pointer, _sel_writeToURL_options_error_,
url.pointer, writeOptionsMask.value, errorPtr);
}
@@ -3334,14 +3074,14 @@ class NSData extends NSObject {
void rangeOfData_options_range_(ffi.Pointer stret, NSData dataToFind,
NSDataSearchOptions mask, NSRange searchRange) {
objc.useMsgSendVariants
- ? _objc_msgSend_189Stret(
+ ? _objc_msgSend_174Stret(
stret,
this.pointer,
_sel_rangeOfData_options_range_,
dataToFind.pointer,
mask.value,
searchRange)
- : stret.ref = _objc_msgSend_189(
+ : stret.ref = _objc_msgSend_174(
this.pointer,
_sel_rangeOfData_options_range_,
dataToFind.pointer,
@@ -3357,7 +3097,7 @@ class NSData extends NSObject {
/// dataWithBytes:length:
static NSData dataWithBytes_length_(ffi.Pointer bytes, int length) {
- final _ret = _objc_msgSend_190(
+ final _ret = _objc_msgSend_175(
_class_NSData, _sel_dataWithBytes_length_, bytes, length);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
@@ -3365,7 +3105,7 @@ class NSData extends NSObject {
/// dataWithBytesNoCopy:length:
static NSData dataWithBytesNoCopy_length_(
ffi.Pointer bytes, int length) {
- final _ret = _objc_msgSend_190(
+ final _ret = _objc_msgSend_175(
_class_NSData, _sel_dataWithBytesNoCopy_length_, bytes, length);
return NSData.castFromPointer(_ret, retain: false, release: true);
}
@@ -3373,7 +3113,7 @@ class NSData extends NSObject {
/// dataWithBytesNoCopy:length:freeWhenDone:
static NSData dataWithBytesNoCopy_length_freeWhenDone_(
ffi.Pointer bytes, int length, bool b) {
- final _ret = _objc_msgSend_191(_class_NSData,
+ final _ret = _objc_msgSend_176(_class_NSData,
_sel_dataWithBytesNoCopy_length_freeWhenDone_, bytes, length, b);
return NSData.castFromPointer(_ret, retain: false, release: true);
}
@@ -3383,7 +3123,7 @@ class NSData extends NSObject {
NSString path,
NSDataReadingOptions readOptionsMask,
ffi.Pointer> errorPtr) {
- final _ret = _objc_msgSend_192(
+ final _ret = _objc_msgSend_177(
_class_NSData,
_sel_dataWithContentsOfFile_options_error_,
path.pointer,
@@ -3399,7 +3139,7 @@ class NSData extends NSObject {
NSURL url,
NSDataReadingOptions readOptionsMask,
ffi.Pointer> errorPtr) {
- final _ret = _objc_msgSend_193(
+ final _ret = _objc_msgSend_178(
_class_NSData,
_sel_dataWithContentsOfURL_options_error_,
url.pointer,
@@ -3412,7 +3152,7 @@ class NSData extends NSObject {
/// dataWithContentsOfFile:
static NSData? dataWithContentsOfFile_(NSString path) {
- final _ret = _objc_msgSend_53(
+ final _ret = _objc_msgSend_52(
_class_NSData, _sel_dataWithContentsOfFile_, path.pointer);
return _ret.address == 0
? null
@@ -3421,7 +3161,7 @@ class NSData extends NSObject {
/// dataWithContentsOfURL:
static NSData? dataWithContentsOfURL_(NSURL url) {
- final _ret = _objc_msgSend_194(
+ final _ret = _objc_msgSend_179(
_class_NSData, _sel_dataWithContentsOfURL_, url.pointer);
return _ret.address == 0
? null
@@ -3430,14 +3170,14 @@ class NSData extends NSObject {
/// initWithBytes:length:
NSData initWithBytes_length_(ffi.Pointer bytes, int length) {
- final _ret = _objc_msgSend_190(
+ final _ret = _objc_msgSend_175(
this.pointer, _sel_initWithBytes_length_, bytes, length);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
/// initWithBytesNoCopy:length:
NSData initWithBytesNoCopy_length_(ffi.Pointer bytes, int length) {
- final _ret = _objc_msgSend_190(
+ final _ret = _objc_msgSend_175(
this.pointer, _sel_initWithBytesNoCopy_length_, bytes, length);
return NSData.castFromPointer(_ret, retain: false, release: true);
}
@@ -3445,7 +3185,7 @@ class NSData extends NSObject {
/// initWithBytesNoCopy:length:freeWhenDone:
NSData initWithBytesNoCopy_length_freeWhenDone_(
ffi.Pointer bytes, int length, bool b) {
- final _ret = _objc_msgSend_191(this.pointer,
+ final _ret = _objc_msgSend_176(this.pointer,
_sel_initWithBytesNoCopy_length_freeWhenDone_, bytes, length, b);
return NSData.castFromPointer(_ret, retain: false, release: true);
}
@@ -3455,7 +3195,7 @@ class NSData extends NSObject {
NSString path,
NSDataReadingOptions readOptionsMask,
ffi.Pointer> errorPtr) {
- final _ret = _objc_msgSend_192(
+ final _ret = _objc_msgSend_177(
this.pointer,
_sel_initWithContentsOfFile_options_error_,
path.pointer,
@@ -3471,7 +3211,7 @@ class NSData extends NSObject {
NSURL url,
NSDataReadingOptions readOptionsMask,
ffi.Pointer> errorPtr) {
- final _ret = _objc_msgSend_193(
+ final _ret = _objc_msgSend_178(
this.pointer,
_sel_initWithContentsOfURL_options_error_,
url.pointer,
@@ -3484,7 +3224,7 @@ class NSData extends NSObject {
/// initWithContentsOfFile:
NSData? initWithContentsOfFile_(NSString path) {
- final _ret = _objc_msgSend_53(
+ final _ret = _objc_msgSend_52(
this.pointer, _sel_initWithContentsOfFile_, path.pointer);
return _ret.address == 0
? null
@@ -3493,7 +3233,7 @@ class NSData extends NSObject {
/// initWithContentsOfURL:
NSData? initWithContentsOfURL_(NSURL url) {
- final _ret = _objc_msgSend_194(
+ final _ret = _objc_msgSend_179(
this.pointer, _sel_initWithContentsOfURL_, url.pointer);
return _ret.address == 0
? null
@@ -3503,21 +3243,21 @@ class NSData extends NSObject {
/// initWithData:
NSData initWithData_(NSData data) {
final _ret =
- _objc_msgSend_195(this.pointer, _sel_initWithData_, data.pointer);
+ _objc_msgSend_180(this.pointer, _sel_initWithData_, data.pointer);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
/// dataWithData:
static NSData dataWithData_(NSData data) {
final _ret =
- _objc_msgSend_195(_class_NSData, _sel_dataWithData_, data.pointer);
+ _objc_msgSend_180(_class_NSData, _sel_dataWithData_, data.pointer);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
/// initWithBase64EncodedString:options:
NSData? initWithBase64EncodedString_options_(
NSString base64String, NSDataBase64DecodingOptions options) {
- final _ret = _objc_msgSend_196(
+ final _ret = _objc_msgSend_181(
this.pointer,
_sel_initWithBase64EncodedString_options_,
base64String.pointer,
@@ -3530,7 +3270,7 @@ class NSData extends NSObject {
/// base64EncodedStringWithOptions:
NSString base64EncodedStringWithOptions_(
NSDataBase64EncodingOptions options) {
- final _ret = _objc_msgSend_197(
+ final _ret = _objc_msgSend_182(
this.pointer, _sel_base64EncodedStringWithOptions_, options.value);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
@@ -3538,7 +3278,7 @@ class NSData extends NSObject {
/// initWithBase64EncodedData:options:
NSData? initWithBase64EncodedData_options_(
NSData base64Data, NSDataBase64DecodingOptions options) {
- final _ret = _objc_msgSend_198(
+ final _ret = _objc_msgSend_183(
this.pointer,
_sel_initWithBase64EncodedData_options_,
base64Data.pointer,
@@ -3550,7 +3290,7 @@ class NSData extends NSObject {
/// base64EncodedDataWithOptions:
NSData base64EncodedDataWithOptions_(NSDataBase64EncodingOptions options) {
- final _ret = _objc_msgSend_199(
+ final _ret = _objc_msgSend_184(
this.pointer, _sel_base64EncodedDataWithOptions_, options.value);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
@@ -3559,7 +3299,7 @@ class NSData extends NSObject {
NSData? decompressedDataUsingAlgorithm_error_(
NSDataCompressionAlgorithm algorithm,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_200(this.pointer,
+ final _ret = _objc_msgSend_185(this.pointer,
_sel_decompressedDataUsingAlgorithm_error_, algorithm.value, error);
return _ret.address == 0
? null
@@ -3570,51 +3310,13 @@ class NSData extends NSObject {
NSData? compressedDataUsingAlgorithm_error_(
NSDataCompressionAlgorithm algorithm,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_200(this.pointer,
+ final _ret = _objc_msgSend_185(this.pointer,
_sel_compressedDataUsingAlgorithm_error_, algorithm.value, error);
return _ret.address == 0
? null
: NSData.castFromPointer(_ret, retain: true, release: true);
}
- /// getBytes:
- void getBytes_(ffi.Pointer buffer) {
- _objc_msgSend_93(this.pointer, _sel_getBytes_, buffer);
- }
-
- /// dataWithContentsOfMappedFile:
- static objc.ObjCObjectBase? dataWithContentsOfMappedFile_(NSString path) {
- final _ret = _objc_msgSend_53(
- _class_NSData, _sel_dataWithContentsOfMappedFile_, path.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// initWithContentsOfMappedFile:
- objc.ObjCObjectBase? initWithContentsOfMappedFile_(NSString path) {
- final _ret = _objc_msgSend_53(
- this.pointer, _sel_initWithContentsOfMappedFile_, path.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// initWithBase64Encoding:
- objc.ObjCObjectBase? initWithBase64Encoding_(NSString base64String) {
- final _ret = _objc_msgSend_53(
- this.pointer, _sel_initWithBase64Encoding_, base64String.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// base64Encoding
- NSString base64Encoding() {
- final _ret = _objc_msgSend_36(this.pointer, _sel_base64Encoding);
- return NSString.castFromPointer(_ret, retain: true, release: true);
- }
-
/// init
NSData init() {
final _ret = _objc_msgSend_2(this.pointer, _sel_init);
@@ -3641,7 +3343,7 @@ class NSData extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSData,
+ final _ret = _objc_msgSend_95(_class_NSData,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -3651,16 +3353,6 @@ class NSData extends NSObject {
return _objc_msgSend_26(
_class_NSData, _sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSData,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSData = objc.getClass("NSData");
@@ -3763,20 +3455,10 @@ class NSURL extends NSObject {
return _objc_msgSend_0(obj.pointer, _sel_isKindOfClass_, _class_NSURL);
}
- /// initWithScheme:host:path:
- NSURL? initWithScheme_host_path_(
- NSString scheme, NSString? host, NSString path) {
- final _ret = _objc_msgSend_42(this.pointer, _sel_initWithScheme_host_path_,
- scheme.pointer, host?.pointer ?? ffi.nullptr, path.pointer);
- return _ret.address == 0
- ? null
- : NSURL.castFromPointer(_ret, retain: true, release: true);
- }
-
/// initFileURLWithPath:isDirectory:relativeToURL:
NSURL initFileURLWithPath_isDirectory_relativeToURL_(
NSString path, bool isDir, NSURL? baseURL) {
- final _ret = _objc_msgSend_43(
+ final _ret = _objc_msgSend_42(
this.pointer,
_sel_initFileURLWithPath_isDirectory_relativeToURL_,
path.pointer,
@@ -3787,7 +3469,7 @@ class NSURL extends NSObject {
/// initFileURLWithPath:relativeToURL:
NSURL initFileURLWithPath_relativeToURL_(NSString path, NSURL? baseURL) {
- final _ret = _objc_msgSend_44(
+ final _ret = _objc_msgSend_43(
this.pointer,
_sel_initFileURLWithPath_relativeToURL_,
path.pointer,
@@ -3797,7 +3479,7 @@ class NSURL extends NSObject {
/// initFileURLWithPath:isDirectory:
NSURL initFileURLWithPath_isDirectory_(NSString path, bool isDir) {
- final _ret = _objc_msgSend_45(this.pointer,
+ final _ret = _objc_msgSend_44(this.pointer,
_sel_initFileURLWithPath_isDirectory_, path.pointer, isDir);
return NSURL.castFromPointer(_ret, retain: true, release: true);
}
@@ -3805,14 +3487,14 @@ class NSURL extends NSObject {
/// initFileURLWithPath:
NSURL initFileURLWithPath_(NSString path) {
final _ret =
- _objc_msgSend_46(this.pointer, _sel_initFileURLWithPath_, path.pointer);
+ _objc_msgSend_45(this.pointer, _sel_initFileURLWithPath_, path.pointer);
return NSURL.castFromPointer(_ret, retain: true, release: true);
}
/// fileURLWithPath:isDirectory:relativeToURL:
static NSURL fileURLWithPath_isDirectory_relativeToURL_(
NSString path, bool isDir, NSURL? baseURL) {
- final _ret = _objc_msgSend_47(
+ final _ret = _objc_msgSend_46(
_class_NSURL,
_sel_fileURLWithPath_isDirectory_relativeToURL_,
path.pointer,
@@ -3823,7 +3505,7 @@ class NSURL extends NSObject {
/// fileURLWithPath:relativeToURL:
static NSURL fileURLWithPath_relativeToURL_(NSString path, NSURL? baseURL) {
- final _ret = _objc_msgSend_48(
+ final _ret = _objc_msgSend_47(
_class_NSURL,
_sel_fileURLWithPath_relativeToURL_,
path.pointer,
@@ -3833,7 +3515,7 @@ class NSURL extends NSObject {
/// fileURLWithPath:isDirectory:
static NSURL fileURLWithPath_isDirectory_(NSString path, bool isDir) {
- final _ret = _objc_msgSend_49(
+ final _ret = _objc_msgSend_48(
_class_NSURL, _sel_fileURLWithPath_isDirectory_, path.pointer, isDir);
return NSURL.castFromPointer(_ret, retain: true, release: true);
}
@@ -3841,14 +3523,14 @@ class NSURL extends NSObject {
/// fileURLWithPath:
static NSURL fileURLWithPath_(NSString path) {
final _ret =
- _objc_msgSend_50(_class_NSURL, _sel_fileURLWithPath_, path.pointer);
+ _objc_msgSend_49(_class_NSURL, _sel_fileURLWithPath_, path.pointer);
return NSURL.castFromPointer(_ret, retain: true, release: true);
}
/// initFileURLWithFileSystemRepresentation:isDirectory:relativeToURL:
NSURL initFileURLWithFileSystemRepresentation_isDirectory_relativeToURL_(
ffi.Pointer path, bool isDir, NSURL? baseURL) {
- final _ret = _objc_msgSend_51(
+ final _ret = _objc_msgSend_50(
this.pointer,
_sel_initFileURLWithFileSystemRepresentation_isDirectory_relativeToURL_,
path,
@@ -3860,7 +3542,7 @@ class NSURL extends NSObject {
/// fileURLWithFileSystemRepresentation:isDirectory:relativeToURL:
static NSURL fileURLWithFileSystemRepresentation_isDirectory_relativeToURL_(
ffi.Pointer path, bool isDir, NSURL? baseURL) {
- final _ret = _objc_msgSend_52(
+ final _ret = _objc_msgSend_51(
_class_NSURL,
_sel_fileURLWithFileSystemRepresentation_isDirectory_relativeToURL_,
path,
@@ -3872,7 +3554,7 @@ class NSURL extends NSObject {
/// initWithString:
NSURL? initWithString_(NSString URLString) {
final _ret =
- _objc_msgSend_53(this.pointer, _sel_initWithString_, URLString.pointer);
+ _objc_msgSend_52(this.pointer, _sel_initWithString_, URLString.pointer);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -3880,7 +3562,7 @@ class NSURL extends NSObject {
/// initWithString:relativeToURL:
NSURL? initWithString_relativeToURL_(NSString URLString, NSURL? baseURL) {
- final _ret = _objc_msgSend_54(
+ final _ret = _objc_msgSend_53(
this.pointer,
_sel_initWithString_relativeToURL_,
URLString.pointer,
@@ -3893,7 +3575,7 @@ class NSURL extends NSObject {
/// URLWithString:
static NSURL? URLWithString_(NSString URLString) {
final _ret =
- _objc_msgSend_53(_class_NSURL, _sel_URLWithString_, URLString.pointer);
+ _objc_msgSend_52(_class_NSURL, _sel_URLWithString_, URLString.pointer);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -3902,7 +3584,7 @@ class NSURL extends NSObject {
/// URLWithString:relativeToURL:
static NSURL? URLWithString_relativeToURL_(
NSString URLString, NSURL? baseURL) {
- final _ret = _objc_msgSend_54(
+ final _ret = _objc_msgSend_53(
_class_NSURL,
_sel_URLWithString_relativeToURL_,
URLString.pointer,
@@ -3915,7 +3597,7 @@ class NSURL extends NSObject {
/// initWithString:encodingInvalidCharacters:
NSURL? initWithString_encodingInvalidCharacters_(
NSString URLString, bool encodingInvalidCharacters) {
- final _ret = _objc_msgSend_55(
+ final _ret = _objc_msgSend_54(
this.pointer,
_sel_initWithString_encodingInvalidCharacters_,
URLString.pointer,
@@ -3928,7 +3610,7 @@ class NSURL extends NSObject {
/// URLWithString:encodingInvalidCharacters:
static NSURL? URLWithString_encodingInvalidCharacters_(
NSString URLString, bool encodingInvalidCharacters) {
- final _ret = _objc_msgSend_55(
+ final _ret = _objc_msgSend_54(
_class_NSURL,
_sel_URLWithString_encodingInvalidCharacters_,
URLString.pointer,
@@ -3940,7 +3622,7 @@ class NSURL extends NSObject {
/// initWithDataRepresentation:relativeToURL:
NSURL initWithDataRepresentation_relativeToURL_(NSData data, NSURL? baseURL) {
- final _ret = _objc_msgSend_56(
+ final _ret = _objc_msgSend_55(
this.pointer,
_sel_initWithDataRepresentation_relativeToURL_,
data.pointer,
@@ -3951,7 +3633,7 @@ class NSURL extends NSObject {
/// URLWithDataRepresentation:relativeToURL:
static NSURL URLWithDataRepresentation_relativeToURL_(
NSData data, NSURL? baseURL) {
- final _ret = _objc_msgSend_57(
+ final _ret = _objc_msgSend_56(
_class_NSURL,
_sel_URLWithDataRepresentation_relativeToURL_,
data.pointer,
@@ -3962,7 +3644,7 @@ class NSURL extends NSObject {
/// initAbsoluteURLWithDataRepresentation:relativeToURL:
NSURL initAbsoluteURLWithDataRepresentation_relativeToURL_(
NSData data, NSURL? baseURL) {
- final _ret = _objc_msgSend_56(
+ final _ret = _objc_msgSend_55(
this.pointer,
_sel_initAbsoluteURLWithDataRepresentation_relativeToURL_,
data.pointer,
@@ -3973,7 +3655,7 @@ class NSURL extends NSObject {
/// absoluteURLWithDataRepresentation:relativeToURL:
static NSURL absoluteURLWithDataRepresentation_relativeToURL_(
NSData data, NSURL? baseURL) {
- final _ret = _objc_msgSend_57(
+ final _ret = _objc_msgSend_56(
_class_NSURL,
_sel_absoluteURLWithDataRepresentation_relativeToURL_,
data.pointer,
@@ -3983,13 +3665,13 @@ class NSURL extends NSObject {
/// dataRepresentation
NSData get dataRepresentation {
- final _ret = _objc_msgSend_58(this.pointer, _sel_dataRepresentation);
+ final _ret = _objc_msgSend_57(this.pointer, _sel_dataRepresentation);
return NSData.castFromPointer(_ret, retain: true, release: true);
}
/// absoluteString
NSString? get absoluteString {
- final _ret = _objc_msgSend_59(this.pointer, _sel_absoluteString);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_absoluteString);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4003,7 +3685,7 @@ class NSURL extends NSObject {
/// baseURL
NSURL? get baseURL {
- final _ret = _objc_msgSend_60(this.pointer, _sel_baseURL);
+ final _ret = _objc_msgSend_59(this.pointer, _sel_baseURL);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4011,7 +3693,7 @@ class NSURL extends NSObject {
/// absoluteURL
NSURL? get absoluteURL {
- final _ret = _objc_msgSend_60(this.pointer, _sel_absoluteURL);
+ final _ret = _objc_msgSend_59(this.pointer, _sel_absoluteURL);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4019,7 +3701,7 @@ class NSURL extends NSObject {
/// scheme
NSString? get scheme {
- final _ret = _objc_msgSend_59(this.pointer, _sel_scheme);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_scheme);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4027,7 +3709,7 @@ class NSURL extends NSObject {
/// resourceSpecifier
NSString? get resourceSpecifier {
- final _ret = _objc_msgSend_59(this.pointer, _sel_resourceSpecifier);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_resourceSpecifier);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4035,7 +3717,7 @@ class NSURL extends NSObject {
/// host
NSString? get host {
- final _ret = _objc_msgSend_59(this.pointer, _sel_host);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_host);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4043,7 +3725,7 @@ class NSURL extends NSObject {
/// port
NSNumber? get port {
- final _ret = _objc_msgSend_144(this.pointer, _sel_port);
+ final _ret = _objc_msgSend_96(this.pointer, _sel_port);
return _ret.address == 0
? null
: NSNumber.castFromPointer(_ret, retain: true, release: true);
@@ -4051,7 +3733,7 @@ class NSURL extends NSObject {
/// user
NSString? get user {
- final _ret = _objc_msgSend_59(this.pointer, _sel_user);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_user);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4059,7 +3741,7 @@ class NSURL extends NSObject {
/// password
NSString? get password {
- final _ret = _objc_msgSend_59(this.pointer, _sel_password);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_password);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4067,7 +3749,7 @@ class NSURL extends NSObject {
/// path
NSString? get path {
- final _ret = _objc_msgSend_59(this.pointer, _sel_path);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_path);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4075,7 +3757,7 @@ class NSURL extends NSObject {
/// fragment
NSString? get fragment {
- final _ret = _objc_msgSend_59(this.pointer, _sel_fragment);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_fragment);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4083,7 +3765,7 @@ class NSURL extends NSObject {
/// parameterString
NSString? get parameterString {
- final _ret = _objc_msgSend_59(this.pointer, _sel_parameterString);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_parameterString);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4091,7 +3773,7 @@ class NSURL extends NSObject {
/// query
NSString? get query {
- final _ret = _objc_msgSend_59(this.pointer, _sel_query);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_query);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4099,7 +3781,7 @@ class NSURL extends NSObject {
/// relativePath
NSString? get relativePath {
- final _ret = _objc_msgSend_59(this.pointer, _sel_relativePath);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_relativePath);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4113,7 +3795,7 @@ class NSURL extends NSObject {
/// getFileSystemRepresentation:maxLength:
bool getFileSystemRepresentation_maxLength_(
ffi.Pointer buffer, int maxBufferLength) {
- return _objc_msgSend_145(this.pointer,
+ return _objc_msgSend_97(this.pointer,
_sel_getFileSystemRepresentation_maxLength_, buffer, maxBufferLength);
}
@@ -4129,7 +3811,7 @@ class NSURL extends NSObject {
/// standardizedURL
NSURL? get standardizedURL {
- final _ret = _objc_msgSend_60(this.pointer, _sel_standardizedURL);
+ final _ret = _objc_msgSend_59(this.pointer, _sel_standardizedURL);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4138,7 +3820,7 @@ class NSURL extends NSObject {
/// checkResourceIsReachableAndReturnError:
bool checkResourceIsReachableAndReturnError_(
ffi.Pointer> error) {
- return _objc_msgSend_146(
+ return _objc_msgSend_143(
this.pointer, _sel_checkResourceIsReachableAndReturnError_, error);
}
@@ -4149,7 +3831,7 @@ class NSURL extends NSObject {
/// fileReferenceURL
NSURL? fileReferenceURL() {
- final _ret = _objc_msgSend_60(this.pointer, _sel_fileReferenceURL);
+ final _ret = _objc_msgSend_59(this.pointer, _sel_fileReferenceURL);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4157,7 +3839,7 @@ class NSURL extends NSObject {
/// filePathURL
NSURL? get filePathURL {
- final _ret = _objc_msgSend_60(this.pointer, _sel_filePathURL);
+ final _ret = _objc_msgSend_59(this.pointer, _sel_filePathURL);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4168,14 +3850,14 @@ class NSURL extends NSObject {
ffi.Pointer> value,
NSString key,
ffi.Pointer> error) {
- return _objc_msgSend_147(this.pointer, _sel_getResourceValue_forKey_error_,
+ return _objc_msgSend_144(this.pointer, _sel_getResourceValue_forKey_error_,
value, key.pointer, error);
}
/// resourceValuesForKeys:error:
objc.ObjCObjectBase? resourceValuesForKeys_error_(
NSArray keys, ffi.Pointer> error) {
- final _ret = _objc_msgSend_148(
+ final _ret = _objc_msgSend_145(
this.pointer, _sel_resourceValuesForKeys_error_, keys.pointer, error);
return _ret.address == 0
? null
@@ -4185,20 +3867,20 @@ class NSURL extends NSObject {
/// setResourceValue:forKey:error:
bool setResourceValue_forKey_error_(objc.ObjCObjectBase? value, NSString key,
ffi.Pointer> error) {
- return _objc_msgSend_149(this.pointer, _sel_setResourceValue_forKey_error_,
+ return _objc_msgSend_146(this.pointer, _sel_setResourceValue_forKey_error_,
value?.pointer ?? ffi.nullptr, key.pointer, error);
}
/// setResourceValues:error:
bool setResourceValues_error_(objc.ObjCObjectBase keyedValues,
ffi.Pointer> error) {
- return _objc_msgSend_150(this.pointer, _sel_setResourceValues_error_,
+ return _objc_msgSend_147(this.pointer, _sel_setResourceValues_error_,
keyedValues.pointer, error);
}
/// removeCachedResourceValueForKey:
void removeCachedResourceValueForKey_(NSString key) {
- _objc_msgSend_151(
+ _objc_msgSend_148(
this.pointer, _sel_removeCachedResourceValueForKey_, key.pointer);
}
@@ -4210,7 +3892,7 @@ class NSURL extends NSObject {
/// setTemporaryResourceValue:forKey:
void setTemporaryResourceValue_forKey_(
objc.ObjCObjectBase? value, NSString key) {
- _objc_msgSend_152(this.pointer, _sel_setTemporaryResourceValue_forKey_,
+ _objc_msgSend_149(this.pointer, _sel_setTemporaryResourceValue_forKey_,
value?.pointer ?? ffi.nullptr, key.pointer);
}
@@ -4221,7 +3903,7 @@ class NSURL extends NSObject {
NSArray? keys,
NSURL? relativeURL,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_153(
+ final _ret = _objc_msgSend_150(
this.pointer,
_sel_bookmarkDataWithOptions_includingResourceValuesForKeys_relativeToURL_error_,
options.value,
@@ -4241,7 +3923,7 @@ class NSURL extends NSObject {
NSURL? relativeURL,
ffi.Pointer isStale,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_154(
+ final _ret = _objc_msgSend_151(
this.pointer,
_sel_initByResolvingBookmarkData_options_relativeToURL_bookmarkDataIsStale_error_,
bookmarkData.pointer,
@@ -4262,7 +3944,7 @@ class NSURL extends NSObject {
NSURL? relativeURL,
ffi.Pointer isStale,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_154(
+ final _ret = _objc_msgSend_151(
_class_NSURL,
_sel_URLByResolvingBookmarkData_options_relativeToURL_bookmarkDataIsStale_error_,
bookmarkData.pointer,
@@ -4278,7 +3960,7 @@ class NSURL extends NSObject {
/// resourceValuesForKeys:fromBookmarkData:
static objc.ObjCObjectBase? resourceValuesForKeys_fromBookmarkData_(
NSArray keys, NSData bookmarkData) {
- final _ret = _objc_msgSend_155(
+ final _ret = _objc_msgSend_152(
_class_NSURL,
_sel_resourceValuesForKeys_fromBookmarkData_,
keys.pointer,
@@ -4294,7 +3976,7 @@ class NSURL extends NSObject {
NSURL bookmarkFileURL,
int options,
ffi.Pointer> error) {
- return _objc_msgSend_156(
+ return _objc_msgSend_153(
_class_NSURL,
_sel_writeBookmarkData_toURL_options_error_,
bookmarkData.pointer,
@@ -4306,7 +3988,7 @@ class NSURL extends NSObject {
/// bookmarkDataWithContentsOfURL:error:
static NSData? bookmarkDataWithContentsOfURL_error_(
NSURL bookmarkFileURL, ffi.Pointer> error) {
- final _ret = _objc_msgSend_157(
+ final _ret = _objc_msgSend_154(
_class_NSURL,
_sel_bookmarkDataWithContentsOfURL_error_,
bookmarkFileURL.pointer,
@@ -4321,7 +4003,7 @@ class NSURL extends NSObject {
NSURL url,
NSURLBookmarkResolutionOptions options,
ffi.Pointer> error) {
- final _ret = _objc_msgSend_158(
+ final _ret = _objc_msgSend_155(
_class_NSURL,
_sel_URLByResolvingAliasFileAtURL_options_error_,
url.pointer,
@@ -4348,7 +4030,7 @@ class NSURL extends NSObject {
ffi.Pointer> value,
NSString key,
ffi.Pointer> error) {
- return _objc_msgSend_147(
+ return _objc_msgSend_144(
this.pointer,
_sel_getPromisedItemResourceValue_forKey_error_,
value,
@@ -4359,7 +4041,7 @@ class NSURL extends NSObject {
/// promisedItemResourceValuesForKeys:error:
NSDictionary? promisedItemResourceValuesForKeys_error_(
NSArray keys, ffi.Pointer> error) {
- final _ret = _objc_msgSend_172(this.pointer,
+ final _ret = _objc_msgSend_168(this.pointer,
_sel_promisedItemResourceValuesForKeys_error_, keys.pointer, error);
return _ret.address == 0
? null
@@ -4369,13 +4051,13 @@ class NSURL extends NSObject {
/// checkPromisedItemIsReachableAndReturnError:
bool checkPromisedItemIsReachableAndReturnError_(
ffi.Pointer> error) {
- return _objc_msgSend_146(
+ return _objc_msgSend_143(
this.pointer, _sel_checkPromisedItemIsReachableAndReturnError_, error);
}
/// fileURLWithPathComponents:
static NSURL? fileURLWithPathComponents_(NSArray components) {
- final _ret = _objc_msgSend_173(
+ final _ret = _objc_msgSend_169(
_class_NSURL, _sel_fileURLWithPathComponents_, components.pointer);
return _ret.address == 0
? null
@@ -4384,7 +4066,7 @@ class NSURL extends NSObject {
/// pathComponents
NSArray? get pathComponents {
- final _ret = _objc_msgSend_114(this.pointer, _sel_pathComponents);
+ final _ret = _objc_msgSend_141(this.pointer, _sel_pathComponents);
return _ret.address == 0
? null
: NSArray.castFromPointer(_ret, retain: true, release: true);
@@ -4392,7 +4074,7 @@ class NSURL extends NSObject {
/// lastPathComponent
NSString? get lastPathComponent {
- final _ret = _objc_msgSend_59(this.pointer, _sel_lastPathComponent);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_lastPathComponent);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4400,7 +4082,7 @@ class NSURL extends NSObject {
/// pathExtension
NSString? get pathExtension {
- final _ret = _objc_msgSend_59(this.pointer, _sel_pathExtension);
+ final _ret = _objc_msgSend_58(this.pointer, _sel_pathExtension);
return _ret.address == 0
? null
: NSString.castFromPointer(_ret, retain: true, release: true);
@@ -4408,7 +4090,7 @@ class NSURL extends NSObject {
/// URLByAppendingPathComponent:
NSURL? URLByAppendingPathComponent_(NSString pathComponent) {
- final _ret = _objc_msgSend_174(
+ final _ret = _objc_msgSend_170(
this.pointer, _sel_URLByAppendingPathComponent_, pathComponent.pointer);
return _ret.address == 0
? null
@@ -4418,7 +4100,7 @@ class NSURL extends NSObject {
/// URLByAppendingPathComponent:isDirectory:
NSURL? URLByAppendingPathComponent_isDirectory_(
NSString pathComponent, bool isDirectory) {
- final _ret = _objc_msgSend_175(
+ final _ret = _objc_msgSend_171(
this.pointer,
_sel_URLByAppendingPathComponent_isDirectory_,
pathComponent.pointer,
@@ -4431,7 +4113,7 @@ class NSURL extends NSObject {
/// URLByDeletingLastPathComponent
NSURL? get URLByDeletingLastPathComponent {
final _ret =
- _objc_msgSend_60(this.pointer, _sel_URLByDeletingLastPathComponent);
+ _objc_msgSend_59(this.pointer, _sel_URLByDeletingLastPathComponent);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4439,7 +4121,7 @@ class NSURL extends NSObject {
/// URLByAppendingPathExtension:
NSURL? URLByAppendingPathExtension_(NSString pathExtension) {
- final _ret = _objc_msgSend_174(
+ final _ret = _objc_msgSend_170(
this.pointer, _sel_URLByAppendingPathExtension_, pathExtension.pointer);
return _ret.address == 0
? null
@@ -4449,7 +4131,7 @@ class NSURL extends NSObject {
/// URLByDeletingPathExtension
NSURL? get URLByDeletingPathExtension {
final _ret =
- _objc_msgSend_60(this.pointer, _sel_URLByDeletingPathExtension);
+ _objc_msgSend_59(this.pointer, _sel_URLByDeletingPathExtension);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4457,7 +4139,7 @@ class NSURL extends NSObject {
/// URLByStandardizingPath
NSURL? get URLByStandardizingPath {
- final _ret = _objc_msgSend_60(this.pointer, _sel_URLByStandardizingPath);
+ final _ret = _objc_msgSend_59(this.pointer, _sel_URLByStandardizingPath);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
@@ -4466,60 +4148,12 @@ class NSURL extends NSObject {
/// URLByResolvingSymlinksInPath
NSURL? get URLByResolvingSymlinksInPath {
final _ret =
- _objc_msgSend_60(this.pointer, _sel_URLByResolvingSymlinksInPath);
+ _objc_msgSend_59(this.pointer, _sel_URLByResolvingSymlinksInPath);
return _ret.address == 0
? null
: NSURL.castFromPointer(_ret, retain: true, release: true);
}
- /// resourceDataUsingCache:
- NSData? resourceDataUsingCache_(bool shouldUseCache) {
- final _ret = _objc_msgSend_176(
- this.pointer, _sel_resourceDataUsingCache_, shouldUseCache);
- return _ret.address == 0
- ? null
- : NSData.castFromPointer(_ret, retain: true, release: true);
- }
-
- /// loadResourceDataNotifyingClient:usingCache:
- void loadResourceDataNotifyingClient_usingCache_(
- objc.ObjCObjectBase client, bool shouldUseCache) {
- _objc_msgSend_177(
- this.pointer,
- _sel_loadResourceDataNotifyingClient_usingCache_,
- client.pointer,
- shouldUseCache);
- }
-
- /// propertyForKey:
- objc.ObjCObjectBase? propertyForKey_(NSString propertyKey) {
- final _ret = _objc_msgSend_53(
- this.pointer, _sel_propertyForKey_, propertyKey.pointer);
- return _ret.address == 0
- ? null
- : objc.ObjCObjectBase(_ret, retain: true, release: true);
- }
-
- /// setResourceData:
- bool setResourceData_(NSData data) {
- return _objc_msgSend_39(this.pointer, _sel_setResourceData_, data.pointer);
- }
-
- /// setProperty:forKey:
- bool setProperty_forKey_(objc.ObjCObjectBase property, NSString propertyKey) {
- return _objc_msgSend_178(this.pointer, _sel_setProperty_forKey_,
- property.pointer, propertyKey.pointer);
- }
-
- /// URLHandleUsingCache:
- NSURLHandle? URLHandleUsingCache_(bool shouldUseCache) {
- final _ret = _objc_msgSend_186(
- this.pointer, _sel_URLHandleUsingCache_, shouldUseCache);
- return _ret.address == 0
- ? null
- : NSURLHandle.castFromPointer(_ret, retain: true, release: true);
- }
-
/// init
NSURL init() {
final _ret = _objc_msgSend_2(this.pointer, _sel_init);
@@ -4546,7 +4180,7 @@ class NSURL extends NSObject {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(
+ final _ret = _objc_msgSend_95(
_class_NSURL, _sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -4556,40 +4190,12 @@ class NSURL extends NSObject {
return _objc_msgSend_26(
_class_NSURL, _sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSURL,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSURL = objc.getClass("NSURL");
-late final _sel_initWithScheme_host_path_ =
- objc.registerName("initWithScheme:host:path:");
-final _objc_msgSend_42 = objc.msgSendPointer
- .cast<
- ffi.NativeFunction<
- instancetype Function(
- ffi.Pointer,
- ffi.Pointer,
- ffi.Pointer,
- ffi.Pointer,
- ffi.Pointer)>>()
- .asFunction<
- instancetype Function(
- ffi.Pointer,
- ffi.Pointer,
- ffi.Pointer,
- ffi.Pointer,
- ffi.Pointer)>();
late final _sel_initFileURLWithPath_isDirectory_relativeToURL_ =
objc.registerName("initFileURLWithPath:isDirectory:relativeToURL:");
-final _objc_msgSend_43 = objc.msgSendPointer
+final _objc_msgSend_42 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4607,7 +4213,7 @@ final _objc_msgSend_43 = objc.msgSendPointer
ffi.Pointer)>();
late final _sel_initFileURLWithPath_relativeToURL_ =
objc.registerName("initFileURLWithPath:relativeToURL:");
-final _objc_msgSend_44 = objc.msgSendPointer
+final _objc_msgSend_43 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4623,7 +4229,7 @@ final _objc_msgSend_44 = objc.msgSendPointer
ffi.Pointer)>();
late final _sel_initFileURLWithPath_isDirectory_ =
objc.registerName("initFileURLWithPath:isDirectory:");
-final _objc_msgSend_45 = objc.msgSendPointer
+final _objc_msgSend_44 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4639,7 +4245,7 @@ final _objc_msgSend_45 = objc.msgSendPointer
bool)>();
late final _sel_initFileURLWithPath_ =
objc.registerName("initFileURLWithPath:");
-final _objc_msgSend_46 = objc.msgSendPointer
+final _objc_msgSend_45 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4651,7 +4257,7 @@ final _objc_msgSend_46 = objc.msgSendPointer
ffi.Pointer, ffi.Pointer)>();
late final _sel_fileURLWithPath_isDirectory_relativeToURL_ =
objc.registerName("fileURLWithPath:isDirectory:relativeToURL:");
-final _objc_msgSend_47 = objc.msgSendPointer
+final _objc_msgSend_46 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(
@@ -4669,7 +4275,7 @@ final _objc_msgSend_47 = objc.msgSendPointer
ffi.Pointer)>();
late final _sel_fileURLWithPath_relativeToURL_ =
objc.registerName("fileURLWithPath:relativeToURL:");
-final _objc_msgSend_48 = objc.msgSendPointer
+final _objc_msgSend_47 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(
@@ -4685,7 +4291,7 @@ final _objc_msgSend_48 = objc.msgSendPointer
ffi.Pointer)>();
late final _sel_fileURLWithPath_isDirectory_ =
objc.registerName("fileURLWithPath:isDirectory:");
-final _objc_msgSend_49 = objc.msgSendPointer
+final _objc_msgSend_48 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(
@@ -4700,7 +4306,7 @@ final _objc_msgSend_49 = objc.msgSendPointer
ffi.Pointer,
bool)>();
late final _sel_fileURLWithPath_ = objc.registerName("fileURLWithPath:");
-final _objc_msgSend_50 = objc.msgSendPointer
+final _objc_msgSend_49 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(
@@ -4713,7 +4319,7 @@ final _objc_msgSend_50 = objc.msgSendPointer
late final _sel_initFileURLWithFileSystemRepresentation_isDirectory_relativeToURL_ =
objc.registerName(
"initFileURLWithFileSystemRepresentation:isDirectory:relativeToURL:");
-final _objc_msgSend_51 = objc.msgSendPointer
+final _objc_msgSend_50 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4732,7 +4338,7 @@ final _objc_msgSend_51 = objc.msgSendPointer
late final _sel_fileURLWithFileSystemRepresentation_isDirectory_relativeToURL_ =
objc.registerName(
"fileURLWithFileSystemRepresentation:isDirectory:relativeToURL:");
-final _objc_msgSend_52 = objc.msgSendPointer
+final _objc_msgSend_51 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(
@@ -4749,7 +4355,7 @@ final _objc_msgSend_52 = objc.msgSendPointer
bool,
ffi.Pointer)>();
late final _sel_initWithString_ = objc.registerName("initWithString:");
-final _objc_msgSend_53 = objc.msgSendPointer
+final _objc_msgSend_52 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4761,7 +4367,7 @@ final _objc_msgSend_53 = objc.msgSendPointer
ffi.Pointer, ffi.Pointer)>();
late final _sel_initWithString_relativeToURL_ =
objc.registerName("initWithString:relativeToURL:");
-final _objc_msgSend_54 = objc.msgSendPointer
+final _objc_msgSend_53 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4780,7 +4386,7 @@ late final _sel_URLWithString_relativeToURL_ =
objc.registerName("URLWithString:relativeToURL:");
late final _sel_initWithString_encodingInvalidCharacters_ =
objc.registerName("initWithString:encodingInvalidCharacters:");
-final _objc_msgSend_55 = objc.msgSendPointer
+final _objc_msgSend_54 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4798,7 +4404,7 @@ late final _sel_URLWithString_encodingInvalidCharacters_ =
objc.registerName("URLWithString:encodingInvalidCharacters:");
late final _sel_initWithDataRepresentation_relativeToURL_ =
objc.registerName("initWithDataRepresentation:relativeToURL:");
-final _objc_msgSend_56 = objc.msgSendPointer
+final _objc_msgSend_55 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
instancetype Function(
@@ -4814,7 +4420,7 @@ final _objc_msgSend_56 = objc.msgSendPointer
ffi.Pointer)>();
late final _sel_URLWithDataRepresentation_relativeToURL_ =
objc.registerName("URLWithDataRepresentation:relativeToURL:");
-final _objc_msgSend_57 = objc.msgSendPointer
+final _objc_msgSend_56 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(
@@ -4833,7 +4439,7 @@ late final _sel_initAbsoluteURLWithDataRepresentation_relativeToURL_ =
late final _sel_absoluteURLWithDataRepresentation_relativeToURL_ =
objc.registerName("absoluteURLWithDataRepresentation:relativeToURL:");
late final _sel_dataRepresentation = objc.registerName("dataRepresentation");
-final _objc_msgSend_58 = objc.msgSendPointer
+final _objc_msgSend_57 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -4842,7 +4448,7 @@ final _objc_msgSend_58 = objc.msgSendPointer
ffi.Pointer Function(
ffi.Pointer, ffi.Pointer)>();
late final _sel_absoluteString = objc.registerName("absoluteString");
-final _objc_msgSend_59 = objc.msgSendPointer
+final _objc_msgSend_58 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -4852,7 +4458,7 @@ final _objc_msgSend_59 = objc.msgSendPointer
ffi.Pointer, ffi.Pointer)>();
late final _sel_relativeString = objc.registerName("relativeString");
late final _sel_baseURL = objc.registerName("baseURL");
-final _objc_msgSend_60 = objc.msgSendPointer
+final _objc_msgSend_59 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -4896,133 +4502,133 @@ class NSNumber extends NSValue {
/// initWithChar:
NSNumber initWithChar_(int value) {
- final _ret = _objc_msgSend_61(this.pointer, _sel_initWithChar_, value);
+ final _ret = _objc_msgSend_60(this.pointer, _sel_initWithChar_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUnsignedChar:
NSNumber initWithUnsignedChar_(int value) {
final _ret =
- _objc_msgSend_62(this.pointer, _sel_initWithUnsignedChar_, value);
+ _objc_msgSend_61(this.pointer, _sel_initWithUnsignedChar_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithShort:
NSNumber initWithShort_(int value) {
- final _ret = _objc_msgSend_63(this.pointer, _sel_initWithShort_, value);
+ final _ret = _objc_msgSend_62(this.pointer, _sel_initWithShort_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUnsignedShort:
NSNumber initWithUnsignedShort_(int value) {
final _ret =
- _objc_msgSend_64(this.pointer, _sel_initWithUnsignedShort_, value);
+ _objc_msgSend_63(this.pointer, _sel_initWithUnsignedShort_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithInt:
NSNumber initWithInt_(int value) {
- final _ret = _objc_msgSend_65(this.pointer, _sel_initWithInt_, value);
+ final _ret = _objc_msgSend_64(this.pointer, _sel_initWithInt_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUnsignedInt:
NSNumber initWithUnsignedInt_(int value) {
final _ret =
- _objc_msgSend_66(this.pointer, _sel_initWithUnsignedInt_, value);
+ _objc_msgSend_65(this.pointer, _sel_initWithUnsignedInt_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithLong:
NSNumber initWithLong_(int value) {
- final _ret = _objc_msgSend_67(this.pointer, _sel_initWithLong_, value);
+ final _ret = _objc_msgSend_66(this.pointer, _sel_initWithLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUnsignedLong:
NSNumber initWithUnsignedLong_(int value) {
final _ret =
- _objc_msgSend_68(this.pointer, _sel_initWithUnsignedLong_, value);
+ _objc_msgSend_67(this.pointer, _sel_initWithUnsignedLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithLongLong:
NSNumber initWithLongLong_(int value) {
- final _ret = _objc_msgSend_69(this.pointer, _sel_initWithLongLong_, value);
+ final _ret = _objc_msgSend_68(this.pointer, _sel_initWithLongLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUnsignedLongLong:
NSNumber initWithUnsignedLongLong_(int value) {
final _ret =
- _objc_msgSend_70(this.pointer, _sel_initWithUnsignedLongLong_, value);
+ _objc_msgSend_69(this.pointer, _sel_initWithUnsignedLongLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithFloat:
NSNumber initWithFloat_(double value) {
- final _ret = _objc_msgSend_71(this.pointer, _sel_initWithFloat_, value);
+ final _ret = _objc_msgSend_70(this.pointer, _sel_initWithFloat_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithDouble:
NSNumber initWithDouble_(double value) {
- final _ret = _objc_msgSend_72(this.pointer, _sel_initWithDouble_, value);
+ final _ret = _objc_msgSend_71(this.pointer, _sel_initWithDouble_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithBool:
NSNumber initWithBool_(bool value) {
- final _ret = _objc_msgSend_73(this.pointer, _sel_initWithBool_, value);
+ final _ret = _objc_msgSend_72(this.pointer, _sel_initWithBool_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithInteger:
NSNumber initWithInteger_(int value) {
- final _ret = _objc_msgSend_67(this.pointer, _sel_initWithInteger_, value);
+ final _ret = _objc_msgSend_66(this.pointer, _sel_initWithInteger_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// initWithUnsignedInteger:
NSNumber initWithUnsignedInteger_(int value) {
final _ret =
- _objc_msgSend_68(this.pointer, _sel_initWithUnsignedInteger_, value);
+ _objc_msgSend_67(this.pointer, _sel_initWithUnsignedInteger_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// charValue
int get charValue {
- return _objc_msgSend_74(this.pointer, _sel_charValue);
+ return _objc_msgSend_73(this.pointer, _sel_charValue);
}
/// unsignedCharValue
int get unsignedCharValue {
- return _objc_msgSend_75(this.pointer, _sel_unsignedCharValue);
+ return _objc_msgSend_74(this.pointer, _sel_unsignedCharValue);
}
/// shortValue
int get shortValue {
- return _objc_msgSend_76(this.pointer, _sel_shortValue);
+ return _objc_msgSend_75(this.pointer, _sel_shortValue);
}
/// unsignedShortValue
int get unsignedShortValue {
- return _objc_msgSend_77(this.pointer, _sel_unsignedShortValue);
+ return _objc_msgSend_76(this.pointer, _sel_unsignedShortValue);
}
/// intValue
int get intValue {
- return _objc_msgSend_78(this.pointer, _sel_intValue);
+ return _objc_msgSend_77(this.pointer, _sel_intValue);
}
/// unsignedIntValue
int get unsignedIntValue {
- return _objc_msgSend_79(this.pointer, _sel_unsignedIntValue);
+ return _objc_msgSend_78(this.pointer, _sel_unsignedIntValue);
}
/// longValue
int get longValue {
- return _objc_msgSend_80(this.pointer, _sel_longValue);
+ return _objc_msgSend_79(this.pointer, _sel_longValue);
}
/// unsignedLongValue
@@ -5032,26 +4638,26 @@ class NSNumber extends NSValue {
/// longLongValue
int get longLongValue {
- return _objc_msgSend_81(this.pointer, _sel_longLongValue);
+ return _objc_msgSend_80(this.pointer, _sel_longLongValue);
}
/// unsignedLongLongValue
int get unsignedLongLongValue {
- return _objc_msgSend_82(this.pointer, _sel_unsignedLongLongValue);
+ return _objc_msgSend_81(this.pointer, _sel_unsignedLongLongValue);
}
/// floatValue
double get floatValue {
return objc.useMsgSendVariants
- ? _objc_msgSend_83Fpret(this.pointer, _sel_floatValue)
- : _objc_msgSend_83(this.pointer, _sel_floatValue);
+ ? _objc_msgSend_82Fpret(this.pointer, _sel_floatValue)
+ : _objc_msgSend_82(this.pointer, _sel_floatValue);
}
/// doubleValue
double get doubleValue {
return objc.useMsgSendVariants
- ? _objc_msgSend_84Fpret(this.pointer, _sel_doubleValue)
- : _objc_msgSend_84(this.pointer, _sel_doubleValue);
+ ? _objc_msgSend_83Fpret(this.pointer, _sel_doubleValue)
+ : _objc_msgSend_83(this.pointer, _sel_doubleValue);
}
/// boolValue
@@ -5061,7 +4667,7 @@ class NSNumber extends NSValue {
/// integerValue
int get integerValue {
- return _objc_msgSend_80(this.pointer, _sel_integerValue);
+ return _objc_msgSend_79(this.pointer, _sel_integerValue);
}
/// unsignedIntegerValue
@@ -5078,86 +4684,86 @@ class NSNumber extends NSValue {
/// compare:
NSComparisonResult compare_(NSNumber otherNumber) {
final _ret =
- _objc_msgSend_85(this.pointer, _sel_compare_, otherNumber.pointer);
+ _objc_msgSend_84(this.pointer, _sel_compare_, otherNumber.pointer);
return NSComparisonResult.fromValue(_ret);
}
/// isEqualToNumber:
bool isEqualToNumber_(NSNumber number) {
- return _objc_msgSend_86(
+ return _objc_msgSend_85(
this.pointer, _sel_isEqualToNumber_, number.pointer);
}
/// descriptionWithLocale:
NSString descriptionWithLocale_(objc.ObjCObjectBase? locale) {
- final _ret = _objc_msgSend_87(this.pointer, _sel_descriptionWithLocale_,
+ final _ret = _objc_msgSend_86(this.pointer, _sel_descriptionWithLocale_,
locale?.pointer ?? ffi.nullptr);
return NSString.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithChar:
static NSNumber numberWithChar_(int value) {
- final _ret = _objc_msgSend_61(_class_NSNumber, _sel_numberWithChar_, value);
+ final _ret = _objc_msgSend_60(_class_NSNumber, _sel_numberWithChar_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithUnsignedChar:
static NSNumber numberWithUnsignedChar_(int value) {
final _ret =
- _objc_msgSend_62(_class_NSNumber, _sel_numberWithUnsignedChar_, value);
+ _objc_msgSend_61(_class_NSNumber, _sel_numberWithUnsignedChar_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithShort:
static NSNumber numberWithShort_(int value) {
final _ret =
- _objc_msgSend_63(_class_NSNumber, _sel_numberWithShort_, value);
+ _objc_msgSend_62(_class_NSNumber, _sel_numberWithShort_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithUnsignedShort:
static NSNumber numberWithUnsignedShort_(int value) {
final _ret =
- _objc_msgSend_64(_class_NSNumber, _sel_numberWithUnsignedShort_, value);
+ _objc_msgSend_63(_class_NSNumber, _sel_numberWithUnsignedShort_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithInt:
static NSNumber numberWithInt_(int value) {
- final _ret = _objc_msgSend_65(_class_NSNumber, _sel_numberWithInt_, value);
+ final _ret = _objc_msgSend_64(_class_NSNumber, _sel_numberWithInt_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithUnsignedInt:
static NSNumber numberWithUnsignedInt_(int value) {
final _ret =
- _objc_msgSend_66(_class_NSNumber, _sel_numberWithUnsignedInt_, value);
+ _objc_msgSend_65(_class_NSNumber, _sel_numberWithUnsignedInt_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithLong:
static NSNumber numberWithLong_(int value) {
- final _ret = _objc_msgSend_67(_class_NSNumber, _sel_numberWithLong_, value);
+ final _ret = _objc_msgSend_66(_class_NSNumber, _sel_numberWithLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithUnsignedLong:
static NSNumber numberWithUnsignedLong_(int value) {
final _ret =
- _objc_msgSend_68(_class_NSNumber, _sel_numberWithUnsignedLong_, value);
+ _objc_msgSend_67(_class_NSNumber, _sel_numberWithUnsignedLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithLongLong:
static NSNumber numberWithLongLong_(int value) {
final _ret =
- _objc_msgSend_69(_class_NSNumber, _sel_numberWithLongLong_, value);
+ _objc_msgSend_68(_class_NSNumber, _sel_numberWithLongLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithUnsignedLongLong:
static NSNumber numberWithUnsignedLongLong_(int value) {
- final _ret = _objc_msgSend_70(
+ final _ret = _objc_msgSend_69(
_class_NSNumber, _sel_numberWithUnsignedLongLong_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
@@ -5165,33 +4771,33 @@ class NSNumber extends NSValue {
/// numberWithFloat:
static NSNumber numberWithFloat_(double value) {
final _ret =
- _objc_msgSend_71(_class_NSNumber, _sel_numberWithFloat_, value);
+ _objc_msgSend_70(_class_NSNumber, _sel_numberWithFloat_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithDouble:
static NSNumber numberWithDouble_(double value) {
final _ret =
- _objc_msgSend_72(_class_NSNumber, _sel_numberWithDouble_, value);
+ _objc_msgSend_71(_class_NSNumber, _sel_numberWithDouble_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithBool:
static NSNumber numberWithBool_(bool value) {
- final _ret = _objc_msgSend_73(_class_NSNumber, _sel_numberWithBool_, value);
+ final _ret = _objc_msgSend_72(_class_NSNumber, _sel_numberWithBool_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithInteger:
static NSNumber numberWithInteger_(int value) {
final _ret =
- _objc_msgSend_67(_class_NSNumber, _sel_numberWithInteger_, value);
+ _objc_msgSend_66(_class_NSNumber, _sel_numberWithInteger_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
/// numberWithUnsignedInteger:
static NSNumber numberWithUnsignedInteger_(int value) {
- final _ret = _objc_msgSend_68(
+ final _ret = _objc_msgSend_67(
_class_NSNumber, _sel_numberWithUnsignedInteger_, value);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
@@ -5199,7 +4805,7 @@ class NSNumber extends NSValue {
/// initWithBytes:objCType:
NSNumber initWithBytes_objCType_(
ffi.Pointer value, ffi.Pointer type) {
- final _ret = _objc_msgSend_88(
+ final _ret = _objc_msgSend_87(
this.pointer, _sel_initWithBytes_objCType_, value, type);
return NSNumber.castFromPointer(_ret, retain: true, release: true);
}
@@ -5207,7 +4813,7 @@ class NSNumber extends NSValue {
/// valueWithBytes:objCType:
static NSValue valueWithBytes_objCType_(
ffi.Pointer value, ffi.Pointer type) {
- final _ret = _objc_msgSend_89(
+ final _ret = _objc_msgSend_88(
_class_NSNumber, _sel_valueWithBytes_objCType_, value, type);
return NSValue.castFromPointer(_ret, retain: true, release: true);
}
@@ -5215,14 +4821,14 @@ class NSNumber extends NSValue {
/// value:withObjCType:
static NSValue value_withObjCType_(
ffi.Pointer value, ffi.Pointer type) {
- final _ret = _objc_msgSend_89(
+ final _ret = _objc_msgSend_88(
_class_NSNumber, _sel_value_withObjCType_, value, type);
return NSValue.castFromPointer(_ret, retain: true, release: true);
}
/// valueWithNonretainedObject:
static NSValue valueWithNonretainedObject_(objc.ObjCObjectBase? anObject) {
- final _ret = _objc_msgSend_90(_class_NSNumber,
+ final _ret = _objc_msgSend_89(_class_NSNumber,
_sel_valueWithNonretainedObject_, anObject?.pointer ?? ffi.nullptr);
return NSValue.castFromPointer(_ret, retain: true, release: true);
}
@@ -5230,13 +4836,13 @@ class NSNumber extends NSValue {
/// valueWithPointer:
static NSValue valueWithPointer_(ffi.Pointer pointer) {
final _ret =
- _objc_msgSend_91(_class_NSNumber, _sel_valueWithPointer_, pointer);
+ _objc_msgSend_90(_class_NSNumber, _sel_valueWithPointer_, pointer);
return NSValue.castFromPointer(_ret, retain: true, release: true);
}
/// valueWithRange:
static NSValue valueWithRange_(NSRange range) {
- final _ret = _objc_msgSend_94(_class_NSNumber, _sel_valueWithRange_, range);
+ final _ret = _objc_msgSend_93(_class_NSNumber, _sel_valueWithRange_, range);
return NSValue.castFromPointer(_ret, retain: true, release: true);
}
@@ -5266,7 +4872,7 @@ class NSNumber extends NSValue {
/// keyPathsForValuesAffectingValueForKey:
static NSSet keyPathsForValuesAffectingValueForKey_(NSString key) {
- final _ret = _objc_msgSend_96(_class_NSNumber,
+ final _ret = _objc_msgSend_95(_class_NSNumber,
_sel_keyPathsForValuesAffectingValueForKey_, key.pointer);
return NSSet.castFromPointer(_ret, retain: true, release: true);
}
@@ -5276,21 +4882,11 @@ class NSNumber extends NSValue {
return _objc_msgSend_26(_class_NSNumber,
_sel_automaticallyNotifiesObserversForKey_, key.pointer);
}
-
- /// setKeys:triggerChangeNotificationsForDependentKey:
- static void setKeys_triggerChangeNotificationsForDependentKey_(
- NSArray keys, NSString dependentKey) {
- _objc_msgSend_116(
- _class_NSNumber,
- _sel_setKeys_triggerChangeNotificationsForDependentKey_,
- keys.pointer,
- dependentKey.pointer);
- }
}
late final _class_NSNumber = objc.getClass("NSNumber");
late final _sel_initWithChar_ = objc.registerName("initWithChar:");
-final _objc_msgSend_61 = objc.msgSendPointer
+final _objc_msgSend_60 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5300,7 +4896,7 @@ final _objc_msgSend_61 = objc.msgSendPointer
ffi.Pointer, int)>();
late final _sel_initWithUnsignedChar_ =
objc.registerName("initWithUnsignedChar:");
-final _objc_msgSend_62 = objc.msgSendPointer
+final _objc_msgSend_61 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5309,7 +4905,7 @@ final _objc_msgSend_62 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, int)>();
late final _sel_initWithShort_ = objc.registerName("initWithShort:");
-final _objc_msgSend_63 = objc.msgSendPointer
+final _objc_msgSend_62 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5319,7 +4915,7 @@ final _objc_msgSend_63 = objc.msgSendPointer
ffi.Pointer, int)>();
late final _sel_initWithUnsignedShort_ =
objc.registerName("initWithUnsignedShort:");
-final _objc_msgSend_64 = objc.msgSendPointer
+final _objc_msgSend_63 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5328,7 +4924,7 @@ final _objc_msgSend_64 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, int)>();
late final _sel_initWithInt_ = objc.registerName("initWithInt:");
-final _objc_msgSend_65 = objc.msgSendPointer
+final _objc_msgSend_64 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5338,7 +4934,7 @@ final _objc_msgSend_65 = objc.msgSendPointer
ffi.Pointer, int)>();
late final _sel_initWithUnsignedInt_ =
objc.registerName("initWithUnsignedInt:");
-final _objc_msgSend_66 = objc.msgSendPointer
+final _objc_msgSend_65 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5347,7 +4943,7 @@ final _objc_msgSend_66 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, int)>();
late final _sel_initWithLong_ = objc.registerName("initWithLong:");
-final _objc_msgSend_67 = objc.msgSendPointer
+final _objc_msgSend_66 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5357,7 +4953,7 @@ final _objc_msgSend_67 = objc.msgSendPointer
ffi.Pointer, int)>();
late final _sel_initWithUnsignedLong_ =
objc.registerName("initWithUnsignedLong:");
-final _objc_msgSend_68 = objc.msgSendPointer
+final _objc_msgSend_67 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5366,7 +4962,7 @@ final _objc_msgSend_68 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, int)>();
late final _sel_initWithLongLong_ = objc.registerName("initWithLongLong:");
-final _objc_msgSend_69 = objc.msgSendPointer
+final _objc_msgSend_68 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5376,7 +4972,7 @@ final _objc_msgSend_69 = objc.msgSendPointer
ffi.Pointer, int)>();
late final _sel_initWithUnsignedLongLong_ =
objc.registerName("initWithUnsignedLongLong:");
-final _objc_msgSend_70 = objc.msgSendPointer
+final _objc_msgSend_69 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5385,7 +4981,7 @@ final _objc_msgSend_70 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, int)>();
late final _sel_initWithFloat_ = objc.registerName("initWithFloat:");
-final _objc_msgSend_71 = objc.msgSendPointer
+final _objc_msgSend_70 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5394,7 +4990,7 @@ final _objc_msgSend_71 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, double)>();
late final _sel_initWithDouble_ = objc.registerName("initWithDouble:");
-final _objc_msgSend_72 = objc.msgSendPointer
+final _objc_msgSend_71 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5403,7 +4999,7 @@ final _objc_msgSend_72 = objc.msgSendPointer
ffi.Pointer Function(ffi.Pointer,
ffi.Pointer, double)>();
late final _sel_initWithBool_ = objc.registerName("initWithBool:");
-final _objc_msgSend_73 = objc.msgSendPointer
+final _objc_msgSend_72 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer Function(ffi.Pointer,
@@ -5415,7 +5011,7 @@ late final _sel_initWithInteger_ = objc.registerName("initWithInteger:");
late final _sel_initWithUnsignedInteger_ =
objc.registerName("initWithUnsignedInteger:");
late final _sel_charValue = objc.registerName("charValue");
-final _objc_msgSend_74 = objc.msgSendPointer
+final _objc_msgSend_73 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Char Function(ffi.Pointer