@nstudio/nativescript-compiler 0.0.0-stage → 9.2.0-alpha.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +19 -0
- package/README.md +72 -2
- package/bin/build-dist.mjs +145 -0
- package/bin/ns-compiled-adapter.js +46 -0
- package/bin/ns-compiled-doctor.js +15 -0
- package/bin/ns-compiled-retrace.js +16 -0
- package/bin/ns-compiled-verify.js +15 -0
- package/bin/ns-compiled.js +26 -0
- package/bin/strip-types.js +18 -0
- package/config.d.ts +41 -0
- package/dist/adapters/active.js +59 -0
- package/dist/adapters/first-party.js +12 -0
- package/dist/adapters/framework.js +135 -0
- package/dist/adapters/hooks.js +115 -0
- package/dist/adapters/load.js +188 -0
- package/dist/api/adapter-api.js +2 -0
- package/dist/api/binding-api.js +11 -0
- package/dist/api/elements.js +21 -0
- package/dist/api/ir.js +29 -0
- package/dist/api/listview.js +27 -0
- package/dist/api/rewrite.js +98 -0
- package/dist/api/typescript-internal.d.ts +35 -0
- package/dist/cli/commands/compile-android.cjs +79 -0
- package/dist/cli/commands/compile-doctor.cjs +45 -0
- package/dist/cli/commands/compile-ios.cjs +77 -0
- package/dist/cli/commands/compile-retrace.cjs +40 -0
- package/dist/cli/commands/compile-verify.cjs +73 -0
- package/dist/cli/contracts.cjs +36 -0
- package/dist/cli/runtime.cjs +166 -0
- package/dist/css/css.js +118 -0
- package/dist/css/worker.js +242 -0
- package/dist/driver/cli.js +95 -0
- package/dist/driver/compile.js +571 -0
- package/dist/driver/contract.js +136 -0
- package/dist/driver/mirror.js +71 -0
- package/dist/driver/paths.js +19 -0
- package/dist/driver/preflight.js +206 -0
- package/dist/driver/toolchain.js +46 -0
- package/dist/driver/unimplemented.js +326 -0
- package/dist/kit/core-source.js +107 -0
- package/dist/kit/kit-index.js +105 -0
- package/dist/kit/manifest.js +468 -0
- package/dist/kit/overlay.js +56 -0
- package/dist/kit/swift-declarations.js +643 -0
- package/dist/kotlin/access.js +635 -0
- package/dist/kotlin/app-modules.js +111 -0
- package/dist/kotlin/arguments.js +398 -0
- package/dist/kotlin/assignment.js +226 -0
- package/dist/kotlin/builtins.js +575 -0
- package/dist/kotlin/calls.js +519 -0
- package/dist/kotlin/checked.js +61 -0
- package/dist/kotlin/class-accessors.js +129 -0
- package/dist/kotlin/class-constructor.js +129 -0
- package/dist/kotlin/class-declaration.js +337 -0
- package/dist/kotlin/class-fields.js +362 -0
- package/dist/kotlin/class-methods.js +213 -0
- package/dist/kotlin/classes.js +333 -0
- package/dist/kotlin/components.js +450 -0
- package/dist/kotlin/construction.js +235 -0
- package/dist/kotlin/control-flow.js +188 -0
- package/dist/kotlin/conversion.js +513 -0
- package/dist/kotlin/core-api.js +762 -0
- package/dist/kotlin/core-index.js +228 -0
- package/dist/kotlin/declarations.js +461 -0
- package/dist/kotlin/diagnostics.js +28 -0
- package/dist/kotlin/expression-statements.js +227 -0
- package/dist/kotlin/expressions.js +468 -0
- package/dist/kotlin/functions.js +479 -0
- package/dist/kotlin/global-calls.js +307 -0
- package/dist/kotlin/install.js +89 -0
- package/dist/kotlin/key-plans.js +117 -0
- package/dist/kotlin/kit-gen.js +581 -0
- package/dist/kotlin/ktfmt.js +60 -0
- package/dist/kotlin/library.js +62 -0
- package/dist/kotlin/literals.js +593 -0
- package/dist/kotlin/loops.js +185 -0
- package/dist/kotlin/mixins.js +103 -0
- package/dist/kotlin/modules.js +769 -0
- package/dist/kotlin/names.js +273 -0
- package/dist/kotlin/narrowing.js +180 -0
- package/dist/kotlin/native/api.js +117 -0
- package/dist/kotlin/native/bridging.js +254 -0
- package/dist/kotlin/native/calls.js +408 -0
- package/dist/kotlin/native/classfiles.js +524 -0
- package/dist/kotlin/native/classpath.js +32 -0
- package/dist/kotlin/native/conversions.js +280 -0
- package/dist/kotlin/native/extend.js +302 -0
- package/dist/kotlin/native/members.js +240 -0
- package/dist/kotlin/native/overloads.js +253 -0
- package/dist/kotlin/native/subclasses.js +378 -0
- package/dist/kotlin/native/types.js +421 -0
- package/dist/kotlin/operators.js +449 -0
- package/dist/kotlin/optional-chains.js +279 -0
- package/dist/kotlin/overrides.js +835 -0
- package/dist/kotlin/placement.js +749 -0
- package/dist/kotlin/prototype-calls.js +154 -0
- package/dist/kotlin/render.js +363 -0
- package/dist/kotlin/state-backend.js +123 -0
- package/dist/kotlin/statements.js +426 -0
- package/dist/kotlin/static-calls.js +296 -0
- package/dist/kotlin/syntax.js +689 -0
- package/dist/kotlin/translator-types.js +1 -0
- package/dist/kotlin/translator.js +810 -0
- package/dist/kotlin/type-facts.js +414 -0
- package/dist/kotlin/type-tests.js +250 -0
- package/dist/kotlin/types.js +662 -0
- package/dist/kotlin/untyped-values.js +356 -0
- package/dist/plugins/bindings-android.js +69 -0
- package/dist/plugins/bindings.js +93 -0
- package/dist/plugins/native-android.js +582 -0
- package/dist/plugins/native-ios.js +632 -0
- package/dist/plugins/resolve.js +108 -0
- package/dist/plugins/source.js +1124 -0
- package/dist/program/app-modules.js +52 -0
- package/dist/program/app-paths.js +60 -0
- package/dist/program/build-caches.js +14 -0
- package/dist/program/build-context.js +48 -0
- package/dist/program/constructor-factories.js +134 -0
- package/dist/program/core-facts.js +151 -0
- package/dist/program/core-patches.js +59 -0
- package/dist/program/env.js +4 -0
- package/dist/program/module-order.js +123 -0
- package/dist/program/order.js +23 -0
- package/dist/program/patterns.js +99 -0
- package/dist/program/platform.js +401 -0
- package/dist/program/program.js +726 -0
- package/dist/program/properties.js +61 -0
- package/dist/program/reach.js +444 -0
- package/dist/program/source-lines.js +268 -0
- package/dist/program/stable-names.js +112 -0
- package/dist/semantics/apis/api.js +31 -0
- package/dist/semantics/apis/array.js +69 -0
- package/dist/semantics/apis/bigint.js +53 -0
- package/dist/semantics/apis/console.js +29 -0
- package/dist/semantics/apis/date.js +7 -0
- package/dist/semantics/apis/globals.js +40 -0
- package/dist/semantics/apis/json.js +6 -0
- package/dist/semantics/apis/mapset.js +21 -0
- package/dist/semantics/apis/math.js +48 -0
- package/dist/semantics/apis/number.js +33 -0
- package/dist/semantics/apis/object.js +25 -0
- package/dist/semantics/apis/operators.js +316 -0
- package/dist/semantics/apis/promise.js +22 -0
- package/dist/semantics/apis/regexp.js +15 -0
- package/dist/semantics/apis/statics.js +61 -0
- package/dist/semantics/apis/string.js +45 -0
- package/dist/semantics/ast.js +315 -0
- package/dist/semantics/async.js +582 -0
- package/dist/semantics/class-plan.js +168 -0
- package/dist/semantics/classes.js +562 -0
- package/dist/semantics/config.js +29 -0
- package/dist/semantics/constant-init.js +107 -0
- package/dist/semantics/conversion.js +255 -0
- package/dist/semantics/decision-trace.js +304 -0
- package/dist/semantics/facts.js +433 -0
- package/dist/semantics/forms/by-name.js +338 -0
- package/dist/semantics/forms/flow.js +336 -0
- package/dist/semantics/forms/forms.js +311 -0
- package/dist/semantics/forms/observers.js +513 -0
- package/dist/semantics/forms/open.js +218 -0
- package/dist/semantics/forms/place-calls.js +387 -0
- package/dist/semantics/forms/placements.js +296 -0
- package/dist/semantics/forms/results.js +307 -0
- package/dist/semantics/forms/union-find.js +157 -0
- package/dist/semantics/globals.js +46 -0
- package/dist/semantics/lang/arrays.js +238 -0
- package/dist/semantics/lang/fields.js +211 -0
- package/dist/semantics/lang/members.js +277 -0
- package/dist/semantics/lang/prototypes.js +262 -0
- package/dist/semantics/lang/this-args.js +189 -0
- package/dist/semantics/lang.js +232 -0
- package/dist/semantics/ledger.js +157 -0
- package/dist/semantics/limits.js +11 -0
- package/dist/semantics/losses.js +201 -0
- package/dist/semantics/lowering-methods.js +42 -0
- package/dist/semantics/marks.js +39 -0
- package/dist/semantics/nullish.js +918 -0
- package/dist/semantics/observers.js +1 -0
- package/dist/semantics/placement.js +698 -0
- package/dist/semantics/platform-globals.js +20 -0
- package/dist/semantics/read-sites.js +29 -0
- package/dist/semantics/refusals.js +206 -0
- package/dist/semantics/refuse-construction.js +64 -0
- package/dist/semantics/refuse-receivers.js +189 -0
- package/dist/semantics/refuse-scope.js +82 -0
- package/dist/semantics/regexp.js +219 -0
- package/dist/semantics/result-shapes.js +203 -0
- package/dist/semantics/runtime.js +482 -0
- package/dist/semantics/shape-defined-keys.js +146 -0
- package/dist/semantics/shape-instance-keys.js +230 -0
- package/dist/semantics/shape-map.js +72 -0
- package/dist/semantics/shapes.js +660 -0
- package/dist/semantics/sharing.js +406 -0
- package/dist/semantics/signals.js +166 -0
- package/dist/semantics/spelled.js +45 -0
- package/dist/semantics/states/by-name.js +46 -0
- package/dist/semantics/states/elements.js +310 -0
- package/dist/semantics/states/fields.js +308 -0
- package/dist/semantics/states/foreign.js +208 -0
- package/dist/semantics/states/lenient.js +246 -0
- package/dist/semantics/states/missing.js +289 -0
- package/dist/semantics/states/nil.js +223 -0
- package/dist/semantics/states/parameters.js +191 -0
- package/dist/semantics/states/predicates.js +232 -0
- package/dist/semantics/states/reads.js +247 -0
- package/dist/semantics/states/results.js +113 -0
- package/dist/semantics/states/untrusted.js +141 -0
- package/dist/semantics/states/untyped.js +194 -0
- package/dist/semantics/states/value-states.js +422 -0
- package/dist/semantics/tdz.js +106 -0
- package/dist/semantics/threading.js +77 -0
- package/dist/semantics/throws.js +880 -0
- package/dist/semantics/top-names.js +59 -0
- package/dist/semantics/translator-methods.js +602 -0
- package/dist/semantics/trust.js +321 -0
- package/dist/semantics/type-methods.js +168 -0
- package/dist/semantics/type-step.js +116 -0
- package/dist/semantics/types.js +458 -0
- package/dist/semantics/worker-state.js +198 -0
- package/dist/swift/access.js +754 -0
- package/dist/swift/app-modules.js +41 -0
- package/dist/swift/arguments.js +237 -0
- package/dist/swift/assignment.js +270 -0
- package/dist/swift/availability.js +146 -0
- package/dist/swift/builtins.js +822 -0
- package/dist/swift/calls.js +493 -0
- package/dist/swift/casts.js +218 -0
- package/dist/swift/checked.js +433 -0
- package/dist/swift/class-accessors.js +139 -0
- package/dist/swift/class-constructor.js +144 -0
- package/dist/swift/class-declaration.js +308 -0
- package/dist/swift/class-fields.js +361 -0
- package/dist/swift/class-methods.js +247 -0
- package/dist/swift/classes.js +524 -0
- package/dist/swift/components.js +386 -0
- package/dist/swift/construction.js +291 -0
- package/dist/swift/control-flow.js +210 -0
- package/dist/swift/conversion.js +425 -0
- package/dist/swift/core-api.js +1068 -0
- package/dist/swift/declarations.js +389 -0
- package/dist/swift/enums.js +58 -0
- package/dist/swift/expression-statements.js +312 -0
- package/dist/swift/expressions.js +575 -0
- package/dist/swift/from-any.js +316 -0
- package/dist/swift/functions.js +498 -0
- package/dist/swift/generics.js +124 -0
- package/dist/swift/global-calls.js +217 -0
- package/dist/swift/install.js +109 -0
- package/dist/swift/key-plans.js +136 -0
- package/dist/swift/kit-gen.js +605 -0
- package/dist/swift/lenient.js +468 -0
- package/dist/swift/library.js +109 -0
- package/dist/swift/literals.js +509 -0
- package/dist/swift/loops.js +245 -0
- package/dist/swift/marks.js +212 -0
- package/dist/swift/members.js +253 -0
- package/dist/swift/method-values.js +179 -0
- package/dist/swift/mixins.js +113 -0
- package/dist/swift/modules.js +969 -0
- package/dist/swift/names.js +370 -0
- package/dist/swift/narrowing.js +170 -0
- package/dist/swift/native/api.js +269 -0
- package/dist/swift/native/bridging.js +240 -0
- package/dist/swift/native/calls.js +586 -0
- package/dist/swift/native/conversions.js +532 -0
- package/dist/swift/native/dispatch.js +218 -0
- package/dist/swift/native/members.js +416 -0
- package/dist/swift/native/sdk-tables.js +772 -0
- package/dist/swift/native/sdk-types.js +1 -0
- package/dist/swift/native/sdk.js +409 -0
- package/dist/swift/native/subclasses.js +533 -0
- package/dist/swift/object-classes.js +396 -0
- package/dist/swift/operators.js +575 -0
- package/dist/swift/optional-chains.js +405 -0
- package/dist/swift/parameters.js +210 -0
- package/dist/swift/placement.js +900 -0
- package/dist/swift/protocols.js +164 -0
- package/dist/swift/prototype-calls.js +227 -0
- package/dist/swift/render.js +385 -0
- package/dist/swift/results.js +370 -0
- package/dist/swift/state-backend.js +243 -0
- package/dist/swift/statements.js +505 -0
- package/dist/swift/static-calls.js +320 -0
- package/dist/swift/syntax.js +916 -0
- package/dist/swift/translator-types.js +1 -0
- package/dist/swift/translator.js +890 -0
- package/dist/swift/type-facts.js +530 -0
- package/dist/swift/type-tests.js +211 -0
- package/dist/swift/types.js +665 -0
- package/dist/targets/android/build.js +598 -0
- package/dist/targets/android/compose-mapping.js +218 -0
- package/dist/targets/android/deprecations.js +81 -0
- package/dist/targets/android/resources.js +80 -0
- package/dist/targets/ios/build.js +583 -0
- package/dist/targets/ios/core-native.js +149 -0
- package/dist/targets/ios/dependencies.js +464 -0
- package/dist/targets/ios/plist.js +127 -0
- package/dist/targets/ios/resources.js +285 -0
- package/dist/targets/ios/retrace.js +196 -0
- package/dist/targets/ios/signing.js +84 -0
- package/dist/targets/ios/xcodegen.js +39 -0
- package/dist/targets/resources.js +180 -0
- package/dist/template/model.js +38 -0
- package/dist/template/plan.js +576 -0
- package/dist/tools/doctor.js +172 -0
- package/dist/tools/retrace.js +116 -0
- package/dist/tools/verify.js +330 -0
- package/dist/types/adapter-api.d.ts +683 -0
- package/dist/types/binding-api.d.ts +48 -0
- package/dist/types/elements.d.ts +10 -0
- package/dist/types/ir.d.ts +245 -0
- package/dist/types/listview.d.ts +15 -0
- package/dist/types/rewrite.d.ts +18 -0
- package/dist/types/typescript-internal.d.ts +35 -0
- package/dist/xml/app.js +65 -0
- package/dist/xml/bindings.js +308 -0
- package/dist/xml/contexts.js +296 -0
- package/dist/xml/fold.js +170 -0
- package/dist/xml/keys.js +146 -0
- package/dist/xml/pages.js +550 -0
- package/dist/xml/plan.js +650 -0
- package/docs/CLI.md +131 -0
- package/docs/cli/compile-android.md +30 -0
- package/docs/cli/compile-doctor.md +18 -0
- package/docs/cli/compile-ios.md +30 -0
- package/docs/cli/compile-retrace.md +18 -0
- package/docs/cli/compile-verify.md +18 -0
- package/docs/cli/compile.md +15 -0
- package/kit-android/build.gradle.kts +65 -0
- package/kit-android/consumer-rules.pro +7 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/__Exports.kt +966 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/__Modules.kt +125 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/__Objects.kt +39497 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/abortcontroller_abortsignal.kt +101 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/abortcontroller_index.kt +109 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/accessibility_accessibility_common.kt +547 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/accessibility_accessibility_properties.kt +263 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/accessibility_index.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_application.kt +2656 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_application_common.kt +1932 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_application_interfaces.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_application_shims.kt +111 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_helpers.kt +198 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_helpers_common.kt +270 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_index.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_scene_delegate_bridge.kt +233 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_settings_application_settings_common.kt +28 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/application_settings_index.kt +188 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/color_color_common.kt +707 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/color_color_types.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/color_color_utils.kt +368 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/color_index.kt +37 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/color_known_colors.kt +418 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/com.tns.FragmentClass.kt +287 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/com.tns.NativeScriptActivity.kt +263 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/com.tns.OnBackPressedCallback.kt +116 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/connectivity_index.kt +289 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/core_types_animation_types.kt +56 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/core_types_index.kt +427 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/core_types_validators.kt +34 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/css_CSS3Parser.kt +954 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/css_CSSNativeScript.kt +205 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/css_mediaquery_index.kt +270 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/css_parser.kt +885 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/css_system_classes.kt +98 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/css_value_reworkcss_value.kt +214 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/data_observable_array_index.kt +798 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/data_observable_index.kt +1175 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/data_virtual_array_index.kt +271 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/file_system_file_system_access.kt +3828 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/file_system_index.kt +1669 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/fps_meter_fps_native.kt +177 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/fps_meter_index.kt +93 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/globals_global_utils.kt +185 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/http_http_interfaces.kt +14 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/http_http_request_http_request_common.kt +41 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/http_http_request_index.kt +119 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/http_http_request_internal_http_request_internal_common.kt +61 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/http_http_request_internal_index.kt +237 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/http_index.kt +155 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/image_asset_image_asset_common.kt +201 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/image_asset_index.kt +119 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/image_source_image_source_common.kt +26 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/image_source_index.kt +846 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/js_libs_easysax_easysax.kt +1045 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/matrix_index.kt +166 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/media_query_list_index.kt +391 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/module_name_resolver_helpers.kt +45 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/module_name_resolver_index.kt +185 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/module_name_resolver_non_bundle_workflow_compat.kt +262 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/module_name_resolver_qualifier_matcher_index.kt +305 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/native_window_index.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/native_window_native_window.kt +397 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/native_window_native_window_common.kt +685 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/native_window_native_window_interfaces.kt +51 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/native_window_window_base.kt +223 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/npm_css_what_src_index.kt +4 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/npm_css_what_src_parse.kt +755 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/npm_css_what_src_stringify.kt +212 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/npm_css_what_src_types.kt +65 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/org.nativescript.NativeScriptComponentCallbacks.kt +57 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/org.nativescript.NativeScriptLifecycleCallbacks.kt +579 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/platform_common.kt +20 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/platform_device_index.kt +251 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/platform_index.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/platform_screen_index.kt +183 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/profiling_index.kt +485 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/text_formatted_string.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/text_index.kt +15 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/text_span.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/text_text_common.kt +277 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/trace_index.kt +480 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_action_bar_action_bar_common.kt +1081 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_action_bar_index.kt +1207 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_activity_indicator_activity_indicator_common.kt +89 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_activity_indicator_index.kt +171 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_animation_common.kt +518 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_animation_shared.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_animation_types.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_index.kt +1539 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_keyframe_animation.kt +1081 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_builder_binding_builder.kt +369 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_builder_component_builder_index.kt +487 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_builder_index.kt +1938 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_button_button_common.kt +70 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_button_index.kt +367 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_content_view_index.kt +220 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_bindable_bindable_expressions.kt +735 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_bindable_bindable_resources.kt +17 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_bindable_bindable_types.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_bindable_expression_parser.kt +4970 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_bindable_index.kt +1342 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_control_state_change_index.kt +52 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_properties_index.kt +3578 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_properties_property_shared.kt +44 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_base_index.kt +3261 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_base_utils.kt +16 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_index.kt +4716 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_overflow_edges.kt +82 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_view_common.kt +3597 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_view_helper_index.kt +134 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_view_helper_view_helper_common.kt +360 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_view_helper_view_helper_shared.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_view_interfaces.kt +349 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_weak_event_listener_index.kt +266 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_date_picker_date_picker_common.kt +369 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_date_picker_index.kt +427 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_dialogs_dialogs_common.kt +428 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_dialogs_index.kt +689 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_editable_text_base_editable_text_base_common.kt +421 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_editable_text_base_index.kt +1140 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_embedding_index.kt +34 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_enums_enums.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_enums_index.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_activity.kt +210 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_fragment.kt +88 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_fragment_transitions.kt +1544 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_fragment_transitions_types.kt +25 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_common.kt +1350 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_constants.kt +10 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_helper_for_android.kt +615 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_helpers.kt +42 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_interfaces.kt +22 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_stack.kt +112 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_index.kt +1890 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_gestures_gestures_common.kt +208 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_gestures_gestures_types.kt +348 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_gestures_index.kt +1785 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_gestures_touch_manager.kt +288 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_html_view_html_view_common.kt +121 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_html_view_index.kt +283 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_image_cache_image_cache_common.kt +450 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_image_cache_index.kt +225 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_image_image_common.kt +574 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_image_index.kt +493 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_image_symbol_effects.kt +31 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_image_symbol_effects_common.kt +138 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_label_index.kt +108 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_absolute_layout_absolute_layout_common.kt +167 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_absolute_layout_index.kt +94 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_dock_layout_dock_layout_common.kt +157 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_dock_layout_index.kt +124 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_flexbox_layout_flexbox_layout_common.kt +1004 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_flexbox_layout_index.kt +675 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_grid_layout_grid_layout_common.kt +1011 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_grid_layout_index.kt +450 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_index.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_layout_base.kt +123 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_layout_base_common.kt +442 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_liquid_glass_container_index.kt +25 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_liquid_glass_container_liquid_glass_container_common.kt +38 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_liquid_glass_index.kt +30 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_liquid_glass_liquid_glass_common.kt +25 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_root_layout_index.kt +556 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_root_layout_root_layout_common.kt +930 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_root_layout_root_layout_stack.kt +49 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_stack_layout_index.kt +63 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_stack_layout_stack_layout_common.kt +83 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_wrap_layout_index.kt +106 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_wrap_layout_wrap_layout_common.kt +185 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_list_picker_index.kt +400 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_list_picker_list_picker_common.kt +260 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_list_view_index.kt +2406 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_list_view_list_view_common.kt +912 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_page_events.kt +17 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_page_index.kt +241 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_page_page_common.kt +449 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_placeholder_index.kt +61 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_placeholder_placeholder_common.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_progress_index.kt +204 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_progress_progress_common.kt +129 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_proxy_view_container_index.kt +457 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_repeater_index.kt +523 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_scroll_view_index.kt +400 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_scroll_view_scroll_view_common.kt +402 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_search_bar_index.kt +711 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_search_bar_search_bar_common.kt +186 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_segmented_bar_index.kt +774 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_segmented_bar_segmented_bar_common.kt +409 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_slider_index.kt +477 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_slider_slider_common.kt +234 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_split_view_index.kt +25 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_split_view_split_view_common.kt +446 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_background.kt +268 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_background_common.kt +771 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_box_shadow.kt +108 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_clip_path_function.kt +129 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_converters.kt +92 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_css_animation_parser.kt +416 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_css_selector.kt +3532 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_css_shadow.kt +38 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_css_stroke.kt +30 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_css_transform.kt +366 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_css_utils.kt +249 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_font.kt +488 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_font_common.kt +446 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_font_interfaces.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_length_shared.kt +264 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_linear_gradient.kt +136 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_style_index.kt +1345 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_style_properties.kt +2907 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_style_scope.kt +3031 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_styling_profile.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_styling_styling_shared.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_switch_index.kt +295 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_switch_switch_common.kt +139 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_tab_view_index.kt +1977 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_tab_view_tab_view_common.kt +902 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_base_formatted_string.kt +471 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_base_index.kt +1662 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_base_span.kt +284 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_base_text_base_common.kt +792 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_field_index.kt +211 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_field_text_field_common.kt +115 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_view_index.kt +94 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_view_text_view_common.kt +140 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_time_picker_index.kt +225 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_time_picker_time_picker_common.kt +699 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_fade_transition.kt +68 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_flip_transition.kt +209 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_index.kt +160 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_modal_transition.kt +49 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_page_transition.kt +416 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_shared_transition.kt +457 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_shared_transition_helper.kt +46 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_slide_transition.kt +294 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_utils.kt +20 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_web_view_index.kt +595 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_web_view_web_view_common.kt +209 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_web_view_web_view_interfaces.kt +6 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_animation_helpers.kt +76 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_common.kt +224 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_constants.kt +22 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_debug.kt +9 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_debug_source.kt +246 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_index.kt +296 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_layout_helper_index.kt +139 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_layout_helper_layout_helper_common.kt +61 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_layout_helper_layout_helper_shared.kt +23 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_lazy.kt +20 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_macrotask_scheduler.kt +45 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_mainthread_helper.kt +64 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_module_merge.kt +13 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_native_helper.kt +79 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_native_helper_for_android.kt +805 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_number_utils.kt +66 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_platform_check.kt +15 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_shared.kt +65 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_types.kt +229 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_utils_shared.kt +16 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/xml_index.kt +869 -0
- package/kit-android/generated/manifest.json +860 -0
- package/kit-android/generated/source-lines.json +1 -0
- package/kit-android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/kit-android/gradle/wrapper/gradle-wrapper.properties +6 -0
- package/kit-android/gradlew +240 -0
- package/kit-android/overlays/xml-free/kotlin/org/nativescript/kit/ui_builder_index.kt +524 -0
- package/kit-android/overlays/xml-free/kotlin/org/nativescript/kit/ui_core_bindable_index.kt +1335 -0
- package/kit-android/overlays/xml-free/overlay.json +20 -0
- package/kit-android/src/fromcore/kotlin/org/nativescript/kit/AnimationFrame.kt +68 -0
- package/kit-android/src/fromcore/kotlin/org/nativescript/kit/CoreBridge.kt +302 -0
- package/kit-android/src/fromcore/kotlin/org/nativescript/kit/Modal.kt +61 -0
- package/kit-android/src/fromcore/kotlin/org/nativescript/kit/NativeScriptApplication.kt +230 -0
- package/kit-android/src/fromcore/kotlin/org/nativescript/kit/Regions.kt +289 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/ChangeDetection.kt +28 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/ColorMix.kt +643 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/JS.kt +10 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/MainThread.kt +10 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/Signals.kt +866 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/UncaughtErrors.kt +51 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Array.kt +731 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/ArrayLike.kt +781 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/BigInt.kt +136 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/CSSCalc.kt +109 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Collections.kt +426 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/CorePackages.kt +13 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Date.kt +573 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Dynamic.kt +689 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/ES2023.kt +93 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/ErrorOrigin.kt +17 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Errors.kt +270 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/HostObjects.kt +72 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Inspect.kt +814 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Intl.kt +702 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Iterators.kt +746 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/JSON.kt +587 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Language.kt +526 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Lowering.kt +70 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Number.kt +367 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Promise.kt +680 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Prototypes.kt +292 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Reactive.kt +36 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Realm.kt +85 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/RegExp.kt +2245 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/ShortestDouble.kt +157 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Strings.kt +398 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/ThrownValue.kt +34 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Timers.kt +182 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/TypedArrays.kt +993 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/URI.kt +74 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Values.kt +1263 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Views.kt +52 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Weak.kt +110 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/WinterTC.kt +356 -0
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Workers.kt +312 -0
- package/kit-apple/Overlays/xml-free/Core/ui.builder.index.swift +536 -0
- package/kit-apple/Overlays/xml-free/Core/ui.core.bindable.index.swift +1375 -0
- package/kit-apple/Overlays/xml-free/overlay.json +34 -0
- package/kit-apple/Package.swift +17 -0
- package/kit-apple/Sources/NativeScriptKit/AnimationFrame.swift +41 -0
- package/kit-apple/Sources/NativeScriptKit/AppModules.swift +88 -0
- package/kit-apple/Sources/NativeScriptKit/ApplicationDelegateClass.swift +273 -0
- package/kit-apple/Sources/NativeScriptKit/CSSCalc.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/ChangeDetection.swift +31 -0
- package/kit-apple/Sources/NativeScriptKit/ColorMix.swift +577 -0
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity0.swift +1413 -0
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity1.swift +6525 -0
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity2.swift +4713 -0
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity3Plus.swift +5428 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_Accuracy_AndroidActionBarIconVisibility_AndroidActionItemPosition_AnimationCurve_AutocapitalizationType_BackgroundRepeat_and_26_more_630c32.swift +472 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_ArrayExpression_BinaryExpression_CallExpression_ChainExpression_ConditionalExpression_Identifier_and_10_more_f883bf.swift +359 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_Tab_NewLine_excl_quot_QUOT_num_and_287_more_88aef2.swift +2190 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_Unknown_QuirksMode_IgnoreCase_CaseSensitive.swift +122 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_a_b_c_d_tx_ty.swift +123 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_a_h_s_l.swift +85 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_a_h_s_v.swift +85 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_a_r_g_b.swift +85 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_activate_deactivate_background_foreground_close_attached_and_26_more_127a37.swift +448 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_activeType.swift +65 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_alert_confirm_prompt_login_action.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_align_offset.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_android_ios_visionos_apple.swift +109 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_angle_colors.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_animations.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_animations_completion.swift +73 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_axis_value.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_backgroundColor_scale_translate_rotate_opacity_width_height_valueSource_duration_curve_forceLayer.swift +257 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_body.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_boundsChanged_sizeChanged.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_callback_thisArg_once.swift +112 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_collections_createUIDocumentInteractionControllerDelegate_getCurrentAppPath_getRootViewController_getVisibleViewController_getWindow_and_10_more_6713a9.swift +281 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_color.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_color_backgroundColor.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_color_offset.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_component_exports.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_component_exports_.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_connectionOptions.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_constructor_hasOwnProperty_isPrototypeOf_propertyIsEnumerable_toLocaleString_toString_and_21_more_e9ed9b.swift +331 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_content_statusCode_headers.swift +106 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_context_closeCallback_fullscreen_animated_stretched.swift +149 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_context_parent_name_elementName_templateItems_errorFormat_sourceTracker_xmlModule.swift +185 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_counters_timeline.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_create.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_createSelector_SelectorCore_SimpleSelector_InvalidSelector_UniversalSelector_TypeSelector_and_12_more_71e044.swift +315 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_curve.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_defaultValue_name_cssName_affectsLayout.swift +131 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_defaultValue_name_cssName_valueConverter.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_defaultValue_name_cssName_valueConverter_.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_deg_rad_grad_turn.swift +105 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_duration_damping.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_duration_repeatCount_delay_curve_propertyNameToAnimate_subPropertiesToAnimate_fromValue_toValue.swift +211 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_duration_spring.swift +90 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_edge_interaction.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_effectType_onCreate.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_effectType_targetView.swift +73 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_effectType_targetView_toGlassStyleFn.swift +110 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_empty_text_json_blob_arraybuffer.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_enterFrom_exitTo.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_entry_isBackNavigation_navigationType.swift +115 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_entry_resolvedPage_navDepth_fragmentTag.swift +133 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_entry_resolvedPage_navDepth_fragmentTag_frameId.swift +162 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_enumerable_configurable_get_set.swift +123 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_enumerable_configurable_get_set_.swift +122 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_enumerable_configurable_get_set__.swift +122 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_android_ios_newValue_object.swift +147 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_data.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_action_index_removed_addedCount.swift +153 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_action_index_removed_addedCount_.swift +154 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_action_index_removed_addedCount__.swift +152 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_android_ios_error.swift +148 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_context_closeCallback.swift +133 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_context_isBackNavigation.swift +132 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_cssFile.swift +110 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_cssFile_.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_cssText.swift +110 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_data.swift +112 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_data_.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_error.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_index_count.swift +120 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_index_section_view_ios_android.swift +168 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_ios.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_ios_.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_ios_android.swift +129 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_ios_android_cssFile.swift +138 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_isBack_entry_fromEntry.swift +130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_key_error.swift +128 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_key_image.swift +129 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_matches_media.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_newValue.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_oldIndex_newIndex.swift +104 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_oldIndex_newIndex_.swift +121 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_propertyName_value_oldValue.swift +147 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_text_ios.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_type_view_ios.swift +117 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_url_navigationType_error.swift +158 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_url_navigationType_error_.swift +160 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_viewController.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_view_context.swift +130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window.swift +103 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_newValue.swift +123 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene.swift +105 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_.swift +105 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_shortcutItem_completionHandler.swift +157 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_shortcutItem_completionHandler_.swift +158 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_uiWindow_connectionOptions.swift +137 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_uiWindow_connectionOptions_.swift +137 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_urlContexts.swift +120 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_urlContexts_.swift +120 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_userActivity.swift +121 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_window_scene_userActivity_.swift +121 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_rootView.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_type.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_type_object.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_window_object.swift +103 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventType_position_prefix_namespace_elementName_attributes_data.swift +169 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_exists_isDirectory.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_f_s_t_a.swift +85 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_folder_path.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_fontFamily_fontSize_fontWeight_fontVariationSettings_isBold_isItalic.swift +130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_fontStyle_fontVariant_fontWeight.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_h_s_l.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_h_s_v.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_headers_timestamp_headersSize_method_postData_url.swift +173 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_highlighted.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_horizontal_vertical.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_hour_minute.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_id_type.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_id_type_action.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_id_type_percent.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_import_type.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_inset_color_values.swift +87 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_inset_offsetX_offsetY_blurRadius_spreadRadius_color.swift +147 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_inset_offsetX_offsetY_blurRadius_spreadRadius_color_.swift +126 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_instance.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_instance_instanceModule.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_instance_property.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_instance_property_.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_interactiveBegan.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_interactiveBegan_interactiveCancelled.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_interactiveCancelled.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_interactive_pageStart_pageEnd_pageOut_pageReturn_instance_activeType.swift +165 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_inverse_type_features.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_ios.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_iosNotificationType.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_iosNotificationType_message.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_ios_.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_ios_scene.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_isMatch_getMatchOccurences_getMatchValue.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_iterator_prototype_for_keyFor_hasInstance_isConcatSpreadable_and_19_more_91b5f3.swift +413 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_keepAspectRatio_autoScaleFactor.swift +73 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_key_createView.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_key_createView_.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_launchData.swift +68 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_left_right.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_left_right_center_top_bottom.swift +115 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_lifecycle_timeline.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_line_column.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_location.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_location_length.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_m.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_maskPath_shadowPath.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_matches_media.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_measuredWidth_measuredHeight.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_message.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_method.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_method_postData.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_modifier_property_value.swift +87 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_moduleName.swift +65 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_moduleName_.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_moduleName_create_transition.swift +93 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_moduleName_transition.swift +76 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_affectsLayout_valueChanged.swift +103 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_affectsLayout_valueChanged_.swift +98 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_affectsLayout_valueChanged__.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_affectsLayout_valueChanged___.swift +102 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_affectsLayout_valueConverter.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_affectsLayout_valueConverter_valueChanged.swift +115 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_defaultValue_valueConverter_valueChanged.swift +139 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_defaultValue_valueConverter_valueChanged_.swift +159 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_valueChanged.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_valueChanged_valueConverter.swift +130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_valueChanged_valueConverter_.swift +134 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_valueConverter.swift +133 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_affectsLayout_valueConverter_.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_equalityComparer_valueChanged_valueConverter.swift +183 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_equalityComparer_valueConverter.swift +168 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_equalityComparer_valueConverter_.swift +169 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_equalityComparer_valueConverter_valueChanged.swift +181 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_valueConverter.swift +128 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_valueConverter_.swift +128 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_valueConverter__.swift +128 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_affectsLayout_valueConverter_valueChanged.swift +139 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_equalityComparer_valueChanged_valueConverter.swift +162 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_equalityComparer_valueConverter.swift +150 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_valueConverter.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_valueConverter_.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_valueConverter__.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_valueConverter___.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_defaultValue_valueConverter_valueChanged.swift +121 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_equalityComparer_defaultValue_valueConverter.swift +129 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_equalityComparer_valueConverter.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_getter_converter.swift +130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_getter_converter_.swift +133 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_getter_converter__.swift +130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_getter_converter___.swift +131 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_getter_converter____.swift +133 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_getter_converter_____.swift +131 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueChanged.swift +99 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueChanged_equalityComparer_valueConverter.swift +153 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueChanged_equalityComparer_valueConverter_.swift +132 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueChanged_valueConverter.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueConverter.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueConverter_.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueConverter__.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_cssName_valueConverter_valueChanged.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue__.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue___.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_equalityComparer_valueConverter_valueChanged.swift +163 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueChanged_coerceValue_valueConverter.swift +144 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueChanged_valueConverter.swift +124 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueConverter.swift +135 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueConverter_.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueConverter__.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueConverter___.swift +135 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueConverter____.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_affectsLayout_valueConverter_valueChanged.swift +122 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_coerceValue_valueChanged_valueConverter.swift +125 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_coerceValue_valueConverter.swift +116 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_coerceValue_valueConverter_.swift +115 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_equalityComparer_coerceValue_valueChanged_valueConverter.swift +170 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_equalityComparer_valueChanged.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_equalityComparer_valueConverter.swift +116 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_equalityComparer_valueConverter_.swift +139 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_equalityComparer_valueConverter__.swift +136 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged.swift +92 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_.swift +92 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_coerceValue_valueConverter.swift +126 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_equalityComparer_valueConverter.swift +146 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter.swift +107 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter_.swift +107 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter__.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter___.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter____.swift +128 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter_____.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueChanged_valueConverter______.swift +126 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter.swift +98 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter_.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter__.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter___.swift +98 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter____.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter_coerceValue.swift +115 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter_valueChanged.swift +107 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_defaultValue_valueConverter_valueChanged_.swift +107 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_duration.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_equalityComparer_valueConverter.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_equalityComparer_valueConverter_.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_equalityComparer_valueConverter__.swift +119 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_keyframes_mediaQueryString.swift +117 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged.swift +82 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_.swift +82 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged__.swift +84 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged___.swift +84 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged____.swift +82 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_____.swift +82 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged______.swift +82 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_______.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged________.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_________.swift +92 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged__________.swift +90 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_valueConverter.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_valueConverter_.swift +119 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueChanged_valueConverter__.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueConverter.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueConverter_.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_name_valueConverter__.swift +82 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_navigatingToEvent_navigatedToEvent_navigatingFromEvent_navigatedFromEvent.swift +116 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_normalState_selectedState.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_num_regexp_string_name_privateId_eof_and_71_more_93cbae.swift +688 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_object_eventName_propertyName_value_oldValue_origin.swift +154 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_object_eventName_scrollX_scrollY.swift +105 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_object_eventName_scrollX_scrollY_.swift +121 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_opacity_color_tapToClose_animation_ignoreShadeRestore.swift +131 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_orientation_systemAppearance.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_orientation_systemAppearance_.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_page_toPage.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_page_toPage_.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_parent_name_items.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_path_name.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_path_name_extension.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_pattern_flags.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_position_systemIcon.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_prefix_namespace_name.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_presented_presenting_independent.swift +98 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_propName_propValue.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value_.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value__.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value___.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value____.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value_____.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value______.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value_______.swift +83 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_property_value________.swift +83 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_r_g_b.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_raw_cooked.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_raw_cooked_.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_raw_requestURL_toNativeImage_toNativeString.swift +114 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_raw_requestURL_toNativeImage_toNativeString_.swift +135 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_recognizer_target.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_repeatX_repeatY_posX_posY.swift +93 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_requestTime_proxyStart_proxyEnd_dnsStart_dnsEnd_connectStart_and_9_more_3e958e.swift +248 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_result_text.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_result_userName_password.swift +102 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_right_left.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_row_col.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_rules.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_rules_.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_safeArea_fullscreen_inWindow.swift +107 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_scale_translate_rotate.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_scale_tx_ty.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_sceneWillConnect_sceneDidActivate_sceneWillResignActive_sceneWillEnterForeground_sceneDidEnterBackground_sceneDidDisconnect_and_1_more_1be9d4.swift +159 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_scene_uiWindow.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_shape_rule.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_sharedElements_presented_presenting.swift +115 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_sharedTransitionTag_zIndex.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_showing.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_snap_endFrame_endCornerRadius_srcSharedView.swift +112 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_sourceProperty_expression_twoWay_source_defaultProperty.swift +120 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_sourceProperty_targetProperty_expression.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_sourceProperty_targetProperty_expression_twoWay_compiled.swift +145 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_spans.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value_.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value__.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value___.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value____.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value_____.swift +88 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value______.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value_______.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value________.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value_________.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value__________.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value___________.swift +87 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value____________.swift +90 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value_____________.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_start_end_value______________.swift +90 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_status_headers.swift +83 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_status_statusText.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_status_statusText_headers_url.swift +110 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_targetProperty.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_targetProperty_sourceProperty.swift +73 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_backgroundColor_scale_translate_rotate_opacity_width_height_valueSource_duration_curve_forceLayer.swift +264 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_opacity_backgroundColor_translate_scale_height_width_rotate_duration_delay_iterations_curve.swift +252 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_property_value_duration_delay_iterations_curve.swift +152 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_property_value_duration_delay_iterations_curve_.swift +152 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_property_value_duration_delay_iterations_curve__.swift +153 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_property_value_duration_delay_iterations_curve___.swift +151 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_target_translate_scale_rotate_opacity_duration_curve.swift +165 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_tension_friction_mass_delay_velocity_animateOptions_animations_completion.swift +165 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_tension_friction_mass_velocity.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_tension_friction_mass_velocity_delay.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_tension_friction_mass_velocity_delay_animations_completion.swift +142 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_textColor_tintColor.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_text_iosFont_color_backgroundColor_textDecoration_baselineOffset_index.swift +144 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_title_cancelButtonText.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_title_okButtonText_cancelButtonText.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_title_okButtonText_cancelButtonText_inputType.swift +112 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_title_okButtonText_cancelButtonText_message.swift +112 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_title_okButtonText_message.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_title_section.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_toArrayBuffer_toString_toJSON_toImage_toFile.swift +142 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_toString_charAt_charCodeAt_concat_indexOf_lastIndexOf_and_44_more_fc25df.swift +481 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_topLeft_topRight_bottomLeft_bottomRight.swift +110 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_top_bottom.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_top_left_bottom_right.swift +109 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_top_right_bottom_left.swift +122 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_top_right_bottom_left_.swift +109 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_totalTime_count_currentStart_runCount.swift +110 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_touches_event.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_transitionContext.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_translateX_translateY_scaleX_scaleY_rotate_opacity.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_translateX_translateY_scaleX_scaleY_rotate_opacity_duration_curve.swift +151 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_translate_rotate_scale.swift +102 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_action_value_namespace_ignoreCase.swift +152 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_action_value_namespace_ignoreCase_.swift +133 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_data.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_data_.swift +92 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_namespace.swift +102 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_prelude_block.swift +120 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_text.swift +104 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_name_text_components.swift +113 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_namespace.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_path.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_prelude_block.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_property_value.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_quote_string_value.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_selectors_declarations.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_start_end.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_start_end_left_right.swift +127 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_start_end_name.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_string.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_string_unit_value.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_stylesheet.swift +83 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_text.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_text_.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_text__.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_text_associatedToken_values.swift +125 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_direction_object_eventName.swift +159 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_eventName_object_getPointerCount_getX_getY.swift +187 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_object_eventName.swift +152 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_object_eventName_state.swift +167 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_rotation_object_eventName_state.swift +182 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_scale_getFocusX_getFocusY_object_eventName_state.swift +194 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_type_view_ios_android_startX_startY_deltaX_deltaY_object_eventName_state.swift +201 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_uri_message_time.swift +108 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_url_method.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_url_source.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_url_source_.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_url_status_statusText_headers_mimeType_fromDiskCache_timing_headersSize.swift +201 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_value_unit.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_value_unit_.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_index.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_index_.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_isPresented_startFrame_snapshot_endFrame_startTransform_and_5_more_20e753.swift +234 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_options.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_options_.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_startFrame_endFrame_snapshot_startOpacity_endOpacity_propertiesToMatch_zIndex.swift +186 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_startFrame_endFrame_startOpacity_endOpacity_propertiesToMatch_imageSourceChangeListener.swift +181 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_view_type_animation.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_width_color.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_width_height.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_width_height_.swift +95 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_width_height_os_deviceType.swift +109 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_windowOpen_windowClose_primaryWindowChanged.swift +96 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_window_isPrimary.swift +80 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_window_isPrimary_data_ios.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_xRadius_yRadius_maxRadius.swift +87 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y.swift +85 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y__.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y___.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y____.swift +86 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_____.swift +77 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y______.swift +74 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_______.swift +89 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y________.swift +88 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_________.swift +77 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_width_height.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_z.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_x_y_z_.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_xmlns.swift +64 -0
- package/kit-apple/Sources/NativeScriptKit/Core/Object_xs_ys_xt_yt_rx_ry_rz.swift +106 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.AndroidApplication.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.AndroidHelper.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.AnimationCurve.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.Application.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.CSSHelper.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.CSSType.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.Device.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.Dialogs.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.Enums.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.NativeWindowEvents.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.PseudoClassHandler.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.SceneEvents.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.WindowEvents.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export._resetRootView.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export._resolveAnimationCurve.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export._setResolver.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export._updateCharactersInRangeReplacementString.swift +23 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.action.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.addCss.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.addTaggedAdditionalCSS.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.addWeakEventListener.swift +22 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.alert.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.android.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.androidDynamicElevationOffsetProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.androidElevationProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.animationTimingFunctionConverter.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.autocapitalizationTypeProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.autocorrectProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundColorProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundImageProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundInternalProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundPositionProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundRepeatProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.backgroundSizeProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.booleanConverter.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderBottomColorProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderBottomLeftRadiusProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderBottomRightRadiusProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderBottomWidthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderLeftColorProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderLeftWidthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderRightColorProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderRightWidthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderTopColorProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderTopLeftRadiusProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderTopRightRadiusProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.borderTopWidthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.clipPathProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.colorProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.columnGapProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.confirm.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.cornerShapeProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.directionProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.discardedErrorEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.displayedEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.eachDescendant.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.editableProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.ensureA11yClasses.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.exitEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontFamilyProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontInternalProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontScaleChangedEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontScaleInternalProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontSizeProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontStyleProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontVariationSettingsProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fontWeightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.foregroundEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fromObject.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.fromObjectRecursive.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getAncestor.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getAndroidAccessibilityManager.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getCssFileName.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getCurrentFontScale.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getCurrentPage.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getFileAccess.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getMainEntry.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getNativeApp.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getNativeApplication.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getResources.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getRootLayout.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getRootLayoutById.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getRootView.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getTransformedText.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.getViewById.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.hasLaunched.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.hasListeners.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.heightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.hintProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.horizontalAlignmentProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.inBackground.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.initAccessibilityCssHelper.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isAccessibilityServiceEnabled.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isAndroid.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isApple.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isEmbedded.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isIOS.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isUserInteractionEnabledProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.isVisionOS.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.keyboardTypeProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.launchEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.layoutDirection.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.layoutDirectionChanged.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.layoutDirectionChangedEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.letterSpacingProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.lineHeightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.loadAppCss.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.login.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.lowMemoryEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.makeParser.swift +22 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.makeValidator.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.marginBottomProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.marginLeftProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.marginRightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.marginTopProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.maxHeightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.maxLengthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.maxWidthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.minHeightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.minWidthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.notify.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.off.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.on.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.opacityProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.orientation.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.orientationChangedEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.paddingBottomProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.paddingInternalProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.paddingLeftProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.paddingRightProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.paddingTopProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.parseCSSShadow.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.parseCSSStroke.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.parseKeyframeDeclarations.swift +22 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.perspectiveProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.placeholderColorProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.platformNames.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profile.swift +22 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingDisable.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingDumpProfiles.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingEnable.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingIsRunning.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingResetProfiles.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingStart.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingStartCPU.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingStop.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingStopCPU.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.profilingUptime.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.prompt.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.querySelectorAll.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.removeTaggedAdditionalCSS.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.removeWeakEventListener.swift +22 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.resetRootView.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.resolveFileNameFromUrl.swift +23 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.resumeEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.returnKeyTypeProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.rotateProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.rotateXProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.rotateYProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.rowGapProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.run.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.sanitizeModuleName.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.scaleXProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.scaleYProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.sendAccessibilityEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.setActivityCallbacks.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.setAutoSystemAppearanceChanged.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.setCssFileName.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.setMaxRefreshRate.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.setNativeApp.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.setResources.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.suspendEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.suspended.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.systemAppearance.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.systemAppearanceChanged.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.systemAppearanceChangedEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.textAlignmentProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.textDecorationProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.textOverflowProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.textShadowProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.textStrokeProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.textTransformProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.timeConverter.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.translateXProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.translateYProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.uncaughtErrorEvent.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.unsetValue.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.updateAccessibilityProperties.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.updateCurrentHelperClasses.swift +21 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.updateTextTriggerProperty.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.verticalAlignmentProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.visibilityProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.whiteSpaceProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.widthProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Export.zIndexProperty.swift +18 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Modules.swift +17 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Namespace.Http.swift +23 -0
- package/kit-apple/Sources/NativeScriptKit/Core/__Namespace.Utils.swift +201 -0
- package/kit-apple/Sources/NativeScriptKit/Core/abortcontroller.abortsignal.swift +109 -0
- package/kit-apple/Sources/NativeScriptKit/Core/abortcontroller.index.swift +118 -0
- package/kit-apple/Sources/NativeScriptKit/Core/accessibility.accessibility-common.swift +572 -0
- package/kit-apple/Sources/NativeScriptKit/Core/accessibility.accessibility-properties.swift +258 -0
- package/kit-apple/Sources/NativeScriptKit/Core/accessibility.index.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application-settings.application-settings-common.swift +36 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application-settings.index.ios.swift +157 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.application-common.swift +2095 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.application-interfaces.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.application-shims.swift +212 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.application.ios.swift +3854 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.helpers-common.swift +224 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.helpers.ios.swift +57 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.index.ios.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/application.scene-delegate-bridge.swift +234 -0
- package/kit-apple/Sources/NativeScriptKit/Core/color.color-common.swift +756 -0
- package/kit-apple/Sources/NativeScriptKit/Core/color.color-types.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/color.color-utils.swift +388 -0
- package/kit-apple/Sources/NativeScriptKit/Core/color.index.ios.swift +100 -0
- package/kit-apple/Sources/NativeScriptKit/Core/color.known-colors.swift +520 -0
- package/kit-apple/Sources/NativeScriptKit/Core/connectivity.index.ios.swift +190 -0
- package/kit-apple/Sources/NativeScriptKit/Core/core-types.animation-types.swift +87 -0
- package/kit-apple/Sources/NativeScriptKit/Core/core-types.index.swift +361 -0
- package/kit-apple/Sources/NativeScriptKit/Core/core-types.validators.swift +62 -0
- package/kit-apple/Sources/NativeScriptKit/Core/css-mediaquery.index.swift +220 -0
- package/kit-apple/Sources/NativeScriptKit/Core/css-value.reworkcss-value.swift +280 -0
- package/kit-apple/Sources/NativeScriptKit/Core/css.CSS3Parser.swift +1012 -0
- package/kit-apple/Sources/NativeScriptKit/Core/css.CSSNativeScript.swift +264 -0
- package/kit-apple/Sources/NativeScriptKit/Core/css.parser.swift +971 -0
- package/kit-apple/Sources/NativeScriptKit/Core/css.system-classes.swift +120 -0
- package/kit-apple/Sources/NativeScriptKit/Core/data.observable-array.index.swift +699 -0
- package/kit-apple/Sources/NativeScriptKit/Core/data.observable.index.swift +1166 -0
- package/kit-apple/Sources/NativeScriptKit/Core/data.virtual-array.index.swift +325 -0
- package/kit-apple/Sources/NativeScriptKit/Core/fetch.index.swift +1201 -0
- package/kit-apple/Sources/NativeScriptKit/Core/file-system.file-system-access.ios.swift +1450 -0
- package/kit-apple/Sources/NativeScriptKit/Core/file-system.index.swift +1756 -0
- package/kit-apple/Sources/NativeScriptKit/Core/fps-meter.fps-native.ios.swift +227 -0
- package/kit-apple/Sources/NativeScriptKit/Core/fps-meter.index.swift +141 -0
- package/kit-apple/Sources/NativeScriptKit/Core/globals.global-utils.swift +252 -0
- package/kit-apple/Sources/NativeScriptKit/Core/http.http-interfaces.swift +24 -0
- package/kit-apple/Sources/NativeScriptKit/Core/http.http-request-internal.http-request-internal-common.swift +59 -0
- package/kit-apple/Sources/NativeScriptKit/Core/http.http-request-internal.index.ios.swift +413 -0
- package/kit-apple/Sources/NativeScriptKit/Core/http.http-request.http-request-common.swift +57 -0
- package/kit-apple/Sources/NativeScriptKit/Core/http.http-request.index.ios.swift +101 -0
- package/kit-apple/Sources/NativeScriptKit/Core/http.index.swift +175 -0
- package/kit-apple/Sources/NativeScriptKit/Core/image-asset.image-asset-common.swift +285 -0
- package/kit-apple/Sources/NativeScriptKit/Core/image-asset.index.ios.swift +205 -0
- package/kit-apple/Sources/NativeScriptKit/Core/image-source.image-source-common.swift +40 -0
- package/kit-apple/Sources/NativeScriptKit/Core/image-source.index.ios.swift +1130 -0
- package/kit-apple/Sources/NativeScriptKit/Core/js-libs.easysax.easysax.swift +1388 -0
- package/kit-apple/Sources/NativeScriptKit/Core/kit-index.json +30808 -0
- package/kit-apple/Sources/NativeScriptKit/Core/manifest.json +3383 -0
- package/kit-apple/Sources/NativeScriptKit/Core/matrix.index.swift +151 -0
- package/kit-apple/Sources/NativeScriptKit/Core/media-query-list.index.swift +468 -0
- package/kit-apple/Sources/NativeScriptKit/Core/module-name-resolver.helpers.swift +57 -0
- package/kit-apple/Sources/NativeScriptKit/Core/module-name-resolver.index.swift +220 -0
- package/kit-apple/Sources/NativeScriptKit/Core/module-name-resolver.non-bundle-workflow-compat.swift +262 -0
- package/kit-apple/Sources/NativeScriptKit/Core/module-name-resolver.qualifier-matcher.index.swift +330 -0
- package/kit-apple/Sources/NativeScriptKit/Core/native-window.index.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/native-window.native-window-common.swift +730 -0
- package/kit-apple/Sources/NativeScriptKit/Core/native-window.native-window-interfaces.swift +46 -0
- package/kit-apple/Sources/NativeScriptKit/Core/native-window.native-window.ios.swift +521 -0
- package/kit-apple/Sources/NativeScriptKit/Core/native-window.window-base.swift +298 -0
- package/kit-apple/Sources/NativeScriptKit/Core/npm.css-what.src.index.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/npm.css-what.src.parse.swift +668 -0
- package/kit-apple/Sources/NativeScriptKit/Core/npm.css-what.src.stringify.swift +221 -0
- package/kit-apple/Sources/NativeScriptKit/Core/npm.css-what.src.types.swift +62 -0
- package/kit-apple/Sources/NativeScriptKit/Core/platform.common.swift +25 -0
- package/kit-apple/Sources/NativeScriptKit/Core/platform.device.index.ios.swift +289 -0
- package/kit-apple/Sources/NativeScriptKit/Core/platform.index.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/platform.screen.index.ios.swift +217 -0
- package/kit-apple/Sources/NativeScriptKit/Core/profiling.index.swift +528 -0
- package/kit-apple/Sources/NativeScriptKit/Core/text.formatted-string.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/text.index.ios.swift +25 -0
- package/kit-apple/Sources/NativeScriptKit/Core/text.span.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/text.text-common.swift +309 -0
- package/kit-apple/Sources/NativeScriptKit/Core/trace.index.swift +513 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.action-bar.action-bar-common.swift +1270 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.action-bar.index.ios.swift +1480 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.activity-indicator.activity-indicator-common.swift +81 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.activity-indicator.index.ios.swift +175 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.animation.animation-common.swift +581 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.animation.animation-shared.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.animation.animation-types.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.animation.index.ios.swift +2204 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.animation.keyframe-animation.swift +1213 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.builder.binding-builder.swift +318 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.builder.component-builder.index.swift +387 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.builder.index.swift +2026 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.button.button-common.swift +75 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.button.index.ios.swift +614 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.content-view.index.swift +291 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.bindable.bindable-expressions.swift +770 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.bindable.bindable-resources.swift +30 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.bindable.bindable-types.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.bindable.expression-parser.swift +5297 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.bindable.index.swift +1376 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.control-state-change.index.ios.swift +197 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.properties.index.swift +3899 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.properties.property-shared.swift +53 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view-base.index.swift +3522 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view-base.utils.swift +32 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.index.ios.swift +3318 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-common.swift +4347 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-helper.index.ios.swift +1417 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-helper.view-helper-common.swift +337 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-helper.view-helper-shared.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-interfaces.swift +272 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.weak-event-listener.index.swift +323 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.date-picker.date-picker-common.swift +335 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.date-picker.index.ios.swift +609 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.dialogs.dialogs-common.swift +486 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.dialogs.index.ios.swift +677 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.editable-text-base.editable-text-base-common.swift +378 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.editable-text-base.index.ios.swift +512 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.embedding.index.ios.swift +25 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.enums.enums.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.enums.index.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.fragment.ios.swift +26 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.fragment.transitions.types.swift +23 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.frame-common.swift +1526 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.frame-constants.swift +21 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.frame-helpers.swift +40 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.frame-interfaces.swift +26 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.frame-stack.swift +138 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.index.ios.swift +1794 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.gestures.gestures-common.swift +269 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.gestures.gestures-types.swift +77 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.gestures.index.ios.swift +1453 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.gestures.touch-manager.swift +451 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.html-view.html-view-common.swift +106 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.html-view.index.ios.swift +301 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image-cache.image-cache-common.swift +479 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image-cache.index.ios.swift +232 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image.image-common.swift +399 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image.index.ios.swift +499 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image.symbol-effects-common.swift +150 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image.symbol-effects.ios.swift +148 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.label.index.ios.swift +483 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.absolute-layout.absolute-layout-common.swift +172 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.absolute-layout.index.ios.swift +189 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.dock-layout.dock-layout-common.swift +157 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.dock-layout.index.ios.swift +264 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.flexbox-layout.flexbox-layout-common.swift +1028 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.flexbox-layout.index.ios.swift +3235 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.grid-layout.grid-layout-common.swift +1014 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.grid-layout.index.ios.swift +2435 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.index.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.layout-base-common.swift +591 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.layout-base.ios.swift +135 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.liquid-glass-container.index.ios.swift +364 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.liquid-glass-container.liquid-glass-container-common.swift +49 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.liquid-glass.index.ios.swift +238 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.liquid-glass.liquid-glass-common.swift +34 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.root-layout.index.ios.swift +347 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.root-layout.root-layout-common.swift +964 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.root-layout.root-layout-stack.swift +59 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.stack-layout.index.ios.swift +350 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.stack-layout.stack-layout-common.swift +72 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.wrap-layout.index.ios.swift +357 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.wrap-layout.wrap-layout-common.swift +188 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.list-picker.index.ios.swift +374 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.list-picker.list-picker-common.swift +252 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.list-view.index.ios.swift +2611 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.list-view.list-view-common.swift +950 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.page.events.swift +23 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.page.index.ios.swift +1340 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.page.page-common.swift +520 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.placeholder.index.swift +63 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.placeholder.placeholder-common.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.progress.index.ios.swift +173 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.progress.progress-common.swift +111 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.proxy-view-container.index.swift +497 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.repeater.index.swift +535 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.scroll-view.index.ios.swift +699 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.scroll-view.scroll-view-common.swift +414 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.search-bar.index.ios.swift +609 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.search-bar.search-bar-common.swift +162 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.segmented-bar.index.ios.swift +470 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.segmented-bar.segmented-bar-common.swift +448 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.slider.index.ios.swift +593 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.slider.slider-common.swift +211 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.split-view.index.ios.swift +1459 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.split-view.split-view-common.swift +410 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.background-common.swift +809 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.background.ios.swift +2290 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.box-shadow.swift +138 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.clip-path-function.swift +198 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.converters.swift +105 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.css-animation-parser.swift +493 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.css-selector.swift +4016 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.css-shadow.swift +48 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.css-stroke.swift +41 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.css-transform.swift +406 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.css-utils.swift +297 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.font-common.swift +477 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.font-interfaces.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.font.ios.swift +416 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.length-shared.swift +343 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.linear-gradient.swift +162 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.style-properties.swift +2524 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.style-scope.swift +3330 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.style.index.swift +905 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.styling-profile.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.styling-shared.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.switch.index.ios.swift +508 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.switch.switch-common.swift +143 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.tab-view.index.ios.swift +2284 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.tab-view.tab-view-common.swift +985 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-base.formatted-string.swift +801 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-base.index.ios.swift +1264 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-base.span.swift +476 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-base.text-base-common.swift +1047 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-field.index.ios.swift +912 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-field.text-field-common.swift +121 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-view.index.ios.swift +1030 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-view.text-view-common.swift +138 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.time-picker.index.ios.swift +473 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.time-picker.time-picker-common.swift +536 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.fade-transition.ios.swift +265 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.index.ios.swift +159 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.modal-transition.ios.swift +635 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.page-transition.ios.swift +1167 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.shared-transition-helper.ios.swift +3673 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.shared-transition.swift +492 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.transition.slide-transition.ios.swift +328 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.utils.ios.swift +132 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.web-view.index.ios.swift +827 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.web-view.web-view-common.swift +206 -0
- package/kit-apple/Sources/NativeScriptKit/Core/ui.web-view.web-view-interfaces.swift +16 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.animation-helpers.swift +84 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.common.swift +278 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.constants.ios.swift +33 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.debug-source.swift +271 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.debug.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.index.ios.swift +205 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.layout-helper.index.ios.swift +131 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.layout-helper.layout-helper-common.swift +87 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.layout-helper.layout-helper-shared.swift +28 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.lazy.swift +39 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.macrotask-scheduler.swift +71 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.mainthread-helper.ios.swift +52 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.module-merge.swift +27 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.native-helper.ios.swift +734 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.number-utils.swift +79 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.platform-check.swift +25 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.shared.swift +84 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.types.swift +308 -0
- package/kit-apple/Sources/NativeScriptKit/Core/utils.utils-shared.swift +31 -0
- package/kit-apple/Sources/NativeScriptKit/Core/xhr.index.swift +1726 -0
- package/kit-apple/Sources/NativeScriptKit/Core/xml.index.swift +775 -0
- package/kit-apple/Sources/NativeScriptKit/CoreBridge.swift +388 -0
- package/kit-apple/Sources/NativeScriptKit/CoreConnectivity.swift +46 -0
- package/kit-apple/Sources/NativeScriptKit/CoreLifetimes.swift +15 -0
- package/kit-apple/Sources/NativeScriptKit/CorePackages.swift +59 -0
- package/kit-apple/Sources/NativeScriptKit/JS.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Modal.swift +65 -0
- package/kit-apple/Sources/NativeScriptKit/Probe.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Regions.swift +291 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/AbsentModules.swift +78 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Array.swift +1693 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/ArrayLike.swift +859 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/BigInt.swift +338 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/BuiltinValues.swift +45 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Collections.swift +609 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Date.swift +269 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Dynamic.swift +474 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/ES2023.swift +105 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Errors.swift +402 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Functions.swift +372 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Inspect.swift +762 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Interop.swift +42 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Intl.swift +799 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Iterators.swift +898 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/JSON.swift +874 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Lowering.swift +593 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Native.swift +819 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/NativeStack.swift +66 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Number.swift +599 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Promise.swift +810 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Prototypes.swift +471 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Reactive.swift +34 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Record.swift +59 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/RegExp.swift +576 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/RegExpEngine.swift +1918 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Stack.swift +20 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/StringUTF16.swift +179 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Symbol.swift +142 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Threads.swift +275 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Timers.swift +240 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/TypedArrays.swift +996 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/URI.swift +94 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Values.swift +2069 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Views.swift +97 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Weak.swift +135 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/WinterTC.swift +484 -0
- package/kit-apple/Sources/NativeScriptKit/Signals.swift +952 -0
- package/kit-apple/Sources/NativeScriptKit/UncaughtErrors.swift +37 -0
- package/package.json +94 -4
- package/verify/ui-driver/Host/App.swift +7 -0
- package/verify/ui-driver/Tests/Driver.swift +54 -0
- package/verify/ui-driver/project.yml +35 -0
|
@@ -0,0 +1,3828 @@
|
|
|
1
|
+
// Generated from @nativescript/core by tools/kit: edit core, not this file.
|
|
2
|
+
package org.nativescript.kit
|
|
3
|
+
|
|
4
|
+
import android.app.Application as android_app_Application
|
|
5
|
+
import androidx.annotation.AnyThread
|
|
6
|
+
import java.io.ByteArrayOutputStream
|
|
7
|
+
import java.io.DataInputStream
|
|
8
|
+
import java.io.File as java_io_File
|
|
9
|
+
import java.io.FileInputStream
|
|
10
|
+
import java.io.FileOutputStream
|
|
11
|
+
import java.io.OutputStreamWriter
|
|
12
|
+
import java.lang.Exception
|
|
13
|
+
import java.nio.ByteBuffer
|
|
14
|
+
import java.nio.channels.FileChannel
|
|
15
|
+
import java.nio.file.Paths
|
|
16
|
+
import org.nativescript.widgets.Async
|
|
17
|
+
import org.nativescript.widgets.FileHelper
|
|
18
|
+
|
|
19
|
+
@AnyThread
|
|
20
|
+
open class FileSystemAccess : JSExpando {
|
|
21
|
+
@JvmField var _pathSeparator: String = "/"
|
|
22
|
+
@JvmField var copy: Any? = this::copySync
|
|
23
|
+
open var readBuffer: Any? = this::readBufferSync
|
|
24
|
+
open var read: Any? = this::readSync
|
|
25
|
+
open var appendBuffer: Any? = this::appendBufferSync
|
|
26
|
+
open var append: Any? = this::appendSync
|
|
27
|
+
open var writeBuffer: Any? = this::writeBufferSync
|
|
28
|
+
open var write: Any? = this::writeSync
|
|
29
|
+
open var readText: Any? = this::readTextSync
|
|
30
|
+
open var appendText: Any? = this::appendTextSync
|
|
31
|
+
open var writeText: Any? = this::writeTextSync
|
|
32
|
+
|
|
33
|
+
fun getLastModified__FileSystemAccess(path: String?): JSDate? {
|
|
34
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
35
|
+
return JSDate(javaFile.lastModified().toDouble())
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
open fun getLastModified_(path: String?): JSDate? {
|
|
39
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
40
|
+
return JSDate(javaFile.lastModified().toDouble())
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
fun getFileSize__FileSystemAccess(path: String?): Double {
|
|
44
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
45
|
+
return javaFile.length().toDouble()
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
open fun getFileSize(path: String?): Double {
|
|
49
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
50
|
+
return javaFile.length().toDouble()
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
fun getParent__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
54
|
+
try {
|
|
55
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
56
|
+
val parent: java_io_File? = javaFile.getParentFile()
|
|
57
|
+
return jsObjectOf(
|
|
58
|
+
"path" to ((parent ?: jsCannotRead("getAbsolutePath")).getAbsolutePath() ?: JSNull),
|
|
59
|
+
"name" to ((parent ?: jsCannotRead("getName")).getName() ?: JSNull),
|
|
60
|
+
)
|
|
61
|
+
} catch (__e_1: Throwable) {
|
|
62
|
+
val exception: Any? = jsCaught(__e_1)
|
|
63
|
+
if (jsTruthy(onError)) {
|
|
64
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
65
|
+
}
|
|
66
|
+
return null
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
open fun getParent_(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
71
|
+
try {
|
|
72
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
73
|
+
val parent: java_io_File? = javaFile.getParentFile()
|
|
74
|
+
return jsObjectOf(
|
|
75
|
+
"path" to ((parent ?: jsCannotRead("getAbsolutePath")).getAbsolutePath() ?: JSNull),
|
|
76
|
+
"name" to ((parent ?: jsCannotRead("getName")).getName() ?: JSNull),
|
|
77
|
+
)
|
|
78
|
+
} catch (__e_1: Throwable) {
|
|
79
|
+
val exception: Any? = jsCaught(__e_1)
|
|
80
|
+
if (jsTruthy(onError)) {
|
|
81
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
82
|
+
}
|
|
83
|
+
return null
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
fun getFile__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
88
|
+
return this.ensureFile(java_io_File((path ?: "undefined")), false, onError)
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
open fun getFile(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
92
|
+
return this.ensureFile(java_io_File((path ?: "undefined")), false, onError)
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
fun getFolder__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
96
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
97
|
+
val dirInfo: Any? = this.ensureFile(javaFile, true, onError)
|
|
98
|
+
if (!jsTruthy(dirInfo)) {
|
|
99
|
+
return null
|
|
100
|
+
}
|
|
101
|
+
return jsObjectOf(
|
|
102
|
+
"path" to jsGet(dirInfo, "path"),
|
|
103
|
+
"name" to jsGet(dirInfo, "name"),
|
|
104
|
+
)
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
open fun getFolder(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
108
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
109
|
+
val dirInfo: Any? = this.ensureFile(javaFile, true, onError)
|
|
110
|
+
if (!jsTruthy(dirInfo)) {
|
|
111
|
+
return null
|
|
112
|
+
}
|
|
113
|
+
return jsObjectOf(
|
|
114
|
+
"path" to jsGet(dirInfo, "path"),
|
|
115
|
+
"name" to jsGet(dirInfo, "name"),
|
|
116
|
+
)
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
fun eachEntity__FileSystemAccess(
|
|
120
|
+
path: String?,
|
|
121
|
+
onEntity: (Any?) -> Boolean,
|
|
122
|
+
onError: ((Any?) -> Any?)? = null,
|
|
123
|
+
) {
|
|
124
|
+
if (!jsTruthy(onEntity)) {
|
|
125
|
+
return
|
|
126
|
+
}
|
|
127
|
+
this.enumEntities(path, onEntity, onError)
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
open fun eachEntity(
|
|
131
|
+
path: String?,
|
|
132
|
+
onEntity: (Any?) -> Boolean,
|
|
133
|
+
onError: ((Any?) -> Any?)? = null,
|
|
134
|
+
) {
|
|
135
|
+
if (!jsTruthy(onEntity)) {
|
|
136
|
+
return
|
|
137
|
+
}
|
|
138
|
+
this.enumEntities(path, onEntity, onError)
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
fun getEntities__FileSystemAccess(
|
|
142
|
+
path: String?,
|
|
143
|
+
onError: ((Any?) -> Any?)? = null,
|
|
144
|
+
): JSArray<Any?>? {
|
|
145
|
+
val fileInfos: JSArray<Any?> = JSArray<Any?>()
|
|
146
|
+
val onEntity: (Any?) -> Boolean = { entity: Any? ->
|
|
147
|
+
fileInfos.push(entity)
|
|
148
|
+
true
|
|
149
|
+
}
|
|
150
|
+
var errorOccurred: Any? = null
|
|
151
|
+
val localError: (Any?) -> Unit = { error: Any? ->
|
|
152
|
+
if (jsTruthy(onError)) {
|
|
153
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
154
|
+
}
|
|
155
|
+
errorOccurred = true
|
|
156
|
+
}
|
|
157
|
+
this.enumEntities(path, onEntity, localError)
|
|
158
|
+
if (!jsTruthy(errorOccurred)) {
|
|
159
|
+
return fileInfos
|
|
160
|
+
}
|
|
161
|
+
return null
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
open fun getEntities(path: String?, onError: ((Any?) -> Any?)? = null): JSArray<Any?>? {
|
|
165
|
+
val fileInfos: JSArray<Any?> = JSArray<Any?>()
|
|
166
|
+
val onEntity: (Any?) -> Boolean = { entity: Any? ->
|
|
167
|
+
fileInfos.push(entity)
|
|
168
|
+
true
|
|
169
|
+
}
|
|
170
|
+
var errorOccurred: Any? = null
|
|
171
|
+
val localError: (Any?) -> Unit = { error: Any? ->
|
|
172
|
+
if (jsTruthy(onError)) {
|
|
173
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
174
|
+
}
|
|
175
|
+
errorOccurred = true
|
|
176
|
+
}
|
|
177
|
+
this.enumEntities(path, onEntity, localError)
|
|
178
|
+
if (!jsTruthy(errorOccurred)) {
|
|
179
|
+
return fileInfos
|
|
180
|
+
}
|
|
181
|
+
return null
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
fun fileExists__FileSystemAccess(path: String?): Boolean {
|
|
185
|
+
val file: java_io_File = java_io_File((path ?: "undefined"))
|
|
186
|
+
return file.exists()
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
open fun fileExists(path: String?): Boolean {
|
|
190
|
+
val file: java_io_File = java_io_File((path ?: "undefined"))
|
|
191
|
+
return file.exists()
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
fun folderExists__FileSystemAccess(path: String?): Boolean {
|
|
195
|
+
val file: java_io_File = java_io_File((path ?: "undefined"))
|
|
196
|
+
return file.exists() && file.isDirectory()
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
open fun folderExists(path: String?): Boolean {
|
|
200
|
+
val file: java_io_File = java_io_File((path ?: "undefined"))
|
|
201
|
+
return file.exists() && file.isDirectory()
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
fun deleteFile__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null) {
|
|
205
|
+
try {
|
|
206
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
207
|
+
if (!javaFile.isFile()) {
|
|
208
|
+
if (jsTruthy(onError)) {
|
|
209
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
210
|
+
jsObjectOf("message" to "The specified parameter is not a File entity.")
|
|
211
|
+
)
|
|
212
|
+
}
|
|
213
|
+
return
|
|
214
|
+
}
|
|
215
|
+
if (!javaFile.delete()) {
|
|
216
|
+
if (jsTruthy(onError)) {
|
|
217
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
218
|
+
jsObjectOf("message" to "File deletion failed")
|
|
219
|
+
)
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
} catch (__e_1: Throwable) {
|
|
223
|
+
val exception: Any? = jsCaught(__e_1)
|
|
224
|
+
if (jsTruthy(onError)) {
|
|
225
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
open fun deleteFile(path: String?, onError: ((Any?) -> Any?)? = null) {
|
|
231
|
+
try {
|
|
232
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
233
|
+
if (!javaFile.isFile()) {
|
|
234
|
+
if (jsTruthy(onError)) {
|
|
235
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
236
|
+
jsObjectOf("message" to "The specified parameter is not a File entity.")
|
|
237
|
+
)
|
|
238
|
+
}
|
|
239
|
+
return
|
|
240
|
+
}
|
|
241
|
+
if (!javaFile.delete()) {
|
|
242
|
+
if (jsTruthy(onError)) {
|
|
243
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
244
|
+
jsObjectOf("message" to "File deletion failed")
|
|
245
|
+
)
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
} catch (__e_1: Throwable) {
|
|
249
|
+
val exception: Any? = jsCaught(__e_1)
|
|
250
|
+
if (jsTruthy(onError)) {
|
|
251
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
fun deleteFolder__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null) {
|
|
257
|
+
try {
|
|
258
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
259
|
+
if (!(javaFile.getCanonicalFile().isDirectory())) {
|
|
260
|
+
if (jsTruthy(onError)) {
|
|
261
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
262
|
+
jsObjectOf("message" to "The specified parameter is not a Folder entity.")
|
|
263
|
+
)
|
|
264
|
+
}
|
|
265
|
+
return
|
|
266
|
+
}
|
|
267
|
+
this.deleteFolderContent(javaFile)
|
|
268
|
+
if (!javaFile.delete()) {
|
|
269
|
+
if (jsTruthy(onError)) {
|
|
270
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
271
|
+
jsObjectOf("message" to "Folder deletion failed.")
|
|
272
|
+
)
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
} catch (__e_1: Throwable) {
|
|
276
|
+
val exception: Any? = jsCaught(__e_1)
|
|
277
|
+
if (jsTruthy(onError)) {
|
|
278
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
open fun deleteFolder(path: String?, onError: ((Any?) -> Any?)? = null) {
|
|
284
|
+
try {
|
|
285
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
286
|
+
if (!(javaFile.getCanonicalFile().isDirectory())) {
|
|
287
|
+
if (jsTruthy(onError)) {
|
|
288
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
289
|
+
jsObjectOf("message" to "The specified parameter is not a Folder entity.")
|
|
290
|
+
)
|
|
291
|
+
}
|
|
292
|
+
return
|
|
293
|
+
}
|
|
294
|
+
this.deleteFolderContent(javaFile)
|
|
295
|
+
if (!javaFile.delete()) {
|
|
296
|
+
if (jsTruthy(onError)) {
|
|
297
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
298
|
+
jsObjectOf("message" to "Folder deletion failed.")
|
|
299
|
+
)
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
} catch (__e_1: Throwable) {
|
|
303
|
+
val exception: Any? = jsCaught(__e_1)
|
|
304
|
+
if (jsTruthy(onError)) {
|
|
305
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
fun emptyFolder__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null) {
|
|
311
|
+
try {
|
|
312
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
313
|
+
if (!(javaFile.getCanonicalFile().isDirectory())) {
|
|
314
|
+
if (jsTruthy(onError)) {
|
|
315
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
316
|
+
jsObjectOf("message" to "The specified parameter is not a Folder entity.")
|
|
317
|
+
)
|
|
318
|
+
}
|
|
319
|
+
return
|
|
320
|
+
}
|
|
321
|
+
this.deleteFolderContent(javaFile)
|
|
322
|
+
} catch (__e_1: Throwable) {
|
|
323
|
+
val exception: Any? = jsCaught(__e_1)
|
|
324
|
+
if (jsTruthy(onError)) {
|
|
325
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
open fun emptyFolder(path: String?, onError: ((Any?) -> Any?)? = null) {
|
|
331
|
+
try {
|
|
332
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
333
|
+
if (!(javaFile.getCanonicalFile().isDirectory())) {
|
|
334
|
+
if (jsTruthy(onError)) {
|
|
335
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
336
|
+
jsObjectOf("message" to "The specified parameter is not a Folder entity.")
|
|
337
|
+
)
|
|
338
|
+
}
|
|
339
|
+
return
|
|
340
|
+
}
|
|
341
|
+
this.deleteFolderContent(javaFile)
|
|
342
|
+
} catch (__e_1: Throwable) {
|
|
343
|
+
val exception: Any? = jsCaught(__e_1)
|
|
344
|
+
if (jsTruthy(onError)) {
|
|
345
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
fun rename__FileSystemAccess(
|
|
351
|
+
path: String?,
|
|
352
|
+
newPath: String?,
|
|
353
|
+
onError: ((Any?) -> Any?)? = null,
|
|
354
|
+
) {
|
|
355
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
356
|
+
if (!javaFile.exists()) {
|
|
357
|
+
if (jsTruthy(onError)) {
|
|
358
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
359
|
+
JSError("The file to rename does not exist")
|
|
360
|
+
)
|
|
361
|
+
}
|
|
362
|
+
return
|
|
363
|
+
}
|
|
364
|
+
val newFile: java_io_File = java_io_File((newPath ?: "undefined"))
|
|
365
|
+
if (newFile.exists()) {
|
|
366
|
+
if (jsTruthy(onError)) {
|
|
367
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
368
|
+
JSError("A file with the same name already exists.")
|
|
369
|
+
)
|
|
370
|
+
}
|
|
371
|
+
return
|
|
372
|
+
}
|
|
373
|
+
if (!javaFile.renameTo(newFile)) {
|
|
374
|
+
if (jsTruthy(onError)) {
|
|
375
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
376
|
+
JSError(
|
|
377
|
+
"Failed to rename file '" +
|
|
378
|
+
jsToString((path ?: "undefined")) +
|
|
379
|
+
"' to '" +
|
|
380
|
+
jsToString((newPath ?: "undefined")) +
|
|
381
|
+
"'"
|
|
382
|
+
)
|
|
383
|
+
)
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
open fun rename(path: String?, newPath: String?, onError: ((Any?) -> Any?)? = null) {
|
|
389
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
390
|
+
if (!javaFile.exists()) {
|
|
391
|
+
if (jsTruthy(onError)) {
|
|
392
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
393
|
+
JSError("The file to rename does not exist")
|
|
394
|
+
)
|
|
395
|
+
}
|
|
396
|
+
return
|
|
397
|
+
}
|
|
398
|
+
val newFile: java_io_File = java_io_File((newPath ?: "undefined"))
|
|
399
|
+
if (newFile.exists()) {
|
|
400
|
+
if (jsTruthy(onError)) {
|
|
401
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
402
|
+
JSError("A file with the same name already exists.")
|
|
403
|
+
)
|
|
404
|
+
}
|
|
405
|
+
return
|
|
406
|
+
}
|
|
407
|
+
if (!javaFile.renameTo(newFile)) {
|
|
408
|
+
if (jsTruthy(onError)) {
|
|
409
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
410
|
+
JSError(
|
|
411
|
+
"Failed to rename file '" +
|
|
412
|
+
jsToString((path ?: "undefined")) +
|
|
413
|
+
"' to '" +
|
|
414
|
+
jsToString((newPath ?: "undefined")) +
|
|
415
|
+
"'"
|
|
416
|
+
)
|
|
417
|
+
)
|
|
418
|
+
}
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
fun getDocumentsFolderPath__FileSystemAccess(): String {
|
|
423
|
+
val dir: java_io_File? =
|
|
424
|
+
jsCastCarried(
|
|
425
|
+
Core_application_helpers_common.getNativeApp(),
|
|
426
|
+
android_app_Application::class.java,
|
|
427
|
+
)
|
|
428
|
+
.getApplicationContext()
|
|
429
|
+
.getFilesDir()
|
|
430
|
+
return (dir ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
open fun getDocumentsFolderPath(): String {
|
|
434
|
+
val dir: java_io_File? =
|
|
435
|
+
jsCastCarried(
|
|
436
|
+
Core_application_helpers_common.getNativeApp(),
|
|
437
|
+
android_app_Application::class.java,
|
|
438
|
+
)
|
|
439
|
+
.getApplicationContext()
|
|
440
|
+
.getFilesDir()
|
|
441
|
+
return (dir ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
open fun getExternalDocumentsFolderPath(): String {
|
|
445
|
+
val dirs: JSArray<java_io_File>? =
|
|
446
|
+
JSArray(
|
|
447
|
+
jsCastCarried(
|
|
448
|
+
Core_application_helpers_common.getNativeApp(),
|
|
449
|
+
android_app_Application::class.java,
|
|
450
|
+
)
|
|
451
|
+
.getApplicationContext()
|
|
452
|
+
.getExternalFilesDirs(null)
|
|
453
|
+
.toList()
|
|
454
|
+
)
|
|
455
|
+
var dir: Any? = null
|
|
456
|
+
if ((jsTruthy(dirs) && (dirs ?: jsCannotRead("length")).length > 1.0)) {
|
|
457
|
+
dir =
|
|
458
|
+
(dirs ?: jsCannotRead("dirs.length - 1")).element(
|
|
459
|
+
(dirs ?: jsCannotRead("length")).length - 1.0
|
|
460
|
+
)
|
|
461
|
+
}
|
|
462
|
+
if (!jsTruthy(dir)) {
|
|
463
|
+
dir =
|
|
464
|
+
(jsCastCarried(
|
|
465
|
+
Core_application_helpers_common.getNativeApp(),
|
|
466
|
+
android_app_Application::class.java,
|
|
467
|
+
)
|
|
468
|
+
.getApplicationContext()
|
|
469
|
+
.getExternalFilesDir(null) ?: JSNull)
|
|
470
|
+
}
|
|
471
|
+
return jsConvertedStringOrEmpty(jsCallMethod(dir, "getAbsolutePath"))
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
fun getLogicalRootPath__FileSystemAccess(): String {
|
|
475
|
+
val dir: java_io_File? =
|
|
476
|
+
jsCastCarried(
|
|
477
|
+
Core_application_helpers_common.getNativeApp(),
|
|
478
|
+
android_app_Application::class.java,
|
|
479
|
+
)
|
|
480
|
+
.getApplicationContext()
|
|
481
|
+
.getFilesDir()
|
|
482
|
+
return (dir ?: jsCannotRead("getCanonicalPath")).getCanonicalPath()
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
open fun getLogicalRootPath(): String {
|
|
486
|
+
val dir: java_io_File? =
|
|
487
|
+
jsCastCarried(
|
|
488
|
+
Core_application_helpers_common.getNativeApp(),
|
|
489
|
+
android_app_Application::class.java,
|
|
490
|
+
)
|
|
491
|
+
.getApplicationContext()
|
|
492
|
+
.getFilesDir()
|
|
493
|
+
return (dir ?: jsCannotRead("getCanonicalPath")).getCanonicalPath()
|
|
494
|
+
}
|
|
495
|
+
|
|
496
|
+
fun getTempFolderPath__FileSystemAccess(): String {
|
|
497
|
+
val dir: java_io_File? =
|
|
498
|
+
jsCastCarried(
|
|
499
|
+
Core_application_helpers_common.getNativeApp(),
|
|
500
|
+
android_app_Application::class.java,
|
|
501
|
+
)
|
|
502
|
+
.getApplicationContext()
|
|
503
|
+
.getCacheDir()
|
|
504
|
+
return (dir ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
open fun getTempFolderPath(): String {
|
|
508
|
+
val dir: java_io_File? =
|
|
509
|
+
jsCastCarried(
|
|
510
|
+
Core_application_helpers_common.getNativeApp(),
|
|
511
|
+
android_app_Application::class.java,
|
|
512
|
+
)
|
|
513
|
+
.getApplicationContext()
|
|
514
|
+
.getCacheDir()
|
|
515
|
+
return (dir ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
fun getCurrentAppPath__FileSystemAccess(): String {
|
|
519
|
+
return this.getLogicalRootPath() + "/app"
|
|
520
|
+
}
|
|
521
|
+
|
|
522
|
+
open fun getCurrentAppPath(): String {
|
|
523
|
+
return this.getLogicalRootPath() + "/app"
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
open fun copySync(src: String?, dest: String?, onError: ((Any?) -> Any?)? = null): Boolean {
|
|
527
|
+
try {
|
|
528
|
+
return Async.File.copySync(
|
|
529
|
+
src,
|
|
530
|
+
dest,
|
|
531
|
+
jsCastCarried(
|
|
532
|
+
Core_application_helpers_common.getNativeApp(),
|
|
533
|
+
android_app_Application::class.java,
|
|
534
|
+
)
|
|
535
|
+
.getApplicationContext(),
|
|
536
|
+
)
|
|
537
|
+
} catch (__e_1: Throwable) {
|
|
538
|
+
val error: Any? = jsCaught(__e_1)
|
|
539
|
+
if (jsTruthy(onError)) {
|
|
540
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
541
|
+
}
|
|
542
|
+
}
|
|
543
|
+
return false
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
open fun copyAsync(src: String?, dest: String?): JSPromise<Boolean>? {
|
|
547
|
+
return JSPromise<Boolean> { __resolvers1: JSResolvers<Boolean> ->
|
|
548
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
549
|
+
try {
|
|
550
|
+
Async.File.copy(
|
|
551
|
+
src,
|
|
552
|
+
dest,
|
|
553
|
+
object : Async.CompleteCallback {
|
|
554
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
555
|
+
|
|
556
|
+
override fun onComplete(result: Any?, __a1: Any?) {
|
|
557
|
+
jsElsewhere(__realm)?.let {
|
|
558
|
+
return it.later { this.onComplete(result, __a1) }
|
|
559
|
+
}
|
|
560
|
+
jsReport {
|
|
561
|
+
__resolvers1.resolve(jsConvertedBooleanOrFalse(result))
|
|
562
|
+
}
|
|
563
|
+
}
|
|
564
|
+
|
|
565
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
566
|
+
jsElsewhere(__realm)?.let {
|
|
567
|
+
return it.later { this.onError(err, __a1) }
|
|
568
|
+
}
|
|
569
|
+
jsReport {
|
|
570
|
+
val err: Any? = err
|
|
571
|
+
reject(err)
|
|
572
|
+
}
|
|
573
|
+
}
|
|
574
|
+
},
|
|
575
|
+
jsCastCarried(
|
|
576
|
+
Core_application_helpers_common.getNativeApp(),
|
|
577
|
+
android_app_Application::class.java,
|
|
578
|
+
)
|
|
579
|
+
.getApplicationContext(),
|
|
580
|
+
)
|
|
581
|
+
} catch (__e_1: Throwable) {
|
|
582
|
+
val ex: Any? = jsCaught(__e_1)
|
|
583
|
+
reject(ex)
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
fun readBufferAsync__FileSystemAccess(path: String?): JSPromise<JSArrayBuffer>? {
|
|
589
|
+
return JSPromise<JSArrayBuffer> { __resolvers1: JSResolvers<JSArrayBuffer> ->
|
|
590
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
591
|
+
try {
|
|
592
|
+
Async.File.readBuffer(
|
|
593
|
+
path,
|
|
594
|
+
object : Async.CompleteCallback {
|
|
595
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
596
|
+
|
|
597
|
+
override fun onComplete(result: Any?, __a1: Any?) {
|
|
598
|
+
jsElsewhere(__realm)?.let {
|
|
599
|
+
return it.later { this.onComplete(result, __a1) }
|
|
600
|
+
}
|
|
601
|
+
jsReport {
|
|
602
|
+
val result: ByteBuffer? = jsCast(result, ByteBuffer::class.java)
|
|
603
|
+
__resolvers1.resolve(
|
|
604
|
+
jsCastCarried(
|
|
605
|
+
JSArrayBuffer.from((result as ByteBuffer)),
|
|
606
|
+
JSArrayBuffer::class.java,
|
|
607
|
+
)
|
|
608
|
+
)
|
|
609
|
+
}
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
613
|
+
jsElsewhere(__realm)?.let {
|
|
614
|
+
return it.later { this.onError(err, __a1) }
|
|
615
|
+
}
|
|
616
|
+
jsReport {
|
|
617
|
+
val err: Any? = err
|
|
618
|
+
reject(err)
|
|
619
|
+
}
|
|
620
|
+
}
|
|
621
|
+
},
|
|
622
|
+
null,
|
|
623
|
+
)
|
|
624
|
+
} catch (__e_1: Throwable) {
|
|
625
|
+
val ex: Any? = jsCaught(__e_1)
|
|
626
|
+
reject(ex)
|
|
627
|
+
}
|
|
628
|
+
}
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
open fun readBufferAsync(path: String?): JSPromise<JSArrayBuffer>? {
|
|
632
|
+
return JSPromise<JSArrayBuffer> { __resolvers1: JSResolvers<JSArrayBuffer> ->
|
|
633
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
634
|
+
try {
|
|
635
|
+
Async.File.readBuffer(
|
|
636
|
+
path,
|
|
637
|
+
object : Async.CompleteCallback {
|
|
638
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
639
|
+
|
|
640
|
+
override fun onComplete(result: Any?, __a1: Any?) {
|
|
641
|
+
jsElsewhere(__realm)?.let {
|
|
642
|
+
return it.later { this.onComplete(result, __a1) }
|
|
643
|
+
}
|
|
644
|
+
jsReport {
|
|
645
|
+
val result: ByteBuffer? = jsCast(result, ByteBuffer::class.java)
|
|
646
|
+
__resolvers1.resolve(
|
|
647
|
+
jsCastCarried(
|
|
648
|
+
JSArrayBuffer.from((result as ByteBuffer)),
|
|
649
|
+
JSArrayBuffer::class.java,
|
|
650
|
+
)
|
|
651
|
+
)
|
|
652
|
+
}
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
656
|
+
jsElsewhere(__realm)?.let {
|
|
657
|
+
return it.later { this.onError(err, __a1) }
|
|
658
|
+
}
|
|
659
|
+
jsReport {
|
|
660
|
+
val err: Any? = err
|
|
661
|
+
reject(err)
|
|
662
|
+
}
|
|
663
|
+
}
|
|
664
|
+
},
|
|
665
|
+
null,
|
|
666
|
+
)
|
|
667
|
+
} catch (__e_1: Throwable) {
|
|
668
|
+
val ex: Any? = jsCaught(__e_1)
|
|
669
|
+
reject(ex)
|
|
670
|
+
}
|
|
671
|
+
}
|
|
672
|
+
}
|
|
673
|
+
|
|
674
|
+
fun readBufferSync__FileSystemAccess(
|
|
675
|
+
path: String?,
|
|
676
|
+
onError: ((Any?) -> Any?)? = null,
|
|
677
|
+
): JSArrayBuffer? {
|
|
678
|
+
try {
|
|
679
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
680
|
+
val stream: FileInputStream = FileInputStream(javaFile)
|
|
681
|
+
val channel: FileChannel? = stream.getChannel()
|
|
682
|
+
val buffer: JSArrayBuffer = JSArrayBuffer(javaFile.length().toDouble())
|
|
683
|
+
jsConvertedNumberOrZero(jsCallMethod(channel, "read", buffer))
|
|
684
|
+
return buffer
|
|
685
|
+
} catch (__e_1: Throwable) {
|
|
686
|
+
val exception: Any? = jsCaught(__e_1)
|
|
687
|
+
if (jsTruthy(onError)) {
|
|
688
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
689
|
+
}
|
|
690
|
+
}
|
|
691
|
+
return null
|
|
692
|
+
}
|
|
693
|
+
|
|
694
|
+
open fun readBufferSync(path: String?, onError: ((Any?) -> Any?)? = null): JSArrayBuffer? {
|
|
695
|
+
try {
|
|
696
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
697
|
+
val stream: FileInputStream = FileInputStream(javaFile)
|
|
698
|
+
val channel: FileChannel? = stream.getChannel()
|
|
699
|
+
val buffer: JSArrayBuffer = JSArrayBuffer(javaFile.length().toDouble())
|
|
700
|
+
jsConvertedNumberOrZero(jsCallMethod(channel, "read", buffer))
|
|
701
|
+
return buffer
|
|
702
|
+
} catch (__e_1: Throwable) {
|
|
703
|
+
val exception: Any? = jsCaught(__e_1)
|
|
704
|
+
if (jsTruthy(onError)) {
|
|
705
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
706
|
+
}
|
|
707
|
+
}
|
|
708
|
+
return null
|
|
709
|
+
}
|
|
710
|
+
|
|
711
|
+
fun readAsync__FileSystemAccess(path: String?): JSPromise<JSArray<Double>>? {
|
|
712
|
+
return JSPromise<JSArray<Double>> { __resolvers1: JSResolvers<JSArray<Double>>
|
|
713
|
+
->
|
|
714
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
715
|
+
try {
|
|
716
|
+
Async.File.read(
|
|
717
|
+
path,
|
|
718
|
+
object : Async.CompleteCallback {
|
|
719
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
720
|
+
|
|
721
|
+
override fun onComplete(result: Any?, __a1: Any?) {
|
|
722
|
+
jsElsewhere(__realm)?.let {
|
|
723
|
+
return it.later { this.onComplete(result, __a1) }
|
|
724
|
+
}
|
|
725
|
+
jsReport {
|
|
726
|
+
val result: JSArray<Double>? =
|
|
727
|
+
(if (jsIsNullish(result)) null
|
|
728
|
+
else jsArrayFrom(result) { jsConvertedNumber(it) })
|
|
729
|
+
__resolvers1.resolve((result ?: jsObjectRequired()))
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
|
|
733
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
734
|
+
jsElsewhere(__realm)?.let {
|
|
735
|
+
return it.later { this.onError(err, __a1) }
|
|
736
|
+
}
|
|
737
|
+
jsReport {
|
|
738
|
+
val err: Any? = err
|
|
739
|
+
reject(err)
|
|
740
|
+
}
|
|
741
|
+
}
|
|
742
|
+
},
|
|
743
|
+
null,
|
|
744
|
+
)
|
|
745
|
+
} catch (__e_1: Throwable) {
|
|
746
|
+
val ex: Any? = jsCaught(__e_1)
|
|
747
|
+
reject(ex)
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
}
|
|
751
|
+
|
|
752
|
+
open fun readAsync(path: String?): JSPromise<JSArray<Double>>? {
|
|
753
|
+
return JSPromise<JSArray<Double>> { __resolvers1: JSResolvers<JSArray<Double>>
|
|
754
|
+
->
|
|
755
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
756
|
+
try {
|
|
757
|
+
Async.File.read(
|
|
758
|
+
path,
|
|
759
|
+
object : Async.CompleteCallback {
|
|
760
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
761
|
+
|
|
762
|
+
override fun onComplete(result: Any?, __a1: Any?) {
|
|
763
|
+
jsElsewhere(__realm)?.let {
|
|
764
|
+
return it.later { this.onComplete(result, __a1) }
|
|
765
|
+
}
|
|
766
|
+
jsReport {
|
|
767
|
+
val result: JSArray<Double>? =
|
|
768
|
+
(if (jsIsNullish(result)) null
|
|
769
|
+
else jsArrayFrom(result) { jsConvertedNumber(it) })
|
|
770
|
+
__resolvers1.resolve((result ?: jsObjectRequired()))
|
|
771
|
+
}
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
775
|
+
jsElsewhere(__realm)?.let {
|
|
776
|
+
return it.later { this.onError(err, __a1) }
|
|
777
|
+
}
|
|
778
|
+
jsReport {
|
|
779
|
+
val err: Any? = err
|
|
780
|
+
reject(err)
|
|
781
|
+
}
|
|
782
|
+
}
|
|
783
|
+
},
|
|
784
|
+
null,
|
|
785
|
+
)
|
|
786
|
+
} catch (__e_1: Throwable) {
|
|
787
|
+
val ex: Any? = jsCaught(__e_1)
|
|
788
|
+
reject(ex)
|
|
789
|
+
}
|
|
790
|
+
}
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
fun readSync__FileSystemAccess(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
794
|
+
try {
|
|
795
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
796
|
+
val stream: FileInputStream = FileInputStream(javaFile)
|
|
797
|
+
val bytes: Any? = jsArrayCreate("byte", javaFile.length().toDouble())
|
|
798
|
+
val dataInputStream: DataInputStream = DataInputStream(stream)
|
|
799
|
+
dataInputStream.readFully(
|
|
800
|
+
(toJavaValue(bytes, ByteArray::class.java) as ByteArray?)
|
|
801
|
+
)
|
|
802
|
+
return bytes
|
|
803
|
+
} catch (__e_1: Throwable) {
|
|
804
|
+
val exception: Any? = jsCaught(__e_1)
|
|
805
|
+
if (jsTruthy(onError)) {
|
|
806
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
807
|
+
}
|
|
808
|
+
}
|
|
809
|
+
return null
|
|
810
|
+
}
|
|
811
|
+
|
|
812
|
+
open fun readSync(path: String?, onError: ((Any?) -> Any?)? = null): Any? {
|
|
813
|
+
try {
|
|
814
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
815
|
+
val stream: FileInputStream = FileInputStream(javaFile)
|
|
816
|
+
val bytes: Any? = jsArrayCreate("byte", javaFile.length().toDouble())
|
|
817
|
+
val dataInputStream: DataInputStream = DataInputStream(stream)
|
|
818
|
+
dataInputStream.readFully(
|
|
819
|
+
(toJavaValue(bytes, ByteArray::class.java) as ByteArray?)
|
|
820
|
+
)
|
|
821
|
+
return bytes
|
|
822
|
+
} catch (__e_1: Throwable) {
|
|
823
|
+
val exception: Any? = jsCaught(__e_1)
|
|
824
|
+
if (jsTruthy(onError)) {
|
|
825
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
826
|
+
}
|
|
827
|
+
}
|
|
828
|
+
return null
|
|
829
|
+
}
|
|
830
|
+
|
|
831
|
+
fun appendBufferAsync__FileSystemAccess(path: String?, buffer: Any?): JSPromise<Unit>? {
|
|
832
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
833
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
834
|
+
try {
|
|
835
|
+
Async.File.appendBuffer(
|
|
836
|
+
path,
|
|
837
|
+
(FileSystemAccess.getBuffer(buffer) as ByteBuffer?),
|
|
838
|
+
object : Async.CompleteCallback {
|
|
839
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
840
|
+
|
|
841
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
842
|
+
jsElsewhere(__realm)?.let {
|
|
843
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
844
|
+
}
|
|
845
|
+
jsReport {
|
|
846
|
+
__resolvers1.resolve(Unit)
|
|
847
|
+
}
|
|
848
|
+
}
|
|
849
|
+
|
|
850
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
851
|
+
jsElsewhere(__realm)?.let {
|
|
852
|
+
return it.later { this.onError(err, __a1) }
|
|
853
|
+
}
|
|
854
|
+
jsReport {
|
|
855
|
+
val err: Any? = err
|
|
856
|
+
reject(err)
|
|
857
|
+
}
|
|
858
|
+
}
|
|
859
|
+
},
|
|
860
|
+
null,
|
|
861
|
+
)
|
|
862
|
+
} catch (__e_1: Throwable) {
|
|
863
|
+
val ex: Any? = jsCaught(__e_1)
|
|
864
|
+
reject(ex)
|
|
865
|
+
}
|
|
866
|
+
}
|
|
867
|
+
}
|
|
868
|
+
|
|
869
|
+
open fun appendBufferAsync(path: String?, buffer: Any?): JSPromise<Unit>? {
|
|
870
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
871
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
872
|
+
try {
|
|
873
|
+
Async.File.appendBuffer(
|
|
874
|
+
path,
|
|
875
|
+
(FileSystemAccess.getBuffer(buffer) as ByteBuffer?),
|
|
876
|
+
object : Async.CompleteCallback {
|
|
877
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
878
|
+
|
|
879
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
880
|
+
jsElsewhere(__realm)?.let {
|
|
881
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
882
|
+
}
|
|
883
|
+
jsReport {
|
|
884
|
+
__resolvers1.resolve(Unit)
|
|
885
|
+
}
|
|
886
|
+
}
|
|
887
|
+
|
|
888
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
889
|
+
jsElsewhere(__realm)?.let {
|
|
890
|
+
return it.later { this.onError(err, __a1) }
|
|
891
|
+
}
|
|
892
|
+
jsReport {
|
|
893
|
+
val err: Any? = err
|
|
894
|
+
reject(err)
|
|
895
|
+
}
|
|
896
|
+
}
|
|
897
|
+
},
|
|
898
|
+
null,
|
|
899
|
+
)
|
|
900
|
+
} catch (__e_1: Throwable) {
|
|
901
|
+
val ex: Any? = jsCaught(__e_1)
|
|
902
|
+
reject(ex)
|
|
903
|
+
}
|
|
904
|
+
}
|
|
905
|
+
}
|
|
906
|
+
|
|
907
|
+
fun appendBufferSync__FileSystemAccess(
|
|
908
|
+
path: String?,
|
|
909
|
+
buffer: Any?,
|
|
910
|
+
onError: ((Any?) -> Any?)? = null,
|
|
911
|
+
) {
|
|
912
|
+
try {
|
|
913
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
914
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
915
|
+
val channel: FileChannel? = stream.getChannel()
|
|
916
|
+
jsConvertedNumberOrZero(
|
|
917
|
+
jsCallMethod(channel, "write", FileSystemAccess.getBuffer(buffer))
|
|
918
|
+
)
|
|
919
|
+
stream.close()
|
|
920
|
+
} catch (__e_1: Throwable) {
|
|
921
|
+
val exception: Any? = jsCaught(__e_1)
|
|
922
|
+
if (jsTruthy(onError)) {
|
|
923
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
924
|
+
}
|
|
925
|
+
}
|
|
926
|
+
}
|
|
927
|
+
|
|
928
|
+
open fun appendBufferSync(path: String?, buffer: Any?, onError: ((Any?) -> Any?)? = null) {
|
|
929
|
+
try {
|
|
930
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
931
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
932
|
+
val channel: FileChannel? = stream.getChannel()
|
|
933
|
+
jsConvertedNumberOrZero(
|
|
934
|
+
jsCallMethod(channel, "write", FileSystemAccess.getBuffer(buffer))
|
|
935
|
+
)
|
|
936
|
+
stream.close()
|
|
937
|
+
} catch (__e_1: Throwable) {
|
|
938
|
+
val exception: Any? = jsCaught(__e_1)
|
|
939
|
+
if (jsTruthy(onError)) {
|
|
940
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
941
|
+
}
|
|
942
|
+
}
|
|
943
|
+
}
|
|
944
|
+
|
|
945
|
+
fun appendAsync__FileSystemAccess(path: String?, bytes: JSArray<Double>?): JSPromise<Unit>? {
|
|
946
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
947
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
948
|
+
try {
|
|
949
|
+
Async.File.append(
|
|
950
|
+
path,
|
|
951
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
952
|
+
object : Async.CompleteCallback {
|
|
953
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
954
|
+
|
|
955
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
956
|
+
jsElsewhere(__realm)?.let {
|
|
957
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
958
|
+
}
|
|
959
|
+
jsReport {
|
|
960
|
+
__resolvers1.resolve(Unit)
|
|
961
|
+
}
|
|
962
|
+
}
|
|
963
|
+
|
|
964
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
965
|
+
jsElsewhere(__realm)?.let {
|
|
966
|
+
return it.later { this.onError(err, __a1) }
|
|
967
|
+
}
|
|
968
|
+
jsReport {
|
|
969
|
+
val err: Any? = err
|
|
970
|
+
reject(err)
|
|
971
|
+
}
|
|
972
|
+
}
|
|
973
|
+
},
|
|
974
|
+
null,
|
|
975
|
+
)
|
|
976
|
+
} catch (__e_1: Throwable) {
|
|
977
|
+
val ex: Any? = jsCaught(__e_1)
|
|
978
|
+
reject(ex)
|
|
979
|
+
}
|
|
980
|
+
}
|
|
981
|
+
}
|
|
982
|
+
|
|
983
|
+
open fun appendAsync(path: String?, bytes: JSArray<Double>?): JSPromise<Unit>? {
|
|
984
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
985
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
986
|
+
try {
|
|
987
|
+
Async.File.append(
|
|
988
|
+
path,
|
|
989
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
990
|
+
object : Async.CompleteCallback {
|
|
991
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
992
|
+
|
|
993
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
994
|
+
jsElsewhere(__realm)?.let {
|
|
995
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
996
|
+
}
|
|
997
|
+
jsReport {
|
|
998
|
+
__resolvers1.resolve(Unit)
|
|
999
|
+
}
|
|
1000
|
+
}
|
|
1001
|
+
|
|
1002
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1003
|
+
jsElsewhere(__realm)?.let {
|
|
1004
|
+
return it.later { this.onError(err, __a1) }
|
|
1005
|
+
}
|
|
1006
|
+
jsReport {
|
|
1007
|
+
val err: Any? = err
|
|
1008
|
+
reject(err)
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
},
|
|
1012
|
+
null,
|
|
1013
|
+
)
|
|
1014
|
+
} catch (__e_1: Throwable) {
|
|
1015
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1016
|
+
reject(ex)
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
}
|
|
1020
|
+
|
|
1021
|
+
fun appendSync__FileSystemAccess(
|
|
1022
|
+
path: String?,
|
|
1023
|
+
bytes: JSArray<Double>?,
|
|
1024
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1025
|
+
) {
|
|
1026
|
+
try {
|
|
1027
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1028
|
+
val stream: FileOutputStream = FileOutputStream(javaFile, true)
|
|
1029
|
+
stream.write(
|
|
1030
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
1031
|
+
0,
|
|
1032
|
+
(bytes ?: jsCannotRead("length")).length.toLong().toInt(),
|
|
1033
|
+
)
|
|
1034
|
+
stream.close()
|
|
1035
|
+
} catch (__e_1: Throwable) {
|
|
1036
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1037
|
+
if (jsTruthy(onError)) {
|
|
1038
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1039
|
+
}
|
|
1040
|
+
}
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
open fun appendSync(path: String?, bytes: JSArray<Double>?, onError: ((Any?) -> Any?)? = null) {
|
|
1044
|
+
try {
|
|
1045
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1046
|
+
val stream: FileOutputStream = FileOutputStream(javaFile, true)
|
|
1047
|
+
stream.write(
|
|
1048
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
1049
|
+
0,
|
|
1050
|
+
(bytes ?: jsCannotRead("length")).length.toLong().toInt(),
|
|
1051
|
+
)
|
|
1052
|
+
stream.close()
|
|
1053
|
+
} catch (__e_1: Throwable) {
|
|
1054
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1055
|
+
if (jsTruthy(onError)) {
|
|
1056
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1057
|
+
}
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
|
|
1061
|
+
fun writeBufferAsync__FileSystemAccess(path: String?, buffer: Any?): JSPromise<Unit>? {
|
|
1062
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1063
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1064
|
+
try {
|
|
1065
|
+
Async.File.writeBuffer(
|
|
1066
|
+
path,
|
|
1067
|
+
(FileSystemAccess.getBuffer(buffer) as ByteBuffer?),
|
|
1068
|
+
object : Async.CompleteCallback {
|
|
1069
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1070
|
+
|
|
1071
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1072
|
+
jsElsewhere(__realm)?.let {
|
|
1073
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1074
|
+
}
|
|
1075
|
+
jsReport {
|
|
1076
|
+
__resolvers1.resolve(Unit)
|
|
1077
|
+
}
|
|
1078
|
+
}
|
|
1079
|
+
|
|
1080
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1081
|
+
jsElsewhere(__realm)?.let {
|
|
1082
|
+
return it.later { this.onError(err, __a1) }
|
|
1083
|
+
}
|
|
1084
|
+
jsReport {
|
|
1085
|
+
val err: Any? = err
|
|
1086
|
+
reject(err)
|
|
1087
|
+
}
|
|
1088
|
+
}
|
|
1089
|
+
},
|
|
1090
|
+
null,
|
|
1091
|
+
)
|
|
1092
|
+
} catch (__e_1: Throwable) {
|
|
1093
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1094
|
+
reject(ex)
|
|
1095
|
+
}
|
|
1096
|
+
}
|
|
1097
|
+
}
|
|
1098
|
+
|
|
1099
|
+
open fun writeBufferAsync(path: String?, buffer: Any?): JSPromise<Unit>? {
|
|
1100
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1101
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1102
|
+
try {
|
|
1103
|
+
Async.File.writeBuffer(
|
|
1104
|
+
path,
|
|
1105
|
+
(FileSystemAccess.getBuffer(buffer) as ByteBuffer?),
|
|
1106
|
+
object : Async.CompleteCallback {
|
|
1107
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1108
|
+
|
|
1109
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1110
|
+
jsElsewhere(__realm)?.let {
|
|
1111
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1112
|
+
}
|
|
1113
|
+
jsReport {
|
|
1114
|
+
__resolvers1.resolve(Unit)
|
|
1115
|
+
}
|
|
1116
|
+
}
|
|
1117
|
+
|
|
1118
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1119
|
+
jsElsewhere(__realm)?.let {
|
|
1120
|
+
return it.later { this.onError(err, __a1) }
|
|
1121
|
+
}
|
|
1122
|
+
jsReport {
|
|
1123
|
+
val err: Any? = err
|
|
1124
|
+
reject(err)
|
|
1125
|
+
}
|
|
1126
|
+
}
|
|
1127
|
+
},
|
|
1128
|
+
null,
|
|
1129
|
+
)
|
|
1130
|
+
} catch (__e_1: Throwable) {
|
|
1131
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1132
|
+
reject(ex)
|
|
1133
|
+
}
|
|
1134
|
+
}
|
|
1135
|
+
}
|
|
1136
|
+
|
|
1137
|
+
fun writeBufferSync__FileSystemAccess(
|
|
1138
|
+
path: String?,
|
|
1139
|
+
buffer: Any?,
|
|
1140
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1141
|
+
) {
|
|
1142
|
+
try {
|
|
1143
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1144
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
1145
|
+
val channel: FileChannel? = stream.getChannel()
|
|
1146
|
+
jsConvertedNumberOrZero(
|
|
1147
|
+
jsCallMethod(channel, "write", FileSystemAccess.getBuffer(buffer))
|
|
1148
|
+
)
|
|
1149
|
+
stream.close()
|
|
1150
|
+
} catch (__e_1: Throwable) {
|
|
1151
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1152
|
+
if (jsTruthy(onError)) {
|
|
1153
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1154
|
+
}
|
|
1155
|
+
}
|
|
1156
|
+
}
|
|
1157
|
+
|
|
1158
|
+
open fun writeBufferSync(path: String?, buffer: Any?, onError: ((Any?) -> Any?)? = null) {
|
|
1159
|
+
try {
|
|
1160
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1161
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
1162
|
+
val channel: FileChannel? = stream.getChannel()
|
|
1163
|
+
jsConvertedNumberOrZero(
|
|
1164
|
+
jsCallMethod(channel, "write", FileSystemAccess.getBuffer(buffer))
|
|
1165
|
+
)
|
|
1166
|
+
stream.close()
|
|
1167
|
+
} catch (__e_1: Throwable) {
|
|
1168
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1169
|
+
if (jsTruthy(onError)) {
|
|
1170
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1171
|
+
}
|
|
1172
|
+
}
|
|
1173
|
+
}
|
|
1174
|
+
|
|
1175
|
+
fun writeAsync__FileSystemAccess(path: String?, bytes: JSArray<Double>?): JSPromise<Unit>? {
|
|
1176
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1177
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1178
|
+
try {
|
|
1179
|
+
Async.File.write(
|
|
1180
|
+
path,
|
|
1181
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
1182
|
+
object : Async.CompleteCallback {
|
|
1183
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1184
|
+
|
|
1185
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1186
|
+
jsElsewhere(__realm)?.let {
|
|
1187
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1188
|
+
}
|
|
1189
|
+
jsReport {
|
|
1190
|
+
__resolvers1.resolve(Unit)
|
|
1191
|
+
}
|
|
1192
|
+
}
|
|
1193
|
+
|
|
1194
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1195
|
+
jsElsewhere(__realm)?.let {
|
|
1196
|
+
return it.later { this.onError(err, __a1) }
|
|
1197
|
+
}
|
|
1198
|
+
jsReport {
|
|
1199
|
+
val err: Any? = err
|
|
1200
|
+
reject(err)
|
|
1201
|
+
}
|
|
1202
|
+
}
|
|
1203
|
+
},
|
|
1204
|
+
null,
|
|
1205
|
+
)
|
|
1206
|
+
} catch (__e_1: Throwable) {
|
|
1207
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1208
|
+
reject(ex)
|
|
1209
|
+
}
|
|
1210
|
+
}
|
|
1211
|
+
}
|
|
1212
|
+
|
|
1213
|
+
open fun writeAsync(path: String?, bytes: JSArray<Double>?): JSPromise<Unit>? {
|
|
1214
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1215
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1216
|
+
try {
|
|
1217
|
+
Async.File.write(
|
|
1218
|
+
path,
|
|
1219
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
1220
|
+
object : Async.CompleteCallback {
|
|
1221
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1222
|
+
|
|
1223
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1224
|
+
jsElsewhere(__realm)?.let {
|
|
1225
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1226
|
+
}
|
|
1227
|
+
jsReport {
|
|
1228
|
+
__resolvers1.resolve(Unit)
|
|
1229
|
+
}
|
|
1230
|
+
}
|
|
1231
|
+
|
|
1232
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1233
|
+
jsElsewhere(__realm)?.let {
|
|
1234
|
+
return it.later { this.onError(err, __a1) }
|
|
1235
|
+
}
|
|
1236
|
+
jsReport {
|
|
1237
|
+
val err: Any? = err
|
|
1238
|
+
reject(err)
|
|
1239
|
+
}
|
|
1240
|
+
}
|
|
1241
|
+
},
|
|
1242
|
+
null,
|
|
1243
|
+
)
|
|
1244
|
+
} catch (__e_1: Throwable) {
|
|
1245
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1246
|
+
reject(ex)
|
|
1247
|
+
}
|
|
1248
|
+
}
|
|
1249
|
+
}
|
|
1250
|
+
|
|
1251
|
+
fun writeSync__FileSystemAccess(
|
|
1252
|
+
path: String?,
|
|
1253
|
+
bytes: JSArray<Double>?,
|
|
1254
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1255
|
+
) {
|
|
1256
|
+
try {
|
|
1257
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1258
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
1259
|
+
stream.write(
|
|
1260
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
1261
|
+
0,
|
|
1262
|
+
(bytes ?: jsCannotRead("length")).length.toLong().toInt(),
|
|
1263
|
+
)
|
|
1264
|
+
stream.close()
|
|
1265
|
+
} catch (__e_1: Throwable) {
|
|
1266
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1267
|
+
if (jsTruthy(onError)) {
|
|
1268
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1269
|
+
}
|
|
1270
|
+
}
|
|
1271
|
+
}
|
|
1272
|
+
|
|
1273
|
+
open fun writeSync(path: String?, bytes: JSArray<Double>?, onError: ((Any?) -> Any?)? = null) {
|
|
1274
|
+
try {
|
|
1275
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1276
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
1277
|
+
stream.write(
|
|
1278
|
+
bytes?.elements?.map { it.toLong().toByte() }?.toByteArray(),
|
|
1279
|
+
0,
|
|
1280
|
+
(bytes ?: jsCannotRead("length")).length.toLong().toInt(),
|
|
1281
|
+
)
|
|
1282
|
+
stream.close()
|
|
1283
|
+
} catch (__e_1: Throwable) {
|
|
1284
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1285
|
+
if (jsTruthy(onError)) {
|
|
1286
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1287
|
+
}
|
|
1288
|
+
}
|
|
1289
|
+
}
|
|
1290
|
+
|
|
1291
|
+
fun readTextAsync__FileSystemAccess(path: String?, encoding: Any? = null): JSPromise<String>? {
|
|
1292
|
+
var actualEncoding: Any? = encoding
|
|
1293
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1294
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1295
|
+
}
|
|
1296
|
+
return JSPromise<String> { __resolvers1: JSResolvers<String> ->
|
|
1297
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1298
|
+
try {
|
|
1299
|
+
Async.File.readText(
|
|
1300
|
+
path,
|
|
1301
|
+
(actualEncoding as String?),
|
|
1302
|
+
object : Async.CompleteCallback {
|
|
1303
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1304
|
+
|
|
1305
|
+
override fun onComplete(result: Any, __a1: Any?) {
|
|
1306
|
+
jsElsewhere(__realm)?.let {
|
|
1307
|
+
return it.later { this.onComplete(result, __a1) }
|
|
1308
|
+
}
|
|
1309
|
+
jsReport {
|
|
1310
|
+
val result: String = jsConvertedStringOrEmpty(result)
|
|
1311
|
+
kotlin.run {
|
|
1312
|
+
var result = result
|
|
1313
|
+
if (
|
|
1314
|
+
jsStrictEquals(
|
|
1315
|
+
actualEncoding,
|
|
1316
|
+
org.nativescript.kit.encoding.UTF_8,
|
|
1317
|
+
)
|
|
1318
|
+
) {
|
|
1319
|
+
result =
|
|
1320
|
+
FileSystemAccess._removeUtf8Bom(result)
|
|
1321
|
+
}
|
|
1322
|
+
__resolvers1.resolve((result ?: "undefined"))
|
|
1323
|
+
}
|
|
1324
|
+
}
|
|
1325
|
+
}
|
|
1326
|
+
|
|
1327
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1328
|
+
jsElsewhere(__realm)?.let {
|
|
1329
|
+
return it.later { this.onError(err, __a1) }
|
|
1330
|
+
}
|
|
1331
|
+
jsReport {
|
|
1332
|
+
val err: Any? = err
|
|
1333
|
+
reject(err)
|
|
1334
|
+
}
|
|
1335
|
+
}
|
|
1336
|
+
},
|
|
1337
|
+
null,
|
|
1338
|
+
)
|
|
1339
|
+
} catch (__e_1: Throwable) {
|
|
1340
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1341
|
+
reject(ex)
|
|
1342
|
+
}
|
|
1343
|
+
}
|
|
1344
|
+
}
|
|
1345
|
+
|
|
1346
|
+
open fun readTextAsync(path: String?, encoding: Any? = null): JSPromise<String>? {
|
|
1347
|
+
var actualEncoding: Any? = encoding
|
|
1348
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1349
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1350
|
+
}
|
|
1351
|
+
return JSPromise<String> { __resolvers1: JSResolvers<String> ->
|
|
1352
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1353
|
+
try {
|
|
1354
|
+
Async.File.readText(
|
|
1355
|
+
path,
|
|
1356
|
+
(actualEncoding as String?),
|
|
1357
|
+
object : Async.CompleteCallback {
|
|
1358
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1359
|
+
|
|
1360
|
+
override fun onComplete(result: Any, __a1: Any?) {
|
|
1361
|
+
jsElsewhere(__realm)?.let {
|
|
1362
|
+
return it.later { this.onComplete(result, __a1) }
|
|
1363
|
+
}
|
|
1364
|
+
jsReport {
|
|
1365
|
+
val result: String = jsConvertedStringOrEmpty(result)
|
|
1366
|
+
kotlin.run {
|
|
1367
|
+
var result = result
|
|
1368
|
+
if (
|
|
1369
|
+
jsStrictEquals(
|
|
1370
|
+
actualEncoding,
|
|
1371
|
+
org.nativescript.kit.encoding.UTF_8,
|
|
1372
|
+
)
|
|
1373
|
+
) {
|
|
1374
|
+
result =
|
|
1375
|
+
FileSystemAccess._removeUtf8Bom(result)
|
|
1376
|
+
}
|
|
1377
|
+
__resolvers1.resolve((result ?: "undefined"))
|
|
1378
|
+
}
|
|
1379
|
+
}
|
|
1380
|
+
}
|
|
1381
|
+
|
|
1382
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1383
|
+
jsElsewhere(__realm)?.let {
|
|
1384
|
+
return it.later { this.onError(err, __a1) }
|
|
1385
|
+
}
|
|
1386
|
+
jsReport {
|
|
1387
|
+
val err: Any? = err
|
|
1388
|
+
reject(err)
|
|
1389
|
+
}
|
|
1390
|
+
}
|
|
1391
|
+
},
|
|
1392
|
+
null,
|
|
1393
|
+
)
|
|
1394
|
+
} catch (__e_1: Throwable) {
|
|
1395
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1396
|
+
reject(ex)
|
|
1397
|
+
}
|
|
1398
|
+
}
|
|
1399
|
+
}
|
|
1400
|
+
|
|
1401
|
+
fun readTextSync__FileSystemAccess(
|
|
1402
|
+
path: String?,
|
|
1403
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1404
|
+
encoding: Any? = null,
|
|
1405
|
+
): String {
|
|
1406
|
+
try {
|
|
1407
|
+
var actualEncoding: Any? = encoding
|
|
1408
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1409
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1410
|
+
}
|
|
1411
|
+
var result: String =
|
|
1412
|
+
jsConvertedStringOrEmpty(
|
|
1413
|
+
jsCallMethod(FileSystemAccess._readAllBytes(path), "toString", actualEncoding)
|
|
1414
|
+
)
|
|
1415
|
+
if (jsStrictEquals(actualEncoding, org.nativescript.kit.encoding.UTF_8)) {
|
|
1416
|
+
result = FileSystemAccess._removeUtf8Bom(result)
|
|
1417
|
+
}
|
|
1418
|
+
return result
|
|
1419
|
+
} catch (__e_1: Throwable) {
|
|
1420
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1421
|
+
if (jsTruthy(onError)) {
|
|
1422
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1423
|
+
}
|
|
1424
|
+
}
|
|
1425
|
+
jsThrow(JSTypeError("no value returned where the declared type needs one"))
|
|
1426
|
+
}
|
|
1427
|
+
|
|
1428
|
+
open fun readTextSync(
|
|
1429
|
+
path: String?,
|
|
1430
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1431
|
+
encoding: Any? = null,
|
|
1432
|
+
): String {
|
|
1433
|
+
try {
|
|
1434
|
+
var actualEncoding: Any? = encoding
|
|
1435
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1436
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1437
|
+
}
|
|
1438
|
+
var result: String =
|
|
1439
|
+
jsConvertedStringOrEmpty(
|
|
1440
|
+
jsCallMethod(FileSystemAccess._readAllBytes(path), "toString", actualEncoding)
|
|
1441
|
+
)
|
|
1442
|
+
if (jsStrictEquals(actualEncoding, org.nativescript.kit.encoding.UTF_8)) {
|
|
1443
|
+
result = FileSystemAccess._removeUtf8Bom(result)
|
|
1444
|
+
}
|
|
1445
|
+
return result
|
|
1446
|
+
} catch (__e_1: Throwable) {
|
|
1447
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1448
|
+
if (jsTruthy(onError)) {
|
|
1449
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1450
|
+
}
|
|
1451
|
+
}
|
|
1452
|
+
jsThrow(JSTypeError("no value returned where the declared type needs one"))
|
|
1453
|
+
}
|
|
1454
|
+
|
|
1455
|
+
fun appendTextAsync__FileSystemAccess(
|
|
1456
|
+
path: String?,
|
|
1457
|
+
content: String?,
|
|
1458
|
+
encoding: Any? = null,
|
|
1459
|
+
): JSPromise<Unit>? {
|
|
1460
|
+
var actualEncoding: Any? = encoding
|
|
1461
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1462
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1463
|
+
}
|
|
1464
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1465
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1466
|
+
try {
|
|
1467
|
+
Async.File.appendText(
|
|
1468
|
+
path,
|
|
1469
|
+
content,
|
|
1470
|
+
(actualEncoding as String?),
|
|
1471
|
+
object : Async.CompleteCallback {
|
|
1472
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1473
|
+
|
|
1474
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1475
|
+
jsElsewhere(__realm)?.let {
|
|
1476
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1477
|
+
}
|
|
1478
|
+
jsReport {
|
|
1479
|
+
__resolvers1.resolve(Unit)
|
|
1480
|
+
}
|
|
1481
|
+
}
|
|
1482
|
+
|
|
1483
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1484
|
+
jsElsewhere(__realm)?.let {
|
|
1485
|
+
return it.later { this.onError(err, __a1) }
|
|
1486
|
+
}
|
|
1487
|
+
jsReport {
|
|
1488
|
+
val err: Any? = err
|
|
1489
|
+
reject(err)
|
|
1490
|
+
}
|
|
1491
|
+
}
|
|
1492
|
+
},
|
|
1493
|
+
null,
|
|
1494
|
+
)
|
|
1495
|
+
} catch (__e_1: Throwable) {
|
|
1496
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1497
|
+
reject(ex)
|
|
1498
|
+
}
|
|
1499
|
+
}
|
|
1500
|
+
}
|
|
1501
|
+
|
|
1502
|
+
open fun appendTextAsync(
|
|
1503
|
+
path: String?,
|
|
1504
|
+
content: String?,
|
|
1505
|
+
encoding: Any? = null,
|
|
1506
|
+
): JSPromise<Unit>? {
|
|
1507
|
+
var actualEncoding: Any? = encoding
|
|
1508
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1509
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1510
|
+
}
|
|
1511
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1512
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1513
|
+
try {
|
|
1514
|
+
Async.File.appendText(
|
|
1515
|
+
path,
|
|
1516
|
+
content,
|
|
1517
|
+
(actualEncoding as String?),
|
|
1518
|
+
object : Async.CompleteCallback {
|
|
1519
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1520
|
+
|
|
1521
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1522
|
+
jsElsewhere(__realm)?.let {
|
|
1523
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1524
|
+
}
|
|
1525
|
+
jsReport {
|
|
1526
|
+
__resolvers1.resolve(Unit)
|
|
1527
|
+
}
|
|
1528
|
+
}
|
|
1529
|
+
|
|
1530
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1531
|
+
jsElsewhere(__realm)?.let {
|
|
1532
|
+
return it.later { this.onError(err, __a1) }
|
|
1533
|
+
}
|
|
1534
|
+
jsReport {
|
|
1535
|
+
val err: Any? = err
|
|
1536
|
+
reject(err)
|
|
1537
|
+
}
|
|
1538
|
+
}
|
|
1539
|
+
},
|
|
1540
|
+
null,
|
|
1541
|
+
)
|
|
1542
|
+
} catch (__e_1: Throwable) {
|
|
1543
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1544
|
+
reject(ex)
|
|
1545
|
+
}
|
|
1546
|
+
}
|
|
1547
|
+
}
|
|
1548
|
+
|
|
1549
|
+
fun appendTextSync__FileSystemAccess(
|
|
1550
|
+
path: String?,
|
|
1551
|
+
content: String?,
|
|
1552
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1553
|
+
encoding: Any? = null,
|
|
1554
|
+
) {
|
|
1555
|
+
try {
|
|
1556
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1557
|
+
val stream: FileOutputStream = FileOutputStream(javaFile, true)
|
|
1558
|
+
var actualEncoding: Any? = encoding
|
|
1559
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1560
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1561
|
+
}
|
|
1562
|
+
val writer: OutputStreamWriter =
|
|
1563
|
+
jsCastCarried(
|
|
1564
|
+
jsNew(OutputStreamWriter::class.java, stream, actualEncoding),
|
|
1565
|
+
OutputStreamWriter::class.java,
|
|
1566
|
+
)
|
|
1567
|
+
writer.write(content)
|
|
1568
|
+
writer.close()
|
|
1569
|
+
} catch (__e_1: Throwable) {
|
|
1570
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1571
|
+
if (jsTruthy(onError)) {
|
|
1572
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1573
|
+
}
|
|
1574
|
+
}
|
|
1575
|
+
}
|
|
1576
|
+
|
|
1577
|
+
open fun appendTextSync(
|
|
1578
|
+
path: String?,
|
|
1579
|
+
content: String?,
|
|
1580
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1581
|
+
encoding: Any? = null,
|
|
1582
|
+
) {
|
|
1583
|
+
try {
|
|
1584
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1585
|
+
val stream: FileOutputStream = FileOutputStream(javaFile, true)
|
|
1586
|
+
var actualEncoding: Any? = encoding
|
|
1587
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1588
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1589
|
+
}
|
|
1590
|
+
val writer: OutputStreamWriter =
|
|
1591
|
+
jsCastCarried(
|
|
1592
|
+
jsNew(OutputStreamWriter::class.java, stream, actualEncoding),
|
|
1593
|
+
OutputStreamWriter::class.java,
|
|
1594
|
+
)
|
|
1595
|
+
writer.write(content)
|
|
1596
|
+
writer.close()
|
|
1597
|
+
} catch (__e_1: Throwable) {
|
|
1598
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1599
|
+
if (jsTruthy(onError)) {
|
|
1600
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1601
|
+
}
|
|
1602
|
+
}
|
|
1603
|
+
}
|
|
1604
|
+
|
|
1605
|
+
fun writeTextAsync__FileSystemAccess(
|
|
1606
|
+
path: String?,
|
|
1607
|
+
content: String?,
|
|
1608
|
+
encoding: Any? = null,
|
|
1609
|
+
): JSPromise<Unit>? {
|
|
1610
|
+
var actualEncoding: Any? = encoding
|
|
1611
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1612
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1613
|
+
}
|
|
1614
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1615
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1616
|
+
try {
|
|
1617
|
+
Async.File.writeText(
|
|
1618
|
+
path,
|
|
1619
|
+
content,
|
|
1620
|
+
(actualEncoding as String?),
|
|
1621
|
+
object : Async.CompleteCallback {
|
|
1622
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1623
|
+
|
|
1624
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1625
|
+
jsElsewhere(__realm)?.let {
|
|
1626
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1627
|
+
}
|
|
1628
|
+
jsReport {
|
|
1629
|
+
__resolvers1.resolve(Unit)
|
|
1630
|
+
}
|
|
1631
|
+
}
|
|
1632
|
+
|
|
1633
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1634
|
+
jsElsewhere(__realm)?.let {
|
|
1635
|
+
return it.later { this.onError(err, __a1) }
|
|
1636
|
+
}
|
|
1637
|
+
jsReport {
|
|
1638
|
+
val err: Any? = err
|
|
1639
|
+
reject(err)
|
|
1640
|
+
}
|
|
1641
|
+
}
|
|
1642
|
+
},
|
|
1643
|
+
null,
|
|
1644
|
+
)
|
|
1645
|
+
} catch (__e_1: Throwable) {
|
|
1646
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1647
|
+
reject(ex)
|
|
1648
|
+
}
|
|
1649
|
+
}
|
|
1650
|
+
}
|
|
1651
|
+
|
|
1652
|
+
open fun writeTextAsync(
|
|
1653
|
+
path: String?,
|
|
1654
|
+
content: String?,
|
|
1655
|
+
encoding: Any? = null,
|
|
1656
|
+
): JSPromise<Unit>? {
|
|
1657
|
+
var actualEncoding: Any? = encoding
|
|
1658
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1659
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1660
|
+
}
|
|
1661
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
1662
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
1663
|
+
try {
|
|
1664
|
+
Async.File.writeText(
|
|
1665
|
+
path,
|
|
1666
|
+
content,
|
|
1667
|
+
(actualEncoding as String?),
|
|
1668
|
+
object : Async.CompleteCallback {
|
|
1669
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
1670
|
+
|
|
1671
|
+
override fun onComplete(__a0: Any?, __a1: Any?) {
|
|
1672
|
+
jsElsewhere(__realm)?.let {
|
|
1673
|
+
return it.later { this.onComplete(__a0, __a1) }
|
|
1674
|
+
}
|
|
1675
|
+
jsReport {
|
|
1676
|
+
__resolvers1.resolve(Unit)
|
|
1677
|
+
}
|
|
1678
|
+
}
|
|
1679
|
+
|
|
1680
|
+
override fun onError(err: String?, __a1: Any?) {
|
|
1681
|
+
jsElsewhere(__realm)?.let {
|
|
1682
|
+
return it.later { this.onError(err, __a1) }
|
|
1683
|
+
}
|
|
1684
|
+
jsReport {
|
|
1685
|
+
val err: Any? = err
|
|
1686
|
+
reject(err)
|
|
1687
|
+
}
|
|
1688
|
+
}
|
|
1689
|
+
},
|
|
1690
|
+
null,
|
|
1691
|
+
)
|
|
1692
|
+
} catch (__e_1: Throwable) {
|
|
1693
|
+
val ex: Any? = jsCaught(__e_1)
|
|
1694
|
+
reject(ex)
|
|
1695
|
+
}
|
|
1696
|
+
}
|
|
1697
|
+
}
|
|
1698
|
+
|
|
1699
|
+
fun writeTextSync__FileSystemAccess(
|
|
1700
|
+
path: String?,
|
|
1701
|
+
content: String?,
|
|
1702
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1703
|
+
encoding: Any? = null,
|
|
1704
|
+
) {
|
|
1705
|
+
try {
|
|
1706
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1707
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
1708
|
+
var actualEncoding: Any? = encoding
|
|
1709
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1710
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1711
|
+
}
|
|
1712
|
+
val writer: OutputStreamWriter =
|
|
1713
|
+
jsCastCarried(
|
|
1714
|
+
jsNew(OutputStreamWriter::class.java, stream, actualEncoding),
|
|
1715
|
+
OutputStreamWriter::class.java,
|
|
1716
|
+
)
|
|
1717
|
+
writer.write(content)
|
|
1718
|
+
writer.close()
|
|
1719
|
+
} catch (__e_1: Throwable) {
|
|
1720
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1721
|
+
if (jsTruthy(onError)) {
|
|
1722
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1723
|
+
}
|
|
1724
|
+
}
|
|
1725
|
+
}
|
|
1726
|
+
|
|
1727
|
+
open fun writeTextSync(
|
|
1728
|
+
path: String?,
|
|
1729
|
+
content: String?,
|
|
1730
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1731
|
+
encoding: Any? = null,
|
|
1732
|
+
) {
|
|
1733
|
+
try {
|
|
1734
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
1735
|
+
val stream: FileOutputStream = FileOutputStream(javaFile)
|
|
1736
|
+
var actualEncoding: Any? = encoding
|
|
1737
|
+
if (!jsTruthy(actualEncoding)) {
|
|
1738
|
+
actualEncoding = org.nativescript.kit.encoding.UTF_8
|
|
1739
|
+
}
|
|
1740
|
+
val writer: OutputStreamWriter =
|
|
1741
|
+
jsCastCarried(
|
|
1742
|
+
jsNew(OutputStreamWriter::class.java, stream, actualEncoding),
|
|
1743
|
+
OutputStreamWriter::class.java,
|
|
1744
|
+
)
|
|
1745
|
+
writer.write(content)
|
|
1746
|
+
writer.close()
|
|
1747
|
+
} catch (__e_1: Throwable) {
|
|
1748
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1749
|
+
if (jsTruthy(onError)) {
|
|
1750
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1751
|
+
}
|
|
1752
|
+
}
|
|
1753
|
+
}
|
|
1754
|
+
|
|
1755
|
+
open fun deleteFolderContent(file: java_io_File?): Boolean {
|
|
1756
|
+
val filesList: JSArray<java_io_File>? =
|
|
1757
|
+
JSArray(
|
|
1758
|
+
((file ?: jsCannotRead("listFiles")).listFiles() ?: jsObjectRequired()).toList()
|
|
1759
|
+
)
|
|
1760
|
+
if ((filesList ?: jsCannotRead("length")).length == 0.0) {
|
|
1761
|
+
return true
|
|
1762
|
+
}
|
|
1763
|
+
var childFile: java_io_File?
|
|
1764
|
+
var success: Boolean = false
|
|
1765
|
+
var i: Double = 0.0
|
|
1766
|
+
while (i < (filesList ?: jsCannotRead("length")).length) {
|
|
1767
|
+
childFile = (filesList ?: jsCannotRead(js(i))).element(i)
|
|
1768
|
+
if (
|
|
1769
|
+
(childFile ?: jsCannotRead("getCanonicalFile")).getCanonicalFile().isDirectory()
|
|
1770
|
+
) {
|
|
1771
|
+
success = this.deleteFolderContent(childFile)
|
|
1772
|
+
if (!success) {
|
|
1773
|
+
break
|
|
1774
|
+
}
|
|
1775
|
+
}
|
|
1776
|
+
success = (childFile ?: jsCannotRead("delete")).delete()
|
|
1777
|
+
i += 1.0
|
|
1778
|
+
}
|
|
1779
|
+
return success
|
|
1780
|
+
}
|
|
1781
|
+
|
|
1782
|
+
open fun ensureFile(
|
|
1783
|
+
javaFile: java_io_File?,
|
|
1784
|
+
isFolder: Boolean,
|
|
1785
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1786
|
+
): Any? {
|
|
1787
|
+
try {
|
|
1788
|
+
if (!((javaFile ?: jsCannotRead("exists")).exists())) {
|
|
1789
|
+
val created: Any?
|
|
1790
|
+
if (isFolder) {
|
|
1791
|
+
created = (javaFile ?: jsCannotRead("mkdirs")).mkdirs()
|
|
1792
|
+
} else {
|
|
1793
|
+
((javaFile ?: jsCannotRead("getParentFile")).getParentFile()
|
|
1794
|
+
?: jsCannotRead("mkdirs"))
|
|
1795
|
+
.mkdirs()
|
|
1796
|
+
created =
|
|
1797
|
+
(javaFile ?: jsCannotRead("createNewFile")).createNewFile()
|
|
1798
|
+
}
|
|
1799
|
+
if (!jsTruthy(created)) {
|
|
1800
|
+
if (jsTruthy(onError)) {
|
|
1801
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
1802
|
+
"Failed to create new java File for path " +
|
|
1803
|
+
(javaFile ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
1804
|
+
)
|
|
1805
|
+
}
|
|
1806
|
+
return null
|
|
1807
|
+
} else {
|
|
1808
|
+
(javaFile ?: jsCannotRead("setReadable")).setReadable(true)
|
|
1809
|
+
(javaFile ?: jsCannotRead("setWritable")).setWritable(true)
|
|
1810
|
+
}
|
|
1811
|
+
}
|
|
1812
|
+
val path: String =
|
|
1813
|
+
(javaFile ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
1814
|
+
return jsObjectOf(
|
|
1815
|
+
"path" to path,
|
|
1816
|
+
"name" to ((javaFile ?: jsCannotRead("getName")).getName() ?: JSNull),
|
|
1817
|
+
"extension" to this.getFileExtension(path),
|
|
1818
|
+
)
|
|
1819
|
+
} catch (__e_1: Throwable) {
|
|
1820
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1821
|
+
if (jsTruthy(onError)) {
|
|
1822
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1823
|
+
}
|
|
1824
|
+
return null
|
|
1825
|
+
}
|
|
1826
|
+
}
|
|
1827
|
+
|
|
1828
|
+
fun getFileExtension__FileSystemAccess(path: String?): String {
|
|
1829
|
+
return Core_utils_utils_shared.getFileExtension(path)
|
|
1830
|
+
}
|
|
1831
|
+
|
|
1832
|
+
open fun getFileExtension(path: String?): String {
|
|
1833
|
+
return Core_utils_utils_shared.getFileExtension(path)
|
|
1834
|
+
}
|
|
1835
|
+
|
|
1836
|
+
open fun enumEntities(
|
|
1837
|
+
path: String?,
|
|
1838
|
+
callback: (Any?) -> Boolean,
|
|
1839
|
+
onError: ((Any?) -> Any?)? = null,
|
|
1840
|
+
) {
|
|
1841
|
+
try {
|
|
1842
|
+
var javaFile: java_io_File? = java_io_File((path ?: "undefined"))
|
|
1843
|
+
if (
|
|
1844
|
+
!((javaFile ?: jsCannotRead("getCanonicalFile")).getCanonicalFile().isDirectory())
|
|
1845
|
+
) {
|
|
1846
|
+
if (jsTruthy(onError)) {
|
|
1847
|
+
(onError ?: jsNotAFunction("onError"))(
|
|
1848
|
+
"There is no folder existing at path " + jsToString((path ?: "undefined"))
|
|
1849
|
+
)
|
|
1850
|
+
}
|
|
1851
|
+
return
|
|
1852
|
+
}
|
|
1853
|
+
val filesList: JSArray<java_io_File>? =
|
|
1854
|
+
JSArray(
|
|
1855
|
+
((javaFile ?: jsCannotRead("listFiles")).listFiles() ?: jsObjectRequired())
|
|
1856
|
+
.toList()
|
|
1857
|
+
)
|
|
1858
|
+
val length: Double = (filesList ?: jsCannotRead("length")).length
|
|
1859
|
+
var info: Any?
|
|
1860
|
+
var retVal: Any?
|
|
1861
|
+
var i: Double = 0.0
|
|
1862
|
+
while (i < length) {
|
|
1863
|
+
javaFile = (filesList ?: jsCannotRead(js(i))).element(i)
|
|
1864
|
+
info =
|
|
1865
|
+
jsObjectOf(
|
|
1866
|
+
"path" to
|
|
1867
|
+
((javaFile ?: jsCannotRead("getAbsolutePath")).getAbsolutePath()
|
|
1868
|
+
?: JSNull),
|
|
1869
|
+
"name" to ((javaFile ?: jsCannotRead("getName")).getName() ?: JSNull),
|
|
1870
|
+
)
|
|
1871
|
+
if ((javaFile ?: jsCannotRead("isFile")).isFile()) {
|
|
1872
|
+
jsSet(
|
|
1873
|
+
info,
|
|
1874
|
+
"extension",
|
|
1875
|
+
this.getFileExtension(jsConvertedStringOrNull(jsGet(info, "path"))),
|
|
1876
|
+
)
|
|
1877
|
+
}
|
|
1878
|
+
retVal = callback(info)
|
|
1879
|
+
if (jsStrictEquals(retVal, false)) {
|
|
1880
|
+
break
|
|
1881
|
+
}
|
|
1882
|
+
i += 1.0
|
|
1883
|
+
}
|
|
1884
|
+
} catch (__e_1: Throwable) {
|
|
1885
|
+
val exception: Any? = jsCaught(__e_1)
|
|
1886
|
+
if (jsTruthy(onError)) {
|
|
1887
|
+
(onError ?: jsNotAFunction("onError"))(exception)
|
|
1888
|
+
}
|
|
1889
|
+
}
|
|
1890
|
+
}
|
|
1891
|
+
|
|
1892
|
+
fun getPathSeparator__FileSystemAccess(): String {
|
|
1893
|
+
return this._pathSeparator
|
|
1894
|
+
}
|
|
1895
|
+
|
|
1896
|
+
open fun getPathSeparator(): String {
|
|
1897
|
+
return this._pathSeparator
|
|
1898
|
+
}
|
|
1899
|
+
|
|
1900
|
+
fun normalizePath__FileSystemAccess(path: String?): String {
|
|
1901
|
+
if (Core_utils_constants.SDK_VERSION >= 26.0) {
|
|
1902
|
+
return Paths.get(path, *(arrayOf<String>(""))).normalize().toString()
|
|
1903
|
+
} else {
|
|
1904
|
+
val file: java_io_File = java_io_File((path ?: "undefined"))
|
|
1905
|
+
return file.getAbsolutePath()
|
|
1906
|
+
}
|
|
1907
|
+
}
|
|
1908
|
+
|
|
1909
|
+
open fun normalizePath(path: String?): String {
|
|
1910
|
+
if (Core_utils_constants.SDK_VERSION >= 26.0) {
|
|
1911
|
+
return Paths.get(path, *(arrayOf<String>(""))).normalize().toString()
|
|
1912
|
+
} else {
|
|
1913
|
+
val file: java_io_File = java_io_File((path ?: "undefined"))
|
|
1914
|
+
return file.getAbsolutePath()
|
|
1915
|
+
}
|
|
1916
|
+
}
|
|
1917
|
+
|
|
1918
|
+
fun joinPath__FileSystemAccess(left: String?, right: String?): String {
|
|
1919
|
+
val file1: java_io_File = java_io_File((left ?: "undefined"))
|
|
1920
|
+
val file2: java_io_File = java_io_File(file1, (right ?: "undefined"))
|
|
1921
|
+
return file2.getPath()
|
|
1922
|
+
}
|
|
1923
|
+
|
|
1924
|
+
open fun joinPath(left: String?, right: String?): String {
|
|
1925
|
+
val file1: java_io_File = java_io_File((left ?: "undefined"))
|
|
1926
|
+
val file2: java_io_File = java_io_File(file1, (right ?: "undefined"))
|
|
1927
|
+
return file2.getPath()
|
|
1928
|
+
}
|
|
1929
|
+
|
|
1930
|
+
fun joinPaths__FileSystemAccess(paths: JSArray<String>?): String {
|
|
1931
|
+
if (!jsTruthy(paths) || (paths ?: jsCannotRead("length")).length == 0.0) {
|
|
1932
|
+
return ""
|
|
1933
|
+
}
|
|
1934
|
+
if ((paths ?: jsCannotRead("length")).length == 1.0) {
|
|
1935
|
+
return ((paths ?: jsCannotRead("0")).element(0.0) ?: "undefined")
|
|
1936
|
+
}
|
|
1937
|
+
var result: String? = (paths ?: jsCannotRead("0")).element(0.0)
|
|
1938
|
+
var i: Double = 1.0
|
|
1939
|
+
while (i < (paths ?: jsCannotRead("length")).length) {
|
|
1940
|
+
result = this.joinPath(result, (paths ?: jsCannotRead(js(i))).element(i))
|
|
1941
|
+
i += 1.0
|
|
1942
|
+
}
|
|
1943
|
+
return (result ?: "undefined")
|
|
1944
|
+
}
|
|
1945
|
+
|
|
1946
|
+
open fun joinPaths(paths: JSArray<String>?): String {
|
|
1947
|
+
if (!jsTruthy(paths) || (paths ?: jsCannotRead("length")).length == 0.0) {
|
|
1948
|
+
return ""
|
|
1949
|
+
}
|
|
1950
|
+
if ((paths ?: jsCannotRead("length")).length == 1.0) {
|
|
1951
|
+
return ((paths ?: jsCannotRead("0")).element(0.0) ?: "undefined")
|
|
1952
|
+
}
|
|
1953
|
+
var result: String? = (paths ?: jsCannotRead("0")).element(0.0)
|
|
1954
|
+
var i: Double = 1.0
|
|
1955
|
+
while (i < (paths ?: jsCannotRead("length")).length) {
|
|
1956
|
+
result = this.joinPath(result, (paths ?: jsCannotRead(js(i))).element(i))
|
|
1957
|
+
i += 1.0
|
|
1958
|
+
}
|
|
1959
|
+
return (result ?: "undefined")
|
|
1960
|
+
}
|
|
1961
|
+
|
|
1962
|
+
override var jsExpando: JSObject? = null
|
|
1963
|
+
override val jsKeys: List<String>
|
|
1964
|
+
get() =
|
|
1965
|
+
listOf("_pathSeparator") +
|
|
1966
|
+
(if (copy == null) listOf() else listOf("copy")) +
|
|
1967
|
+
(if (readBuffer == null) listOf() else listOf("readBuffer")) +
|
|
1968
|
+
(if (read == null) listOf() else listOf("read")) +
|
|
1969
|
+
(if (appendBuffer == null) listOf() else listOf("appendBuffer")) +
|
|
1970
|
+
(if (append == null) listOf() else listOf("append")) +
|
|
1971
|
+
(if (writeBuffer == null) listOf() else listOf("writeBuffer")) +
|
|
1972
|
+
(if (write == null) listOf() else listOf("write")) +
|
|
1973
|
+
(if (readText == null) listOf() else listOf("readText")) +
|
|
1974
|
+
(if (appendText == null) listOf() else listOf("appendText")) +
|
|
1975
|
+
(if (writeText == null) listOf() else listOf("writeText")) +
|
|
1976
|
+
(jsExpando?.jsKeys ?: listOf())
|
|
1977
|
+
|
|
1978
|
+
override val jsClassName: String?
|
|
1979
|
+
get() = "FileSystemAccess"
|
|
1980
|
+
|
|
1981
|
+
override fun jsGet(key: String): Any? =
|
|
1982
|
+
when (key) {
|
|
1983
|
+
"_pathSeparator" -> this._pathSeparator
|
|
1984
|
+
"copy" -> this.copy
|
|
1985
|
+
"readBuffer" -> this.readBuffer
|
|
1986
|
+
"read" -> this.read
|
|
1987
|
+
"appendBuffer" -> this.appendBuffer
|
|
1988
|
+
"append" -> this.append
|
|
1989
|
+
"writeBuffer" -> this.writeBuffer
|
|
1990
|
+
"write" -> this.write
|
|
1991
|
+
"readText" -> this.readText
|
|
1992
|
+
"appendText" -> this.appendText
|
|
1993
|
+
"writeText" -> this.writeText
|
|
1994
|
+
"getLastModified" ->
|
|
1995
|
+
jsFunction { __a ->
|
|
1996
|
+
this.getLastModified_(jsConvertedStringOrNull(__a.getOrNull(0)))
|
|
1997
|
+
}
|
|
1998
|
+
"getFileSize" ->
|
|
1999
|
+
jsFunction { __a -> this.getFileSize(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
2000
|
+
"getParent" ->
|
|
2001
|
+
jsFunction { __a ->
|
|
2002
|
+
this.getParent_(
|
|
2003
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2004
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2005
|
+
)
|
|
2006
|
+
}
|
|
2007
|
+
"getFile" ->
|
|
2008
|
+
jsFunction { __a ->
|
|
2009
|
+
this.getFile(
|
|
2010
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2011
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2012
|
+
)
|
|
2013
|
+
}
|
|
2014
|
+
"getFolder" ->
|
|
2015
|
+
jsFunction { __a ->
|
|
2016
|
+
this.getFolder(
|
|
2017
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2018
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2019
|
+
)
|
|
2020
|
+
}
|
|
2021
|
+
"eachEntity" ->
|
|
2022
|
+
jsFunction { __a ->
|
|
2023
|
+
this.eachEntity(
|
|
2024
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2025
|
+
jsFunction1<Any?, Boolean>(__a.getOrNull(1)),
|
|
2026
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2027
|
+
)
|
|
2028
|
+
null
|
|
2029
|
+
}
|
|
2030
|
+
"getEntities" ->
|
|
2031
|
+
jsFunction { __a ->
|
|
2032
|
+
this.getEntities(
|
|
2033
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2034
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2035
|
+
)
|
|
2036
|
+
}
|
|
2037
|
+
"fileExists" ->
|
|
2038
|
+
jsFunction { __a -> this.fileExists(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
2039
|
+
"folderExists" ->
|
|
2040
|
+
jsFunction { __a -> this.folderExists(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
2041
|
+
"deleteFile" ->
|
|
2042
|
+
jsFunction { __a ->
|
|
2043
|
+
this.deleteFile(
|
|
2044
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2045
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2046
|
+
)
|
|
2047
|
+
null
|
|
2048
|
+
}
|
|
2049
|
+
"deleteFolder" ->
|
|
2050
|
+
jsFunction { __a ->
|
|
2051
|
+
this.deleteFolder(
|
|
2052
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2053
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2054
|
+
)
|
|
2055
|
+
null
|
|
2056
|
+
}
|
|
2057
|
+
"emptyFolder" ->
|
|
2058
|
+
jsFunction { __a ->
|
|
2059
|
+
this.emptyFolder(
|
|
2060
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2061
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2062
|
+
)
|
|
2063
|
+
null
|
|
2064
|
+
}
|
|
2065
|
+
"rename" ->
|
|
2066
|
+
jsFunction { __a ->
|
|
2067
|
+
this.rename(
|
|
2068
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2069
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2070
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2071
|
+
)
|
|
2072
|
+
null
|
|
2073
|
+
}
|
|
2074
|
+
"getDocumentsFolderPath" -> jsFunction { this.getDocumentsFolderPath() }
|
|
2075
|
+
"getExternalDocumentsFolderPath" -> jsFunction { this.getExternalDocumentsFolderPath() }
|
|
2076
|
+
"getLogicalRootPath" -> jsFunction { this.getLogicalRootPath() }
|
|
2077
|
+
"getTempFolderPath" -> jsFunction { this.getTempFolderPath() }
|
|
2078
|
+
"getCurrentAppPath" -> jsFunction { this.getCurrentAppPath() }
|
|
2079
|
+
"copySync" ->
|
|
2080
|
+
jsFunction { __a ->
|
|
2081
|
+
this.copySync(
|
|
2082
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2083
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2084
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2085
|
+
)
|
|
2086
|
+
}
|
|
2087
|
+
"copyAsync" ->
|
|
2088
|
+
jsFunction { __a ->
|
|
2089
|
+
this.copyAsync(
|
|
2090
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2091
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2092
|
+
)
|
|
2093
|
+
}
|
|
2094
|
+
"readBufferAsync" ->
|
|
2095
|
+
jsFunction { __a ->
|
|
2096
|
+
this.readBufferAsync(jsConvertedStringOrNull(__a.getOrNull(0)))
|
|
2097
|
+
}
|
|
2098
|
+
"readBufferSync" ->
|
|
2099
|
+
jsFunction { __a ->
|
|
2100
|
+
this.readBufferSync(
|
|
2101
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2102
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2103
|
+
)
|
|
2104
|
+
}
|
|
2105
|
+
"readAsync" ->
|
|
2106
|
+
jsFunction { __a -> this.readAsync(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
2107
|
+
"readSync" ->
|
|
2108
|
+
jsFunction { __a ->
|
|
2109
|
+
this.readSync(
|
|
2110
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2111
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2112
|
+
)
|
|
2113
|
+
}
|
|
2114
|
+
"appendBufferAsync" ->
|
|
2115
|
+
jsFunction { __a ->
|
|
2116
|
+
this.appendBufferAsync(
|
|
2117
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2118
|
+
__a.getOrNull(1),
|
|
2119
|
+
)
|
|
2120
|
+
}
|
|
2121
|
+
"appendBufferSync" ->
|
|
2122
|
+
jsFunction { __a ->
|
|
2123
|
+
this.appendBufferSync(
|
|
2124
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2125
|
+
__a.getOrNull(1),
|
|
2126
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2127
|
+
)
|
|
2128
|
+
null
|
|
2129
|
+
}
|
|
2130
|
+
"appendAsync" ->
|
|
2131
|
+
jsFunction { __a ->
|
|
2132
|
+
this.appendAsync(
|
|
2133
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2134
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
2135
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
2136
|
+
)
|
|
2137
|
+
}
|
|
2138
|
+
"appendSync" ->
|
|
2139
|
+
jsFunction { __a ->
|
|
2140
|
+
this.appendSync(
|
|
2141
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2142
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
2143
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
2144
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2145
|
+
)
|
|
2146
|
+
null
|
|
2147
|
+
}
|
|
2148
|
+
"writeBufferAsync" ->
|
|
2149
|
+
jsFunction { __a ->
|
|
2150
|
+
this.writeBufferAsync(
|
|
2151
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2152
|
+
__a.getOrNull(1),
|
|
2153
|
+
)
|
|
2154
|
+
}
|
|
2155
|
+
"writeBufferSync" ->
|
|
2156
|
+
jsFunction { __a ->
|
|
2157
|
+
this.writeBufferSync(
|
|
2158
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2159
|
+
__a.getOrNull(1),
|
|
2160
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2161
|
+
)
|
|
2162
|
+
null
|
|
2163
|
+
}
|
|
2164
|
+
"writeAsync" ->
|
|
2165
|
+
jsFunction { __a ->
|
|
2166
|
+
this.writeAsync(
|
|
2167
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2168
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
2169
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
2170
|
+
)
|
|
2171
|
+
}
|
|
2172
|
+
"writeSync" ->
|
|
2173
|
+
jsFunction { __a ->
|
|
2174
|
+
this.writeSync(
|
|
2175
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2176
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
2177
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
2178
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2179
|
+
)
|
|
2180
|
+
null
|
|
2181
|
+
}
|
|
2182
|
+
"readTextAsync" ->
|
|
2183
|
+
jsFunction { __a ->
|
|
2184
|
+
this.readTextAsync(jsConvertedStringOrNull(__a.getOrNull(0)), __a.getOrNull(1))
|
|
2185
|
+
}
|
|
2186
|
+
"readTextSync" ->
|
|
2187
|
+
jsFunction { __a ->
|
|
2188
|
+
this.readTextSync(
|
|
2189
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2190
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
2191
|
+
__a.getOrNull(2),
|
|
2192
|
+
)
|
|
2193
|
+
}
|
|
2194
|
+
"appendTextAsync" ->
|
|
2195
|
+
jsFunction { __a ->
|
|
2196
|
+
this.appendTextAsync(
|
|
2197
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2198
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2199
|
+
__a.getOrNull(2),
|
|
2200
|
+
)
|
|
2201
|
+
}
|
|
2202
|
+
"appendTextSync" ->
|
|
2203
|
+
jsFunction { __a ->
|
|
2204
|
+
this.appendTextSync(
|
|
2205
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2206
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2207
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2208
|
+
__a.getOrNull(3),
|
|
2209
|
+
)
|
|
2210
|
+
null
|
|
2211
|
+
}
|
|
2212
|
+
"writeTextAsync" ->
|
|
2213
|
+
jsFunction { __a ->
|
|
2214
|
+
this.writeTextAsync(
|
|
2215
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2216
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2217
|
+
__a.getOrNull(2),
|
|
2218
|
+
)
|
|
2219
|
+
}
|
|
2220
|
+
"writeTextSync" ->
|
|
2221
|
+
jsFunction { __a ->
|
|
2222
|
+
this.writeTextSync(
|
|
2223
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2224
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2225
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2226
|
+
__a.getOrNull(3),
|
|
2227
|
+
)
|
|
2228
|
+
null
|
|
2229
|
+
}
|
|
2230
|
+
"deleteFolderContent" ->
|
|
2231
|
+
jsFunction { __a ->
|
|
2232
|
+
this.deleteFolderContent(jsCast(__a.getOrNull(0), java_io_File::class.java))
|
|
2233
|
+
}
|
|
2234
|
+
"ensureFile" ->
|
|
2235
|
+
jsFunction { __a ->
|
|
2236
|
+
this.ensureFile(
|
|
2237
|
+
jsCast(__a.getOrNull(0), java_io_File::class.java),
|
|
2238
|
+
jsConvertedBooleanOrFalse(__a.getOrNull(1)),
|
|
2239
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2240
|
+
)
|
|
2241
|
+
}
|
|
2242
|
+
"getFileExtension" ->
|
|
2243
|
+
jsFunction { __a ->
|
|
2244
|
+
this.getFileExtension(jsConvertedStringOrNull(__a.getOrNull(0)))
|
|
2245
|
+
}
|
|
2246
|
+
"enumEntities" ->
|
|
2247
|
+
jsFunction { __a ->
|
|
2248
|
+
this.enumEntities(
|
|
2249
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2250
|
+
jsFunction1<Any?, Boolean>(__a.getOrNull(1)),
|
|
2251
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
2252
|
+
)
|
|
2253
|
+
null
|
|
2254
|
+
}
|
|
2255
|
+
"getPathSeparator" -> jsFunction { this.getPathSeparator() }
|
|
2256
|
+
"normalizePath" ->
|
|
2257
|
+
jsFunction { __a -> this.normalizePath(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
2258
|
+
"joinPath" ->
|
|
2259
|
+
jsFunction { __a ->
|
|
2260
|
+
this.joinPath(
|
|
2261
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
2262
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
2263
|
+
)
|
|
2264
|
+
}
|
|
2265
|
+
"joinPaths" ->
|
|
2266
|
+
jsFunction { __a ->
|
|
2267
|
+
this.joinPaths(
|
|
2268
|
+
(if (jsIsNullish(__a.getOrNull(0))) null
|
|
2269
|
+
else jsArrayFrom(__a.getOrNull(0)) { jsConvertedString(it) })
|
|
2270
|
+
)
|
|
2271
|
+
}
|
|
2272
|
+
else -> jsExpandoGet(this, key)
|
|
2273
|
+
}
|
|
2274
|
+
|
|
2275
|
+
override fun jsSet(key: String, value: Any?) {
|
|
2276
|
+
when (key) {
|
|
2277
|
+
"_pathSeparator" -> this._pathSeparator = jsConvertedString(value, "_pathSeparator")
|
|
2278
|
+
"copy" -> this.copy = value
|
|
2279
|
+
"readBuffer" -> this.readBuffer = value
|
|
2280
|
+
"read" -> this.read = value
|
|
2281
|
+
"appendBuffer" -> this.appendBuffer = value
|
|
2282
|
+
"append" -> this.append = value
|
|
2283
|
+
"writeBuffer" -> this.writeBuffer = value
|
|
2284
|
+
"write" -> this.write = value
|
|
2285
|
+
"readText" -> this.readText = value
|
|
2286
|
+
"appendText" -> this.appendText = value
|
|
2287
|
+
"writeText" -> this.writeText = value
|
|
2288
|
+
else -> jsExpandoSet(this, key, value)
|
|
2289
|
+
}
|
|
2290
|
+
}
|
|
2291
|
+
|
|
2292
|
+
override fun jsHasMember(key: String): Boolean =
|
|
2293
|
+
when (key) {
|
|
2294
|
+
"getLastModified",
|
|
2295
|
+
"getFileSize",
|
|
2296
|
+
"getParent",
|
|
2297
|
+
"getFile",
|
|
2298
|
+
"getFolder",
|
|
2299
|
+
"eachEntity",
|
|
2300
|
+
"getEntities",
|
|
2301
|
+
"fileExists",
|
|
2302
|
+
"folderExists",
|
|
2303
|
+
"deleteFile",
|
|
2304
|
+
"deleteFolder",
|
|
2305
|
+
"emptyFolder",
|
|
2306
|
+
"rename",
|
|
2307
|
+
"getDocumentsFolderPath",
|
|
2308
|
+
"getExternalDocumentsFolderPath",
|
|
2309
|
+
"getLogicalRootPath",
|
|
2310
|
+
"getTempFolderPath",
|
|
2311
|
+
"getCurrentAppPath",
|
|
2312
|
+
"copySync",
|
|
2313
|
+
"copyAsync",
|
|
2314
|
+
"readBufferAsync",
|
|
2315
|
+
"readBufferSync",
|
|
2316
|
+
"readAsync",
|
|
2317
|
+
"readSync",
|
|
2318
|
+
"appendBufferAsync",
|
|
2319
|
+
"appendBufferSync",
|
|
2320
|
+
"appendAsync",
|
|
2321
|
+
"appendSync",
|
|
2322
|
+
"writeBufferAsync",
|
|
2323
|
+
"writeBufferSync",
|
|
2324
|
+
"writeAsync",
|
|
2325
|
+
"writeSync",
|
|
2326
|
+
"readTextAsync",
|
|
2327
|
+
"readTextSync",
|
|
2328
|
+
"appendTextAsync",
|
|
2329
|
+
"appendTextSync",
|
|
2330
|
+
"writeTextAsync",
|
|
2331
|
+
"writeTextSync",
|
|
2332
|
+
"deleteFolderContent",
|
|
2333
|
+
"ensureFile",
|
|
2334
|
+
"getFileExtension",
|
|
2335
|
+
"enumEntities",
|
|
2336
|
+
"getPathSeparator",
|
|
2337
|
+
"normalizePath",
|
|
2338
|
+
"joinPath",
|
|
2339
|
+
"joinPaths" -> true
|
|
2340
|
+
else -> false
|
|
2341
|
+
}
|
|
2342
|
+
|
|
2343
|
+
companion object {
|
|
2344
|
+
fun getBuffer(buffer: Any?): Any? {
|
|
2345
|
+
if ((buffer is Any)) {
|
|
2346
|
+
return jsOr(
|
|
2347
|
+
jsGet((jsCastCarried(buffer, JSArrayBuffer::class.java)), "nativeObject")
|
|
2348
|
+
) {
|
|
2349
|
+
jsCastCarried(buffer, JSArrayBuffer::class.java)
|
|
2350
|
+
}
|
|
2351
|
+
} else {
|
|
2352
|
+
return jsOr(
|
|
2353
|
+
jsGetOptional((jsGetOptional(buffer, "buffer")), "nativeObject")
|
|
2354
|
+
) {
|
|
2355
|
+
buffer
|
|
2356
|
+
}
|
|
2357
|
+
}
|
|
2358
|
+
}
|
|
2359
|
+
|
|
2360
|
+
fun _readAllBytes(path: String?): ByteArrayOutputStream? {
|
|
2361
|
+
val javaFile: java_io_File = java_io_File((path ?: "undefined"))
|
|
2362
|
+
val stream: FileInputStream = FileInputStream(javaFile)
|
|
2363
|
+
try {
|
|
2364
|
+
val output: ByteArrayOutputStream =
|
|
2365
|
+
ByteArrayOutputStream(
|
|
2366
|
+
jsMathMax(javaFile.length().toDouble(), 32.0).toLong().toInt()
|
|
2367
|
+
)
|
|
2368
|
+
val chunk: Any? = jsArrayCreate("byte", 65536.0)
|
|
2369
|
+
var count: Double? = null
|
|
2370
|
+
while (
|
|
2371
|
+
(kotlin.run {
|
|
2372
|
+
val __assigned1: Double =
|
|
2373
|
+
stream
|
|
2374
|
+
.read((toJavaValue(chunk, ByteArray::class.java) as ByteArray?))
|
|
2375
|
+
.toDouble()
|
|
2376
|
+
count = __assigned1
|
|
2377
|
+
__assigned1
|
|
2378
|
+
}) != -1.0
|
|
2379
|
+
) {
|
|
2380
|
+
output.write(
|
|
2381
|
+
(toJavaValue(chunk, ByteArray::class.java) as ByteArray?),
|
|
2382
|
+
0,
|
|
2383
|
+
(count ?: Double.NaN).toLong().toInt(),
|
|
2384
|
+
)
|
|
2385
|
+
}
|
|
2386
|
+
return output
|
|
2387
|
+
} finally {
|
|
2388
|
+
stream.close()
|
|
2389
|
+
}
|
|
2390
|
+
}
|
|
2391
|
+
|
|
2392
|
+
fun _removeUtf8Bom(s: String?): String {
|
|
2393
|
+
var s = s
|
|
2394
|
+
if (jsCharCodeAt((s ?: jsCannotRead("charCodeAt")), 0.0) == 65279.0) {
|
|
2395
|
+
s = jsSlice((s ?: jsCannotRead("slice")), 1.0)
|
|
2396
|
+
}
|
|
2397
|
+
return (s ?: "undefined")
|
|
2398
|
+
}
|
|
2399
|
+
}
|
|
2400
|
+
}
|
|
2401
|
+
|
|
2402
|
+
@AnyThread
|
|
2403
|
+
open class FileSystemAccess29 : FileSystemAccess {
|
|
2404
|
+
@JvmField var __skip: Boolean = true
|
|
2405
|
+
|
|
2406
|
+
init {
|
|
2407
|
+
this.appendBuffer = this::appendBufferSync
|
|
2408
|
+
}
|
|
2409
|
+
|
|
2410
|
+
init {
|
|
2411
|
+
this.append = this::appendSync
|
|
2412
|
+
}
|
|
2413
|
+
|
|
2414
|
+
init {
|
|
2415
|
+
this.appendText = this::appendTextSync
|
|
2416
|
+
}
|
|
2417
|
+
|
|
2418
|
+
init {
|
|
2419
|
+
this.readText = this::readTextSync
|
|
2420
|
+
}
|
|
2421
|
+
|
|
2422
|
+
init {
|
|
2423
|
+
this.readBuffer = this::readBufferSync
|
|
2424
|
+
}
|
|
2425
|
+
|
|
2426
|
+
init {
|
|
2427
|
+
this.read = this::readSync
|
|
2428
|
+
}
|
|
2429
|
+
|
|
2430
|
+
init {
|
|
2431
|
+
this.writeText = this::writeTextSync
|
|
2432
|
+
}
|
|
2433
|
+
|
|
2434
|
+
init {
|
|
2435
|
+
this.writeBuffer = this::writeBufferSync
|
|
2436
|
+
}
|
|
2437
|
+
|
|
2438
|
+
init {
|
|
2439
|
+
this.write = this::writeSync
|
|
2440
|
+
}
|
|
2441
|
+
|
|
2442
|
+
constructor() : super()
|
|
2443
|
+
|
|
2444
|
+
override fun getLastModified_(path: String?): JSDate? {
|
|
2445
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2446
|
+
return JSDate(
|
|
2447
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2448
|
+
?: jsCannotRead("getLastModified"))
|
|
2449
|
+
.getLastModified()
|
|
2450
|
+
.toDouble() * 1000.0
|
|
2451
|
+
)
|
|
2452
|
+
}
|
|
2453
|
+
return super.getLastModified_(path)
|
|
2454
|
+
}
|
|
2455
|
+
|
|
2456
|
+
override fun getFileSize(path: String?): Double {
|
|
2457
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2458
|
+
return (Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2459
|
+
?: jsCannotRead("getSize"))
|
|
2460
|
+
.getSize()
|
|
2461
|
+
.toDouble()
|
|
2462
|
+
}
|
|
2463
|
+
return super.getFileSize(path)
|
|
2464
|
+
}
|
|
2465
|
+
|
|
2466
|
+
override fun getParent_(path: String?, onError: ((Any?) -> Any?)?): Any? {
|
|
2467
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2468
|
+
return jsNull
|
|
2469
|
+
}
|
|
2470
|
+
return super.getParent_(path, onError)
|
|
2471
|
+
}
|
|
2472
|
+
|
|
2473
|
+
override fun getFile(path: String?, onError: ((Any?) -> Any?)?): Any? {
|
|
2474
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2475
|
+
try {
|
|
2476
|
+
val file: FileHelper? =
|
|
2477
|
+
Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2478
|
+
return jsObjectOf(
|
|
2479
|
+
"path" to path,
|
|
2480
|
+
"name" to ((file ?: jsCannotRead("getName")).getName() ?: JSNull),
|
|
2481
|
+
"extension" to ((file ?: jsCannotRead("getExtension")).getExtension() ?: JSNull),
|
|
2482
|
+
)
|
|
2483
|
+
} catch (__e_1: Throwable) {
|
|
2484
|
+
val e: Any? = jsCaught(__e_1)
|
|
2485
|
+
if (jsTypeof(onError) == "function") {
|
|
2486
|
+
(onError ?: jsNotAFunction("onError"))(e)
|
|
2487
|
+
}
|
|
2488
|
+
return null
|
|
2489
|
+
}
|
|
2490
|
+
}
|
|
2491
|
+
return super.getFile(path, onError)
|
|
2492
|
+
}
|
|
2493
|
+
|
|
2494
|
+
override fun getFolder(path: String?, onError: ((Any?) -> Any?)?): Any? {
|
|
2495
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2496
|
+
return jsNull
|
|
2497
|
+
}
|
|
2498
|
+
return super.getFolder(path, onError)
|
|
2499
|
+
}
|
|
2500
|
+
|
|
2501
|
+
override fun getEntities(path: String?, onError: ((Any?) -> Any?)?): JSArray<Any?>? {
|
|
2502
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2503
|
+
return null
|
|
2504
|
+
}
|
|
2505
|
+
return super.getEntities(path, onError)
|
|
2506
|
+
}
|
|
2507
|
+
|
|
2508
|
+
override fun eachEntity(
|
|
2509
|
+
path: String?,
|
|
2510
|
+
onEntity: (Any?) -> Boolean,
|
|
2511
|
+
onError: ((Any?) -> Any?)?,
|
|
2512
|
+
) {
|
|
2513
|
+
(fun(): Any? {
|
|
2514
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2515
|
+
return jsNull
|
|
2516
|
+
}
|
|
2517
|
+
super.eachEntity(path, onEntity, null)
|
|
2518
|
+
return null
|
|
2519
|
+
})()
|
|
2520
|
+
}
|
|
2521
|
+
|
|
2522
|
+
override fun fileExists(path: String?): Boolean {
|
|
2523
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2524
|
+
return FileHelper.exists(
|
|
2525
|
+
jsCastCarried(
|
|
2526
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2527
|
+
android_app_Application::class.java,
|
|
2528
|
+
)
|
|
2529
|
+
.getApplicationContext(),
|
|
2530
|
+
path,
|
|
2531
|
+
)
|
|
2532
|
+
}
|
|
2533
|
+
return super.fileExists(path)
|
|
2534
|
+
}
|
|
2535
|
+
|
|
2536
|
+
override fun folderExists(path: String?): Boolean {
|
|
2537
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2538
|
+
return false
|
|
2539
|
+
}
|
|
2540
|
+
return super.folderExists(path)
|
|
2541
|
+
}
|
|
2542
|
+
|
|
2543
|
+
override fun deleteFile(path: String?, onError: ((Any?) -> Any?)?) {
|
|
2544
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2545
|
+
try {
|
|
2546
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2547
|
+
?: jsCannotRead("delete"))
|
|
2548
|
+
.delete(
|
|
2549
|
+
jsCastCarried(
|
|
2550
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2551
|
+
android_app_Application::class.java,
|
|
2552
|
+
)
|
|
2553
|
+
.getApplicationContext()
|
|
2554
|
+
)
|
|
2555
|
+
} catch (__e_1: Throwable) {
|
|
2556
|
+
val e: Any? = jsCaught(__e_1)
|
|
2557
|
+
onError?.invoke(e)
|
|
2558
|
+
}
|
|
2559
|
+
} else {
|
|
2560
|
+
super.deleteFile(path, onError)
|
|
2561
|
+
}
|
|
2562
|
+
}
|
|
2563
|
+
|
|
2564
|
+
override fun deleteFolder(path: String?, onError: ((Any?) -> Any?)?) {
|
|
2565
|
+
if (!Core_file_system_file_system_access.isContentUri(path)) {
|
|
2566
|
+
super.deleteFolder(path, onError)
|
|
2567
|
+
}
|
|
2568
|
+
}
|
|
2569
|
+
|
|
2570
|
+
override fun emptyFolder(path: String?, onError: ((Any?) -> Any?)?) {
|
|
2571
|
+
if (!Core_file_system_file_system_access.isContentUri(path)) {
|
|
2572
|
+
super.emptyFolder(path, onError)
|
|
2573
|
+
}
|
|
2574
|
+
}
|
|
2575
|
+
|
|
2576
|
+
override fun rename(path: String?, newPath: String?, onError: ((Any?) -> Any?)?) {
|
|
2577
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2578
|
+
var callback: Any? = jsNull
|
|
2579
|
+
if (jsTypeof(onError) == "function") {
|
|
2580
|
+
callback =
|
|
2581
|
+
object : FileHelper.Callback {
|
|
2582
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2583
|
+
|
|
2584
|
+
override fun onSuccess(result: Any?) {
|
|
2585
|
+
jsElsewhere(__realm)?.let {
|
|
2586
|
+
return it.later { this.onSuccess(result) }
|
|
2587
|
+
}
|
|
2588
|
+
}
|
|
2589
|
+
|
|
2590
|
+
override fun onError(error: Exception?) {
|
|
2591
|
+
jsElsewhere(__realm)?.let {
|
|
2592
|
+
return it.later { this.onError(error) }
|
|
2593
|
+
}
|
|
2594
|
+
jsReport {
|
|
2595
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
2596
|
+
}
|
|
2597
|
+
}
|
|
2598
|
+
}
|
|
2599
|
+
}
|
|
2600
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2601
|
+
?: jsCannotRead("renameSync"))
|
|
2602
|
+
.renameSync(
|
|
2603
|
+
jsCastCarried(
|
|
2604
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2605
|
+
android_app_Application::class.java,
|
|
2606
|
+
)
|
|
2607
|
+
.getApplicationContext(),
|
|
2608
|
+
newPath,
|
|
2609
|
+
(callback as FileHelper.Callback?),
|
|
2610
|
+
)
|
|
2611
|
+
} else {
|
|
2612
|
+
super.rename(path, newPath, onError)
|
|
2613
|
+
}
|
|
2614
|
+
}
|
|
2615
|
+
|
|
2616
|
+
open fun renameAsync(path: String?, newPath: String?): JSPromise<Any?>? {
|
|
2617
|
+
return jsAs<JSPromise<Any?>?>(
|
|
2618
|
+
JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
2619
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
2620
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2621
|
+
?: jsCannotRead("renameSync"))
|
|
2622
|
+
.renameSync(
|
|
2623
|
+
jsCastCarried(
|
|
2624
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2625
|
+
android_app_Application::class.java,
|
|
2626
|
+
)
|
|
2627
|
+
.getApplicationContext(),
|
|
2628
|
+
newPath,
|
|
2629
|
+
object : FileHelper.Callback {
|
|
2630
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2631
|
+
|
|
2632
|
+
override fun onSuccess(result: Any?) {
|
|
2633
|
+
jsElsewhere(__realm)?.let {
|
|
2634
|
+
return it.later { this.onSuccess(result) }
|
|
2635
|
+
}
|
|
2636
|
+
jsReport {
|
|
2637
|
+
__resolvers1.resolve(Unit)
|
|
2638
|
+
}
|
|
2639
|
+
}
|
|
2640
|
+
|
|
2641
|
+
override fun onError(error: Exception?) {
|
|
2642
|
+
jsElsewhere(__realm)?.let {
|
|
2643
|
+
return it.later { this.onError(error) }
|
|
2644
|
+
}
|
|
2645
|
+
jsReport {
|
|
2646
|
+
reject(error)
|
|
2647
|
+
}
|
|
2648
|
+
}
|
|
2649
|
+
},
|
|
2650
|
+
)
|
|
2651
|
+
}
|
|
2652
|
+
)
|
|
2653
|
+
}
|
|
2654
|
+
|
|
2655
|
+
override fun getDocumentsFolderPath(): String {
|
|
2656
|
+
return super.getDocumentsFolderPath()
|
|
2657
|
+
}
|
|
2658
|
+
|
|
2659
|
+
override fun getTempFolderPath(): String {
|
|
2660
|
+
return super.getTempFolderPath()
|
|
2661
|
+
}
|
|
2662
|
+
|
|
2663
|
+
override fun getLogicalRootPath(): String {
|
|
2664
|
+
return super.getLogicalRootPath()
|
|
2665
|
+
}
|
|
2666
|
+
|
|
2667
|
+
override fun getCurrentAppPath(): String {
|
|
2668
|
+
return super.getCurrentAppPath()
|
|
2669
|
+
}
|
|
2670
|
+
|
|
2671
|
+
override fun appendBufferAsync(path: String?, buffer: Any?): JSPromise<Unit>? {
|
|
2672
|
+
val content = buffer
|
|
2673
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2674
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
2675
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
2676
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2677
|
+
?: jsCannotRead("appendBuffer"))
|
|
2678
|
+
.appendBuffer(
|
|
2679
|
+
jsCastCarried(
|
|
2680
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2681
|
+
android_app_Application::class.java,
|
|
2682
|
+
)
|
|
2683
|
+
.getApplicationContext(),
|
|
2684
|
+
(FileSystemAccess.getBuffer(content) as ByteBuffer?),
|
|
2685
|
+
object : FileHelper.Callback {
|
|
2686
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2687
|
+
|
|
2688
|
+
override fun onSuccess(result: Any?) {
|
|
2689
|
+
jsElsewhere(__realm)?.let {
|
|
2690
|
+
return it.later { this.onSuccess(result) }
|
|
2691
|
+
}
|
|
2692
|
+
jsReport {
|
|
2693
|
+
__resolvers1.resolve(Unit)
|
|
2694
|
+
}
|
|
2695
|
+
}
|
|
2696
|
+
|
|
2697
|
+
override fun onError(error: Exception?) {
|
|
2698
|
+
jsElsewhere(__realm)?.let {
|
|
2699
|
+
return it.later { this.onError(error) }
|
|
2700
|
+
}
|
|
2701
|
+
jsReport {
|
|
2702
|
+
reject(error)
|
|
2703
|
+
}
|
|
2704
|
+
}
|
|
2705
|
+
},
|
|
2706
|
+
)
|
|
2707
|
+
}
|
|
2708
|
+
}
|
|
2709
|
+
return super.appendAsync(
|
|
2710
|
+
path,
|
|
2711
|
+
(if (jsIsNullish(content)) null else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
2712
|
+
)
|
|
2713
|
+
}
|
|
2714
|
+
|
|
2715
|
+
override fun appendBufferSync(path: String?, buffer: Any?, onError: ((Any?) -> Any?)?) {
|
|
2716
|
+
val content = buffer
|
|
2717
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2718
|
+
var callback: Any? = jsNull
|
|
2719
|
+
if (jsTypeof(onError) == "function") {
|
|
2720
|
+
callback =
|
|
2721
|
+
object : FileHelper.Callback {
|
|
2722
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2723
|
+
|
|
2724
|
+
override fun onSuccess(result: Any?) {
|
|
2725
|
+
jsElsewhere(__realm)?.let {
|
|
2726
|
+
return it.later { this.onSuccess(result) }
|
|
2727
|
+
}
|
|
2728
|
+
}
|
|
2729
|
+
|
|
2730
|
+
override fun onError(error: Exception?) {
|
|
2731
|
+
jsElsewhere(__realm)?.let {
|
|
2732
|
+
return it.later { this.onError(error) }
|
|
2733
|
+
}
|
|
2734
|
+
jsReport {
|
|
2735
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
2736
|
+
}
|
|
2737
|
+
}
|
|
2738
|
+
}
|
|
2739
|
+
}
|
|
2740
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2741
|
+
?: jsCannotRead("appendSync"))
|
|
2742
|
+
.appendSync(
|
|
2743
|
+
jsCastCarried(
|
|
2744
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2745
|
+
android_app_Application::class.java,
|
|
2746
|
+
)
|
|
2747
|
+
.getApplicationContext(),
|
|
2748
|
+
(toJavaValue(FileSystemAccess.getBuffer(content), ByteArray::class.java)
|
|
2749
|
+
as ByteArray?),
|
|
2750
|
+
(callback as FileHelper.Callback?),
|
|
2751
|
+
)
|
|
2752
|
+
} else {
|
|
2753
|
+
super.appendSync(
|
|
2754
|
+
path,
|
|
2755
|
+
(if (jsIsNullish(content)) null
|
|
2756
|
+
else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
2757
|
+
onError,
|
|
2758
|
+
)
|
|
2759
|
+
}
|
|
2760
|
+
}
|
|
2761
|
+
|
|
2762
|
+
override fun appendAsync(path: String?, bytes: JSArray<Double>?): JSPromise<Unit>? {
|
|
2763
|
+
val content: Any? = bytes
|
|
2764
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2765
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
2766
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
2767
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2768
|
+
?: jsCannotRead("append"))
|
|
2769
|
+
.append(
|
|
2770
|
+
jsCastCarried(
|
|
2771
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2772
|
+
android_app_Application::class.java,
|
|
2773
|
+
)
|
|
2774
|
+
.getApplicationContext(),
|
|
2775
|
+
(toJavaValue(content, ByteArray::class.java) as ByteArray?),
|
|
2776
|
+
object : FileHelper.Callback {
|
|
2777
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2778
|
+
|
|
2779
|
+
override fun onSuccess(result: Any?) {
|
|
2780
|
+
jsElsewhere(__realm)?.let {
|
|
2781
|
+
return it.later { this.onSuccess(result) }
|
|
2782
|
+
}
|
|
2783
|
+
jsReport {
|
|
2784
|
+
__resolvers1.resolve(Unit)
|
|
2785
|
+
}
|
|
2786
|
+
}
|
|
2787
|
+
|
|
2788
|
+
override fun onError(error: Exception?) {
|
|
2789
|
+
jsElsewhere(__realm)?.let {
|
|
2790
|
+
return it.later { this.onError(error) }
|
|
2791
|
+
}
|
|
2792
|
+
jsReport {
|
|
2793
|
+
reject(error)
|
|
2794
|
+
}
|
|
2795
|
+
}
|
|
2796
|
+
},
|
|
2797
|
+
)
|
|
2798
|
+
}
|
|
2799
|
+
}
|
|
2800
|
+
return super.appendAsync(
|
|
2801
|
+
path,
|
|
2802
|
+
(if (jsIsNullish(content)) null else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
2803
|
+
)
|
|
2804
|
+
}
|
|
2805
|
+
|
|
2806
|
+
override fun appendSync(path: String?, bytes: JSArray<Double>?, onError: ((Any?) -> Any?)?) {
|
|
2807
|
+
val content: Any? = bytes
|
|
2808
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2809
|
+
var callback: Any? = jsNull
|
|
2810
|
+
if (jsTypeof(onError) == "function") {
|
|
2811
|
+
callback =
|
|
2812
|
+
object : FileHelper.Callback {
|
|
2813
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2814
|
+
|
|
2815
|
+
override fun onSuccess(result: Any?) {
|
|
2816
|
+
jsElsewhere(__realm)?.let {
|
|
2817
|
+
return it.later { this.onSuccess(result) }
|
|
2818
|
+
}
|
|
2819
|
+
}
|
|
2820
|
+
|
|
2821
|
+
override fun onError(error: Exception?) {
|
|
2822
|
+
jsElsewhere(__realm)?.let {
|
|
2823
|
+
return it.later { this.onError(error) }
|
|
2824
|
+
}
|
|
2825
|
+
jsReport {
|
|
2826
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
2827
|
+
}
|
|
2828
|
+
}
|
|
2829
|
+
}
|
|
2830
|
+
}
|
|
2831
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2832
|
+
?: jsCannotRead("appendSync"))
|
|
2833
|
+
.appendSync(
|
|
2834
|
+
jsCastCarried(
|
|
2835
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2836
|
+
android_app_Application::class.java,
|
|
2837
|
+
)
|
|
2838
|
+
.getApplicationContext(),
|
|
2839
|
+
(toJavaValue(content, ByteArray::class.java) as ByteArray?),
|
|
2840
|
+
(callback as FileHelper.Callback?),
|
|
2841
|
+
)
|
|
2842
|
+
} else {
|
|
2843
|
+
super.appendSync(
|
|
2844
|
+
path,
|
|
2845
|
+
(if (jsIsNullish(content)) null
|
|
2846
|
+
else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
2847
|
+
onError,
|
|
2848
|
+
)
|
|
2849
|
+
}
|
|
2850
|
+
}
|
|
2851
|
+
|
|
2852
|
+
override fun appendTextAsync(
|
|
2853
|
+
path: String?,
|
|
2854
|
+
content: String?,
|
|
2855
|
+
encoding: Any?,
|
|
2856
|
+
): JSPromise<Unit>? {
|
|
2857
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2858
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
2859
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
2860
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2861
|
+
?: jsCannotRead("appendText"))
|
|
2862
|
+
.appendText(
|
|
2863
|
+
jsCastCarried(
|
|
2864
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2865
|
+
android_app_Application::class.java,
|
|
2866
|
+
)
|
|
2867
|
+
.getApplicationContext(),
|
|
2868
|
+
content,
|
|
2869
|
+
(jsNullishCoalesce(encoding) { jsNull } as String?),
|
|
2870
|
+
object : FileHelper.Callback {
|
|
2871
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2872
|
+
|
|
2873
|
+
override fun onSuccess(result: Any?) {
|
|
2874
|
+
jsElsewhere(__realm)?.let {
|
|
2875
|
+
return it.later { this.onSuccess(result) }
|
|
2876
|
+
}
|
|
2877
|
+
jsReport {
|
|
2878
|
+
__resolvers1.resolve(Unit)
|
|
2879
|
+
}
|
|
2880
|
+
}
|
|
2881
|
+
|
|
2882
|
+
override fun onError(error: Exception?) {
|
|
2883
|
+
jsElsewhere(__realm)?.let {
|
|
2884
|
+
return it.later { this.onError(error) }
|
|
2885
|
+
}
|
|
2886
|
+
jsReport {
|
|
2887
|
+
reject(error)
|
|
2888
|
+
}
|
|
2889
|
+
}
|
|
2890
|
+
},
|
|
2891
|
+
)
|
|
2892
|
+
}
|
|
2893
|
+
}
|
|
2894
|
+
return super.appendTextAsync(path, content, encoding)
|
|
2895
|
+
}
|
|
2896
|
+
|
|
2897
|
+
override fun appendTextSync(
|
|
2898
|
+
path: String?,
|
|
2899
|
+
content: String?,
|
|
2900
|
+
onError: ((Any?) -> Any?)?,
|
|
2901
|
+
encoding: Any?,
|
|
2902
|
+
) {
|
|
2903
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2904
|
+
var callback: Any? = jsNull
|
|
2905
|
+
if (jsTypeof(onError) == "function") {
|
|
2906
|
+
callback =
|
|
2907
|
+
object : FileHelper.Callback {
|
|
2908
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2909
|
+
|
|
2910
|
+
override fun onSuccess(result: Any?) {
|
|
2911
|
+
jsElsewhere(__realm)?.let {
|
|
2912
|
+
return it.later { this.onSuccess(result) }
|
|
2913
|
+
}
|
|
2914
|
+
}
|
|
2915
|
+
|
|
2916
|
+
override fun onError(error: Exception?) {
|
|
2917
|
+
jsElsewhere(__realm)?.let {
|
|
2918
|
+
return it.later { this.onError(error) }
|
|
2919
|
+
}
|
|
2920
|
+
jsReport {
|
|
2921
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
2922
|
+
}
|
|
2923
|
+
}
|
|
2924
|
+
}
|
|
2925
|
+
}
|
|
2926
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2927
|
+
?: jsCannotRead("appendTextSync"))
|
|
2928
|
+
.appendTextSync(
|
|
2929
|
+
jsCastCarried(
|
|
2930
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2931
|
+
android_app_Application::class.java,
|
|
2932
|
+
)
|
|
2933
|
+
.getApplicationContext(),
|
|
2934
|
+
content,
|
|
2935
|
+
(jsNullishCoalesce(encoding) { jsNull } as String?),
|
|
2936
|
+
(callback as FileHelper.Callback?),
|
|
2937
|
+
)
|
|
2938
|
+
} else {
|
|
2939
|
+
super.appendTextSync(path, content, onError, null)
|
|
2940
|
+
}
|
|
2941
|
+
}
|
|
2942
|
+
|
|
2943
|
+
override fun readTextAsync(path: String?, encoding: Any?): JSPromise<String>? {
|
|
2944
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2945
|
+
return JSPromise<String> { __resolvers1: JSResolvers<String> ->
|
|
2946
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
2947
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
2948
|
+
?: jsCannotRead("readText"))
|
|
2949
|
+
.readText(
|
|
2950
|
+
jsCastCarried(
|
|
2951
|
+
Core_application_helpers_common.getNativeApp(),
|
|
2952
|
+
android_app_Application::class.java,
|
|
2953
|
+
)
|
|
2954
|
+
.getApplicationContext(),
|
|
2955
|
+
(jsNullishCoalesce(encoding) { jsNull } as String?),
|
|
2956
|
+
object : FileHelper.Callback {
|
|
2957
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2958
|
+
|
|
2959
|
+
override fun onSuccess(result: Any?) {
|
|
2960
|
+
jsElsewhere(__realm)?.let {
|
|
2961
|
+
return it.later { this.onSuccess(result) }
|
|
2962
|
+
}
|
|
2963
|
+
jsReport {
|
|
2964
|
+
__resolvers1.resolve(
|
|
2965
|
+
jsConvertedStringOrEmpty(result)
|
|
2966
|
+
)
|
|
2967
|
+
}
|
|
2968
|
+
}
|
|
2969
|
+
|
|
2970
|
+
override fun onError(error: Exception?) {
|
|
2971
|
+
jsElsewhere(__realm)?.let {
|
|
2972
|
+
return it.later { this.onError(error) }
|
|
2973
|
+
}
|
|
2974
|
+
jsReport {
|
|
2975
|
+
reject(error)
|
|
2976
|
+
}
|
|
2977
|
+
}
|
|
2978
|
+
},
|
|
2979
|
+
)
|
|
2980
|
+
}
|
|
2981
|
+
}
|
|
2982
|
+
return super.readTextAsync(path, encoding)
|
|
2983
|
+
}
|
|
2984
|
+
|
|
2985
|
+
override fun readTextSync(path: String?, onError: ((Any?) -> Any?)?, encoding: Any?): String {
|
|
2986
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
2987
|
+
var callback: Any? = jsNull
|
|
2988
|
+
if (jsTypeof(onError) == "function") {
|
|
2989
|
+
callback =
|
|
2990
|
+
object : FileHelper.Callback {
|
|
2991
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
2992
|
+
|
|
2993
|
+
override fun onSuccess(result: Any?) {
|
|
2994
|
+
jsElsewhere(__realm)?.let {
|
|
2995
|
+
return it.later { this.onSuccess(result) }
|
|
2996
|
+
}
|
|
2997
|
+
}
|
|
2998
|
+
|
|
2999
|
+
override fun onError(error: Exception?) {
|
|
3000
|
+
jsElsewhere(__realm)?.let {
|
|
3001
|
+
return it.later { this.onError(error) }
|
|
3002
|
+
}
|
|
3003
|
+
jsReport {
|
|
3004
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
3005
|
+
}
|
|
3006
|
+
}
|
|
3007
|
+
}
|
|
3008
|
+
}
|
|
3009
|
+
return (Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3010
|
+
?: jsCannotRead("readTextSync"))
|
|
3011
|
+
.readTextSync(
|
|
3012
|
+
jsCastCarried(
|
|
3013
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3014
|
+
android_app_Application::class.java,
|
|
3015
|
+
)
|
|
3016
|
+
.getApplicationContext(),
|
|
3017
|
+
(jsNullishCoalesce(encoding) { jsNull } as String?),
|
|
3018
|
+
(callback as FileHelper.Callback?),
|
|
3019
|
+
)
|
|
3020
|
+
} else {
|
|
3021
|
+
return super.readTextSync(path, onError, encoding)
|
|
3022
|
+
}
|
|
3023
|
+
}
|
|
3024
|
+
|
|
3025
|
+
override fun readBufferAsync(path: String?): JSPromise<JSArrayBuffer>? {
|
|
3026
|
+
return jsAs<JSPromise<JSArrayBuffer>?>(
|
|
3027
|
+
(fun(): JSPromise<Any?>? {
|
|
3028
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3029
|
+
return JSPromise<Any?> { __resolvers1: JSResolvers<Any?> ->
|
|
3030
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
3031
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3032
|
+
?: jsCannotRead("readBuffer"))
|
|
3033
|
+
.readBuffer(
|
|
3034
|
+
jsCastCarried(
|
|
3035
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3036
|
+
android_app_Application::class.java,
|
|
3037
|
+
)
|
|
3038
|
+
.getApplicationContext(),
|
|
3039
|
+
object : FileHelper.Callback {
|
|
3040
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3041
|
+
|
|
3042
|
+
override fun onSuccess(result: Any?) {
|
|
3043
|
+
jsElsewhere(__realm)?.let {
|
|
3044
|
+
return it.later { this.onSuccess(result) }
|
|
3045
|
+
}
|
|
3046
|
+
jsReport {
|
|
3047
|
+
__resolvers1.resolve(result)
|
|
3048
|
+
}
|
|
3049
|
+
}
|
|
3050
|
+
|
|
3051
|
+
override fun onError(error: Exception?) {
|
|
3052
|
+
jsElsewhere(__realm)?.let {
|
|
3053
|
+
return it.later { this.onError(error) }
|
|
3054
|
+
}
|
|
3055
|
+
jsReport {
|
|
3056
|
+
reject(error)
|
|
3057
|
+
}
|
|
3058
|
+
}
|
|
3059
|
+
},
|
|
3060
|
+
)
|
|
3061
|
+
}
|
|
3062
|
+
}
|
|
3063
|
+
return jsAs<JSPromise<Any?>?>(super.readBufferAsync(path))
|
|
3064
|
+
})()
|
|
3065
|
+
)
|
|
3066
|
+
}
|
|
3067
|
+
|
|
3068
|
+
override fun readBufferSync(path: String?, onError: ((Any?) -> Any?)?): JSArrayBuffer? {
|
|
3069
|
+
return jsCast(
|
|
3070
|
+
(fun(): Any? {
|
|
3071
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3072
|
+
var callback: Any? = jsNull
|
|
3073
|
+
if (jsTypeof(onError) == "function") {
|
|
3074
|
+
callback =
|
|
3075
|
+
object : FileHelper.Callback {
|
|
3076
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3077
|
+
|
|
3078
|
+
override fun onSuccess(result: Any?) {
|
|
3079
|
+
jsElsewhere(__realm)?.let {
|
|
3080
|
+
return it.later { this.onSuccess(result) }
|
|
3081
|
+
}
|
|
3082
|
+
}
|
|
3083
|
+
|
|
3084
|
+
override fun onError(error: Exception?) {
|
|
3085
|
+
jsElsewhere(__realm)?.let {
|
|
3086
|
+
return it.later { this.onError(error) }
|
|
3087
|
+
}
|
|
3088
|
+
jsReport {
|
|
3089
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
3090
|
+
}
|
|
3091
|
+
}
|
|
3092
|
+
}
|
|
3093
|
+
}
|
|
3094
|
+
val ret: ByteBuffer? =
|
|
3095
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3096
|
+
?: jsCannotRead("readBufferSync"))
|
|
3097
|
+
.readBufferSync(
|
|
3098
|
+
jsCastCarried(
|
|
3099
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3100
|
+
android_app_Application::class.java,
|
|
3101
|
+
)
|
|
3102
|
+
.getApplicationContext(),
|
|
3103
|
+
(callback as FileHelper.Callback?),
|
|
3104
|
+
)
|
|
3105
|
+
if (jsTruthy(ret)) {
|
|
3106
|
+
return jsNull
|
|
3107
|
+
}
|
|
3108
|
+
return JSArrayBuffer.from((ret as ByteBuffer))
|
|
3109
|
+
}
|
|
3110
|
+
return super.readBufferSync(path, onError)
|
|
3111
|
+
})(),
|
|
3112
|
+
JSArrayBuffer::class.java,
|
|
3113
|
+
)
|
|
3114
|
+
}
|
|
3115
|
+
|
|
3116
|
+
override fun readAsync(path: String?): JSPromise<JSArray<Double>>? {
|
|
3117
|
+
return jsAs<JSPromise<JSArray<Double>>?>(
|
|
3118
|
+
(fun(): JSPromise<Any?>? {
|
|
3119
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3120
|
+
return JSPromise<Any?> { __resolvers1: JSResolvers<Any?> ->
|
|
3121
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
3122
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3123
|
+
?: jsCannotRead("read"))
|
|
3124
|
+
.read(
|
|
3125
|
+
jsCastCarried(
|
|
3126
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3127
|
+
android_app_Application::class.java,
|
|
3128
|
+
)
|
|
3129
|
+
.getApplicationContext(),
|
|
3130
|
+
object : FileHelper.Callback {
|
|
3131
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3132
|
+
|
|
3133
|
+
override fun onSuccess(result: Any?) {
|
|
3134
|
+
jsElsewhere(__realm)?.let {
|
|
3135
|
+
return it.later { this.onSuccess(result) }
|
|
3136
|
+
}
|
|
3137
|
+
jsReport {
|
|
3138
|
+
__resolvers1.resolve(result)
|
|
3139
|
+
}
|
|
3140
|
+
}
|
|
3141
|
+
|
|
3142
|
+
override fun onError(error: Exception?) {
|
|
3143
|
+
jsElsewhere(__realm)?.let {
|
|
3144
|
+
return it.later { this.onError(error) }
|
|
3145
|
+
}
|
|
3146
|
+
jsReport {
|
|
3147
|
+
reject(error)
|
|
3148
|
+
}
|
|
3149
|
+
}
|
|
3150
|
+
},
|
|
3151
|
+
)
|
|
3152
|
+
}
|
|
3153
|
+
}
|
|
3154
|
+
return jsAs<JSPromise<Any?>?>(super.readAsync(path))
|
|
3155
|
+
})()
|
|
3156
|
+
)
|
|
3157
|
+
}
|
|
3158
|
+
|
|
3159
|
+
override fun readSync(path: String?, onError: ((Any?) -> Any?)?): Any? {
|
|
3160
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3161
|
+
var callback: Any? = jsNull
|
|
3162
|
+
if (jsTypeof(onError) == "function") {
|
|
3163
|
+
callback =
|
|
3164
|
+
object : FileHelper.Callback {
|
|
3165
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3166
|
+
|
|
3167
|
+
override fun onSuccess(result: Any?) {
|
|
3168
|
+
jsElsewhere(__realm)?.let {
|
|
3169
|
+
return it.later { this.onSuccess(result) }
|
|
3170
|
+
}
|
|
3171
|
+
}
|
|
3172
|
+
|
|
3173
|
+
override fun onError(error: Exception?) {
|
|
3174
|
+
jsElsewhere(__realm)?.let {
|
|
3175
|
+
return it.later { this.onError(error) }
|
|
3176
|
+
}
|
|
3177
|
+
jsReport {
|
|
3178
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
3179
|
+
}
|
|
3180
|
+
}
|
|
3181
|
+
}
|
|
3182
|
+
}
|
|
3183
|
+
return (JSArray(
|
|
3184
|
+
((Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3185
|
+
?: jsCannotRead("readSync"))
|
|
3186
|
+
.readSync(
|
|
3187
|
+
jsCastCarried(
|
|
3188
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3189
|
+
android_app_Application::class.java,
|
|
3190
|
+
)
|
|
3191
|
+
.getApplicationContext(),
|
|
3192
|
+
(callback as FileHelper.Callback?),
|
|
3193
|
+
) ?: jsObjectRequired())
|
|
3194
|
+
.map { it.toDouble() }
|
|
3195
|
+
) ?: JSNull)
|
|
3196
|
+
}
|
|
3197
|
+
return super.readSync(path, onError)
|
|
3198
|
+
}
|
|
3199
|
+
|
|
3200
|
+
override fun writeTextAsync(path: String?, content: String?, encoding: Any?): JSPromise<Unit>? {
|
|
3201
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3202
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
3203
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
3204
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3205
|
+
?: jsCannotRead("writeText"))
|
|
3206
|
+
.writeText(
|
|
3207
|
+
jsCastCarried(
|
|
3208
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3209
|
+
android_app_Application::class.java,
|
|
3210
|
+
)
|
|
3211
|
+
.getApplicationContext(),
|
|
3212
|
+
content,
|
|
3213
|
+
(jsNullishCoalesce(encoding) { jsNull } as String?),
|
|
3214
|
+
object : FileHelper.Callback {
|
|
3215
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3216
|
+
|
|
3217
|
+
override fun onSuccess(result: Any?) {
|
|
3218
|
+
jsElsewhere(__realm)?.let {
|
|
3219
|
+
return it.later { this.onSuccess(result) }
|
|
3220
|
+
}
|
|
3221
|
+
jsReport {
|
|
3222
|
+
__resolvers1.resolve(Unit)
|
|
3223
|
+
}
|
|
3224
|
+
}
|
|
3225
|
+
|
|
3226
|
+
override fun onError(error: Exception?) {
|
|
3227
|
+
jsElsewhere(__realm)?.let {
|
|
3228
|
+
return it.later { this.onError(error) }
|
|
3229
|
+
}
|
|
3230
|
+
jsReport {
|
|
3231
|
+
reject(error)
|
|
3232
|
+
}
|
|
3233
|
+
}
|
|
3234
|
+
},
|
|
3235
|
+
)
|
|
3236
|
+
}
|
|
3237
|
+
}
|
|
3238
|
+
return super.writeTextAsync(path, content, encoding)
|
|
3239
|
+
}
|
|
3240
|
+
|
|
3241
|
+
override fun writeTextSync(
|
|
3242
|
+
path: String?,
|
|
3243
|
+
content: String?,
|
|
3244
|
+
onError: ((Any?) -> Any?)?,
|
|
3245
|
+
encoding: Any?,
|
|
3246
|
+
) {
|
|
3247
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3248
|
+
var callback: Any? = jsNull
|
|
3249
|
+
if (jsTypeof(onError) == "function") {
|
|
3250
|
+
callback =
|
|
3251
|
+
object : FileHelper.Callback {
|
|
3252
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3253
|
+
|
|
3254
|
+
override fun onSuccess(result: Any?) {
|
|
3255
|
+
jsElsewhere(__realm)?.let {
|
|
3256
|
+
return it.later { this.onSuccess(result) }
|
|
3257
|
+
}
|
|
3258
|
+
}
|
|
3259
|
+
|
|
3260
|
+
override fun onError(error: Exception?) {
|
|
3261
|
+
jsElsewhere(__realm)?.let {
|
|
3262
|
+
return it.later { this.onError(error) }
|
|
3263
|
+
}
|
|
3264
|
+
jsReport {
|
|
3265
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
3266
|
+
}
|
|
3267
|
+
}
|
|
3268
|
+
}
|
|
3269
|
+
}
|
|
3270
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3271
|
+
?: jsCannotRead("writeTextSync"))
|
|
3272
|
+
.writeTextSync(
|
|
3273
|
+
jsCastCarried(
|
|
3274
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3275
|
+
android_app_Application::class.java,
|
|
3276
|
+
)
|
|
3277
|
+
.getApplicationContext(),
|
|
3278
|
+
content,
|
|
3279
|
+
(jsNullishCoalesce(encoding) { jsNull } as String?),
|
|
3280
|
+
(callback as FileHelper.Callback?),
|
|
3281
|
+
)
|
|
3282
|
+
} else {
|
|
3283
|
+
super.writeTextSync(path, content, onError, null)
|
|
3284
|
+
}
|
|
3285
|
+
}
|
|
3286
|
+
|
|
3287
|
+
override fun writeBufferAsync(path: String?, buffer: Any?): JSPromise<Unit>? {
|
|
3288
|
+
val content = buffer
|
|
3289
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3290
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
3291
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
3292
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3293
|
+
?: jsCannotRead("writeBuffer"))
|
|
3294
|
+
.writeBuffer(
|
|
3295
|
+
jsCastCarried(
|
|
3296
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3297
|
+
android_app_Application::class.java,
|
|
3298
|
+
)
|
|
3299
|
+
.getApplicationContext(),
|
|
3300
|
+
(FileSystemAccess.getBuffer(content) as ByteBuffer?),
|
|
3301
|
+
object : FileHelper.Callback {
|
|
3302
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3303
|
+
|
|
3304
|
+
override fun onSuccess(result: Any?) {
|
|
3305
|
+
jsElsewhere(__realm)?.let {
|
|
3306
|
+
return it.later { this.onSuccess(result) }
|
|
3307
|
+
}
|
|
3308
|
+
jsReport {
|
|
3309
|
+
__resolvers1.resolve(Unit)
|
|
3310
|
+
}
|
|
3311
|
+
}
|
|
3312
|
+
|
|
3313
|
+
override fun onError(error: Exception?) {
|
|
3314
|
+
jsElsewhere(__realm)?.let {
|
|
3315
|
+
return it.later { this.onError(error) }
|
|
3316
|
+
}
|
|
3317
|
+
jsReport {
|
|
3318
|
+
reject(error)
|
|
3319
|
+
}
|
|
3320
|
+
}
|
|
3321
|
+
},
|
|
3322
|
+
)
|
|
3323
|
+
}
|
|
3324
|
+
}
|
|
3325
|
+
return super.writeAsync(
|
|
3326
|
+
path,
|
|
3327
|
+
(if (jsIsNullish(content)) null else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
3328
|
+
)
|
|
3329
|
+
}
|
|
3330
|
+
|
|
3331
|
+
override fun writeBufferSync(path: String?, buffer: Any?, onError: ((Any?) -> Any?)?) {
|
|
3332
|
+
val content = buffer
|
|
3333
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3334
|
+
var callback: Any? = jsNull
|
|
3335
|
+
if (jsTypeof(onError) == "function") {
|
|
3336
|
+
callback =
|
|
3337
|
+
object : FileHelper.Callback {
|
|
3338
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3339
|
+
|
|
3340
|
+
override fun onSuccess(result: Any?) {
|
|
3341
|
+
jsElsewhere(__realm)?.let {
|
|
3342
|
+
return it.later { this.onSuccess(result) }
|
|
3343
|
+
}
|
|
3344
|
+
}
|
|
3345
|
+
|
|
3346
|
+
override fun onError(error: Exception?) {
|
|
3347
|
+
jsElsewhere(__realm)?.let {
|
|
3348
|
+
return it.later { this.onError(error) }
|
|
3349
|
+
}
|
|
3350
|
+
jsReport {
|
|
3351
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
3352
|
+
}
|
|
3353
|
+
}
|
|
3354
|
+
}
|
|
3355
|
+
}
|
|
3356
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3357
|
+
?: jsCannotRead("writeSync"))
|
|
3358
|
+
.writeSync(
|
|
3359
|
+
jsCastCarried(
|
|
3360
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3361
|
+
android_app_Application::class.java,
|
|
3362
|
+
)
|
|
3363
|
+
.getApplicationContext(),
|
|
3364
|
+
(toJavaValue(FileSystemAccess.getBuffer(content), ByteArray::class.java)
|
|
3365
|
+
as ByteArray?),
|
|
3366
|
+
(callback as FileHelper.Callback?),
|
|
3367
|
+
)
|
|
3368
|
+
} else {
|
|
3369
|
+
super.writeSync(
|
|
3370
|
+
path,
|
|
3371
|
+
(if (jsIsNullish(content)) null
|
|
3372
|
+
else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
3373
|
+
onError,
|
|
3374
|
+
)
|
|
3375
|
+
}
|
|
3376
|
+
}
|
|
3377
|
+
|
|
3378
|
+
override fun writeAsync(path: String?, bytes: JSArray<Double>?): JSPromise<Unit>? {
|
|
3379
|
+
val content: Any? = bytes
|
|
3380
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3381
|
+
return JSPromise<Unit> { __resolvers1: JSResolvers<Unit> ->
|
|
3382
|
+
val reject: (Any?) -> Unit = { __resolvers1.reject(it) }
|
|
3383
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3384
|
+
?: jsCannotRead("write"))
|
|
3385
|
+
.write(
|
|
3386
|
+
jsCastCarried(
|
|
3387
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3388
|
+
android_app_Application::class.java,
|
|
3389
|
+
)
|
|
3390
|
+
.getApplicationContext(),
|
|
3391
|
+
(toJavaValue(content, ByteArray::class.java) as ByteArray?),
|
|
3392
|
+
object : FileHelper.Callback {
|
|
3393
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3394
|
+
|
|
3395
|
+
override fun onSuccess(result: Any?) {
|
|
3396
|
+
jsElsewhere(__realm)?.let {
|
|
3397
|
+
return it.later { this.onSuccess(result) }
|
|
3398
|
+
}
|
|
3399
|
+
jsReport {
|
|
3400
|
+
__resolvers1.resolve(Unit)
|
|
3401
|
+
}
|
|
3402
|
+
}
|
|
3403
|
+
|
|
3404
|
+
override fun onError(error: Exception?) {
|
|
3405
|
+
jsElsewhere(__realm)?.let {
|
|
3406
|
+
return it.later { this.onError(error) }
|
|
3407
|
+
}
|
|
3408
|
+
jsReport {
|
|
3409
|
+
reject(error)
|
|
3410
|
+
}
|
|
3411
|
+
}
|
|
3412
|
+
},
|
|
3413
|
+
)
|
|
3414
|
+
}
|
|
3415
|
+
}
|
|
3416
|
+
return super.writeAsync(
|
|
3417
|
+
path,
|
|
3418
|
+
(if (jsIsNullish(content)) null else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
3419
|
+
)
|
|
3420
|
+
}
|
|
3421
|
+
|
|
3422
|
+
override fun writeSync(path: String?, bytes: JSArray<Double>?, onError: ((Any?) -> Any?)?) {
|
|
3423
|
+
val content: Any? = bytes
|
|
3424
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3425
|
+
var callback: Any? = jsNull
|
|
3426
|
+
if (jsTypeof(onError) == "function") {
|
|
3427
|
+
callback =
|
|
3428
|
+
object : FileHelper.Callback {
|
|
3429
|
+
private val __realm: JSRealm? = JSRealm.current()
|
|
3430
|
+
|
|
3431
|
+
override fun onSuccess(result: Any?) {
|
|
3432
|
+
jsElsewhere(__realm)?.let {
|
|
3433
|
+
return it.later { this.onSuccess(result) }
|
|
3434
|
+
}
|
|
3435
|
+
}
|
|
3436
|
+
|
|
3437
|
+
override fun onError(error: Exception?) {
|
|
3438
|
+
jsElsewhere(__realm)?.let {
|
|
3439
|
+
return it.later { this.onError(error) }
|
|
3440
|
+
}
|
|
3441
|
+
jsReport {
|
|
3442
|
+
(onError ?: jsNotAFunction("onError"))(error)
|
|
3443
|
+
}
|
|
3444
|
+
}
|
|
3445
|
+
}
|
|
3446
|
+
}
|
|
3447
|
+
(Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3448
|
+
?: jsCannotRead("writeSync"))
|
|
3449
|
+
.writeSync(
|
|
3450
|
+
jsCastCarried(
|
|
3451
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3452
|
+
android_app_Application::class.java,
|
|
3453
|
+
)
|
|
3454
|
+
.getApplicationContext(),
|
|
3455
|
+
(toJavaValue(content, ByteArray::class.java) as ByteArray?),
|
|
3456
|
+
(callback as FileHelper.Callback?),
|
|
3457
|
+
)
|
|
3458
|
+
} else {
|
|
3459
|
+
super.writeSync(
|
|
3460
|
+
path,
|
|
3461
|
+
(if (jsIsNullish(content)) null
|
|
3462
|
+
else jsArrayFrom(content) { jsConvertedNumber(it) }),
|
|
3463
|
+
onError,
|
|
3464
|
+
)
|
|
3465
|
+
}
|
|
3466
|
+
}
|
|
3467
|
+
|
|
3468
|
+
override fun getFileExtension(path: String?): String {
|
|
3469
|
+
if (Core_file_system_file_system_access.isContentUri(path)) {
|
|
3470
|
+
return (Core_file_system_file_system_access.getOrSetHelper(path)
|
|
3471
|
+
?: jsCannotRead("getExtension"))
|
|
3472
|
+
.getExtension()
|
|
3473
|
+
}
|
|
3474
|
+
return super.getFileExtension(path)
|
|
3475
|
+
}
|
|
3476
|
+
|
|
3477
|
+
override fun getPathSeparator(): String {
|
|
3478
|
+
return super.getPathSeparator()
|
|
3479
|
+
}
|
|
3480
|
+
|
|
3481
|
+
override fun normalizePath(path: String?): String {
|
|
3482
|
+
return super.normalizePath(path)
|
|
3483
|
+
}
|
|
3484
|
+
|
|
3485
|
+
override fun joinPath(left: String?, right: String?): String {
|
|
3486
|
+
return super.joinPath(left, right)
|
|
3487
|
+
}
|
|
3488
|
+
|
|
3489
|
+
override fun joinPaths(paths: JSArray<String>?): String {
|
|
3490
|
+
return super.joinPaths(paths)
|
|
3491
|
+
}
|
|
3492
|
+
|
|
3493
|
+
override val jsKeys: List<String>
|
|
3494
|
+
get() = super.jsKeys + listOf("__skip")
|
|
3495
|
+
|
|
3496
|
+
override val jsClassName: String?
|
|
3497
|
+
get() = "FileSystemAccess29"
|
|
3498
|
+
|
|
3499
|
+
override fun jsGet(key: String): Any? =
|
|
3500
|
+
when (key) {
|
|
3501
|
+
"__skip" -> this.__skip
|
|
3502
|
+
"getLastModified" ->
|
|
3503
|
+
jsFunction { __a ->
|
|
3504
|
+
this.getLastModified_(jsConvertedStringOrNull(__a.getOrNull(0)))
|
|
3505
|
+
}
|
|
3506
|
+
"getFileSize" ->
|
|
3507
|
+
jsFunction { __a -> this.getFileSize(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
3508
|
+
"getParent" ->
|
|
3509
|
+
jsFunction { __a ->
|
|
3510
|
+
this.getParent_(
|
|
3511
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3512
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3513
|
+
)
|
|
3514
|
+
}
|
|
3515
|
+
"getFile" ->
|
|
3516
|
+
jsFunction { __a ->
|
|
3517
|
+
this.getFile(
|
|
3518
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3519
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3520
|
+
)
|
|
3521
|
+
}
|
|
3522
|
+
"getFolder" ->
|
|
3523
|
+
jsFunction { __a ->
|
|
3524
|
+
this.getFolder(
|
|
3525
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3526
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3527
|
+
)
|
|
3528
|
+
}
|
|
3529
|
+
"getEntities" ->
|
|
3530
|
+
jsFunction { __a ->
|
|
3531
|
+
this.getEntities(
|
|
3532
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3533
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3534
|
+
)
|
|
3535
|
+
}
|
|
3536
|
+
"fileExists" ->
|
|
3537
|
+
jsFunction { __a -> this.fileExists(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
3538
|
+
"folderExists" ->
|
|
3539
|
+
jsFunction { __a -> this.folderExists(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
3540
|
+
"deleteFile" ->
|
|
3541
|
+
jsFunction { __a ->
|
|
3542
|
+
this.deleteFile(
|
|
3543
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3544
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3545
|
+
)
|
|
3546
|
+
null
|
|
3547
|
+
}
|
|
3548
|
+
"deleteFolder" ->
|
|
3549
|
+
jsFunction { __a ->
|
|
3550
|
+
this.deleteFolder(
|
|
3551
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3552
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3553
|
+
)
|
|
3554
|
+
null
|
|
3555
|
+
}
|
|
3556
|
+
"emptyFolder" ->
|
|
3557
|
+
jsFunction { __a ->
|
|
3558
|
+
this.emptyFolder(
|
|
3559
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3560
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3561
|
+
)
|
|
3562
|
+
null
|
|
3563
|
+
}
|
|
3564
|
+
"rename" ->
|
|
3565
|
+
jsFunction { __a ->
|
|
3566
|
+
this.rename(
|
|
3567
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3568
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3569
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3570
|
+
)
|
|
3571
|
+
null
|
|
3572
|
+
}
|
|
3573
|
+
"renameAsync" ->
|
|
3574
|
+
jsFunction { __a ->
|
|
3575
|
+
this.renameAsync(
|
|
3576
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3577
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3578
|
+
)
|
|
3579
|
+
}
|
|
3580
|
+
"getDocumentsFolderPath" -> jsFunction { this.getDocumentsFolderPath() }
|
|
3581
|
+
"getTempFolderPath" -> jsFunction { this.getTempFolderPath() }
|
|
3582
|
+
"getLogicalRootPath" -> jsFunction { this.getLogicalRootPath() }
|
|
3583
|
+
"getCurrentAppPath" -> jsFunction { this.getCurrentAppPath() }
|
|
3584
|
+
"appendBufferAsync" ->
|
|
3585
|
+
jsFunction { __a ->
|
|
3586
|
+
this.appendBufferAsync(
|
|
3587
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3588
|
+
__a.getOrNull(1),
|
|
3589
|
+
)
|
|
3590
|
+
}
|
|
3591
|
+
"appendBufferSync" ->
|
|
3592
|
+
jsFunction { __a ->
|
|
3593
|
+
this.appendBufferSync(
|
|
3594
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3595
|
+
__a.getOrNull(1),
|
|
3596
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3597
|
+
)
|
|
3598
|
+
null
|
|
3599
|
+
}
|
|
3600
|
+
"appendTextAsync" ->
|
|
3601
|
+
jsFunction { __a ->
|
|
3602
|
+
this.appendTextAsync(
|
|
3603
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3604
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3605
|
+
__a.getOrNull(2),
|
|
3606
|
+
)
|
|
3607
|
+
}
|
|
3608
|
+
"appendTextSync" ->
|
|
3609
|
+
jsFunction { __a ->
|
|
3610
|
+
this.appendTextSync(
|
|
3611
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3612
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3613
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3614
|
+
__a.getOrNull(3),
|
|
3615
|
+
)
|
|
3616
|
+
null
|
|
3617
|
+
}
|
|
3618
|
+
"readTextAsync" ->
|
|
3619
|
+
jsFunction { __a ->
|
|
3620
|
+
this.readTextAsync(jsConvertedStringOrNull(__a.getOrNull(0)), __a.getOrNull(1))
|
|
3621
|
+
}
|
|
3622
|
+
"readTextSync" ->
|
|
3623
|
+
jsFunction { __a ->
|
|
3624
|
+
this.readTextSync(
|
|
3625
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3626
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3627
|
+
__a.getOrNull(2),
|
|
3628
|
+
)
|
|
3629
|
+
}
|
|
3630
|
+
"readSync" ->
|
|
3631
|
+
jsFunction { __a ->
|
|
3632
|
+
this.readSync(
|
|
3633
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3634
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3635
|
+
)
|
|
3636
|
+
}
|
|
3637
|
+
"writeTextAsync" ->
|
|
3638
|
+
jsFunction { __a ->
|
|
3639
|
+
this.writeTextAsync(
|
|
3640
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3641
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3642
|
+
__a.getOrNull(2),
|
|
3643
|
+
)
|
|
3644
|
+
}
|
|
3645
|
+
"writeTextSync" ->
|
|
3646
|
+
jsFunction { __a ->
|
|
3647
|
+
this.writeTextSync(
|
|
3648
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3649
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3650
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3651
|
+
__a.getOrNull(3),
|
|
3652
|
+
)
|
|
3653
|
+
null
|
|
3654
|
+
}
|
|
3655
|
+
"writeBufferAsync" ->
|
|
3656
|
+
jsFunction { __a ->
|
|
3657
|
+
this.writeBufferAsync(
|
|
3658
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3659
|
+
__a.getOrNull(1),
|
|
3660
|
+
)
|
|
3661
|
+
}
|
|
3662
|
+
"writeBufferSync" ->
|
|
3663
|
+
jsFunction { __a ->
|
|
3664
|
+
this.writeBufferSync(
|
|
3665
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3666
|
+
__a.getOrNull(1),
|
|
3667
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3668
|
+
)
|
|
3669
|
+
null
|
|
3670
|
+
}
|
|
3671
|
+
"getFileExtension" ->
|
|
3672
|
+
jsFunction { __a ->
|
|
3673
|
+
this.getFileExtension(jsConvertedStringOrNull(__a.getOrNull(0)))
|
|
3674
|
+
}
|
|
3675
|
+
"getPathSeparator" -> jsFunction { this.getPathSeparator() }
|
|
3676
|
+
"normalizePath" ->
|
|
3677
|
+
jsFunction { __a -> this.normalizePath(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
3678
|
+
"joinPath" ->
|
|
3679
|
+
jsFunction { __a ->
|
|
3680
|
+
this.joinPath(
|
|
3681
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3682
|
+
jsConvertedStringOrNull(__a.getOrNull(1)),
|
|
3683
|
+
)
|
|
3684
|
+
}
|
|
3685
|
+
"joinPaths" ->
|
|
3686
|
+
jsFunction { __a ->
|
|
3687
|
+
this.joinPaths(
|
|
3688
|
+
(if (jsIsNullish(__a.getOrNull(0))) null
|
|
3689
|
+
else jsArrayFrom(__a.getOrNull(0)) { jsConvertedString(it) })
|
|
3690
|
+
)
|
|
3691
|
+
}
|
|
3692
|
+
"eachEntity" ->
|
|
3693
|
+
jsFunction { __a ->
|
|
3694
|
+
this.eachEntity(
|
|
3695
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3696
|
+
jsFunction1<Any?, Boolean>(__a.getOrNull(1)),
|
|
3697
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3698
|
+
)
|
|
3699
|
+
null
|
|
3700
|
+
}
|
|
3701
|
+
"appendAsync" ->
|
|
3702
|
+
jsFunction { __a ->
|
|
3703
|
+
this.appendAsync(
|
|
3704
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3705
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
3706
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
3707
|
+
)
|
|
3708
|
+
}
|
|
3709
|
+
"appendSync" ->
|
|
3710
|
+
jsFunction { __a ->
|
|
3711
|
+
this.appendSync(
|
|
3712
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3713
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
3714
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
3715
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3716
|
+
)
|
|
3717
|
+
null
|
|
3718
|
+
}
|
|
3719
|
+
"readBufferAsync" ->
|
|
3720
|
+
jsFunction { __a ->
|
|
3721
|
+
this.readBufferAsync(jsConvertedStringOrNull(__a.getOrNull(0)))
|
|
3722
|
+
}
|
|
3723
|
+
"readBufferSync" ->
|
|
3724
|
+
jsFunction { __a ->
|
|
3725
|
+
this.readBufferSync(
|
|
3726
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3727
|
+
jsUnlessNullish(__a.getOrNull(1)) { jsFunction1<Any?, Any?>(it) },
|
|
3728
|
+
)
|
|
3729
|
+
}
|
|
3730
|
+
"readAsync" ->
|
|
3731
|
+
jsFunction { __a -> this.readAsync(jsConvertedStringOrNull(__a.getOrNull(0))) }
|
|
3732
|
+
"writeAsync" ->
|
|
3733
|
+
jsFunction { __a ->
|
|
3734
|
+
this.writeAsync(
|
|
3735
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3736
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
3737
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
3738
|
+
)
|
|
3739
|
+
}
|
|
3740
|
+
"writeSync" ->
|
|
3741
|
+
jsFunction { __a ->
|
|
3742
|
+
this.writeSync(
|
|
3743
|
+
jsConvertedStringOrNull(__a.getOrNull(0)),
|
|
3744
|
+
(if (jsIsNullish(__a.getOrNull(1))) null
|
|
3745
|
+
else jsArrayFrom(__a.getOrNull(1)) { jsConvertedNumber(it) }),
|
|
3746
|
+
jsUnlessNullish(__a.getOrNull(2)) { jsFunction1<Any?, Any?>(it) },
|
|
3747
|
+
)
|
|
3748
|
+
null
|
|
3749
|
+
}
|
|
3750
|
+
else -> super.jsGet(key)
|
|
3751
|
+
}
|
|
3752
|
+
|
|
3753
|
+
override fun jsSet(key: String, value: Any?) {
|
|
3754
|
+
when (key) {
|
|
3755
|
+
"__skip" -> this.__skip = jsConvertedBoolean(value, "__skip")
|
|
3756
|
+
else -> super.jsSet(key, value)
|
|
3757
|
+
}
|
|
3758
|
+
}
|
|
3759
|
+
|
|
3760
|
+
override fun jsHasMember(key: String): Boolean =
|
|
3761
|
+
when (key) {
|
|
3762
|
+
"getLastModified",
|
|
3763
|
+
"getFileSize",
|
|
3764
|
+
"getParent",
|
|
3765
|
+
"getFile",
|
|
3766
|
+
"getFolder",
|
|
3767
|
+
"getEntities",
|
|
3768
|
+
"fileExists",
|
|
3769
|
+
"folderExists",
|
|
3770
|
+
"deleteFile",
|
|
3771
|
+
"deleteFolder",
|
|
3772
|
+
"emptyFolder",
|
|
3773
|
+
"rename",
|
|
3774
|
+
"renameAsync",
|
|
3775
|
+
"getDocumentsFolderPath",
|
|
3776
|
+
"getTempFolderPath",
|
|
3777
|
+
"getLogicalRootPath",
|
|
3778
|
+
"getCurrentAppPath",
|
|
3779
|
+
"appendBufferAsync",
|
|
3780
|
+
"appendBufferSync",
|
|
3781
|
+
"appendTextAsync",
|
|
3782
|
+
"appendTextSync",
|
|
3783
|
+
"readTextAsync",
|
|
3784
|
+
"readTextSync",
|
|
3785
|
+
"readSync",
|
|
3786
|
+
"writeTextAsync",
|
|
3787
|
+
"writeTextSync",
|
|
3788
|
+
"writeBufferAsync",
|
|
3789
|
+
"writeBufferSync",
|
|
3790
|
+
"getFileExtension",
|
|
3791
|
+
"getPathSeparator",
|
|
3792
|
+
"normalizePath",
|
|
3793
|
+
"joinPath",
|
|
3794
|
+
"joinPaths",
|
|
3795
|
+
"eachEntity",
|
|
3796
|
+
"appendAsync",
|
|
3797
|
+
"appendSync",
|
|
3798
|
+
"readBufferAsync",
|
|
3799
|
+
"readBufferSync",
|
|
3800
|
+
"readAsync",
|
|
3801
|
+
"writeAsync",
|
|
3802
|
+
"writeSync" -> true
|
|
3803
|
+
else -> super<FileSystemAccess>.jsHasMember(key)
|
|
3804
|
+
}
|
|
3805
|
+
}
|
|
3806
|
+
|
|
3807
|
+
@AnyThread
|
|
3808
|
+
object Core_file_system_file_system_access {
|
|
3809
|
+
fun getOrSetHelper(path: String?): FileHelper? {
|
|
3810
|
+
return FileHelper.fromString(
|
|
3811
|
+
jsCastCarried(
|
|
3812
|
+
Core_application_helpers_common.getNativeApp(),
|
|
3813
|
+
android_app_Application::class.java,
|
|
3814
|
+
)
|
|
3815
|
+
.getApplicationContext(),
|
|
3816
|
+
path,
|
|
3817
|
+
)
|
|
3818
|
+
}
|
|
3819
|
+
|
|
3820
|
+
fun isContentUri(path: String?): Boolean {
|
|
3821
|
+
if (
|
|
3822
|
+
jsTypeof(path) == "string" && jsStartsWith((path ?: "undefined"), "content:")
|
|
3823
|
+
) {
|
|
3824
|
+
return true
|
|
3825
|
+
}
|
|
3826
|
+
return false
|
|
3827
|
+
}
|
|
3828
|
+
}
|