@dynatrace/react-native-plugin 2.275.1 → 2.279.1

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.
Files changed (48) hide show
  1. package/README.md +128 -41
  2. package/android/build.gradle +1 -1
  3. package/files/plugin.gradle +1 -1
  4. package/index.js +1 -0
  5. package/ios/lib/Dynatrace.xcframework/Info.plist +9 -9
  6. package/ios/lib/Dynatrace.xcframework/ios-arm64/Dynatrace.framework/Dynatrace +0 -0
  7. package/ios/lib/Dynatrace.xcframework/ios-arm64/Dynatrace.framework/Headers/Dynatrace.h +1 -1
  8. package/ios/lib/Dynatrace.xcframework/ios-arm64/Dynatrace.framework/Info.plist +0 -0
  9. package/ios/lib/Dynatrace.xcframework/ios-arm64/Dynatrace.framework/Modules/Dynatrace.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
  10. package/ios/lib/Dynatrace.xcframework/ios-arm64/Dynatrace.framework/Modules/Dynatrace.swiftmodule/arm64-apple-ios.abi.json +1 -1
  11. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Dynatrace +0 -0
  12. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Headers/Dynatrace.h +1 -1
  13. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Info.plist +0 -0
  14. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Modules/Dynatrace.swiftmodule/Project/arm64-apple-ios-simulator.swiftsourceinfo +0 -0
  15. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Modules/Dynatrace.swiftmodule/Project/x86_64-apple-ios-simulator.swiftsourceinfo +0 -0
  16. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Modules/Dynatrace.swiftmodule/arm64-apple-ios-simulator.abi.json +1 -1
  17. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/Modules/Dynatrace.swiftmodule/x86_64-apple-ios-simulator.abi.json +1 -1
  18. package/ios/lib/Dynatrace.xcframework/ios-arm64_x86_64-simulator/Dynatrace.framework/_CodeSignature/CodeResources +15 -15
  19. package/ios/lib/Dynatrace.xcframework/tvos-arm64/Dynatrace.framework/Dynatrace +0 -0
  20. package/ios/lib/Dynatrace.xcframework/tvos-arm64/Dynatrace.framework/Headers/Dynatrace.h +1 -1
  21. package/ios/lib/Dynatrace.xcframework/tvos-arm64/Dynatrace.framework/Info.plist +0 -0
  22. package/ios/lib/Dynatrace.xcframework/tvos-arm64/Dynatrace.framework/Modules/Dynatrace.swiftmodule/Project/arm64-apple-tvos.swiftsourceinfo +0 -0
  23. package/ios/lib/Dynatrace.xcframework/tvos-arm64_x86_64-simulator/Dynatrace.framework/Dynatrace +0 -0
  24. package/ios/lib/Dynatrace.xcframework/tvos-arm64_x86_64-simulator/Dynatrace.framework/Headers/Dynatrace.h +1 -1
  25. package/ios/lib/Dynatrace.xcframework/tvos-arm64_x86_64-simulator/Dynatrace.framework/Info.plist +0 -0
  26. package/ios/lib/Dynatrace.xcframework/tvos-arm64_x86_64-simulator/Dynatrace.framework/Modules/Dynatrace.swiftmodule/Project/arm64-apple-tvos-simulator.swiftsourceinfo +0 -0
  27. package/ios/lib/Dynatrace.xcframework/tvos-arm64_x86_64-simulator/Dynatrace.framework/Modules/Dynatrace.swiftmodule/Project/x86_64-apple-tvos-simulator.swiftsourceinfo +0 -0
  28. package/ios/lib/Dynatrace.xcframework/tvos-arm64_x86_64-simulator/Dynatrace.framework/_CodeSignature/CodeResources +11 -11
  29. package/lib/instrumentor/DynatraceInstrumentation.js +1 -1
  30. package/lib/instrumentor/base/Application.js +4 -3
  31. package/lib/instrumentor/base/Dynatrace.js +27 -27
  32. package/lib/instrumentor/base/DynatraceRootAction.js +3 -3
  33. package/lib/instrumentor/base/Logger.js +2 -2
  34. package/lib/instrumentor/base/Touchable.js +3 -3
  35. package/lib/instrumentor/base/configuration/Configuration.js +13 -18
  36. package/lib/instrumentor/base/configuration/ConfigurationBuilder.js +56 -0
  37. package/lib/instrumentor/base/configuration/ConfigurationDefaults.js +2 -10
  38. package/lib/instrumentor/base/configuration/ConfigurationHandler.js +15 -0
  39. package/lib/instrumentor/base/configuration/ConfigurationPreset.js +23 -0
  40. package/lib/instrumentor/base/configuration/ManualStartupConfiguration.js +6 -4
  41. package/lib/react/Component.js +6 -6
  42. package/lib/react-navigation/ReactNavigation.js +22 -0
  43. package/package.json +1 -1
  44. package/scripts/Config.js +3 -0
  45. package/typings/react-native-dynatrace.d.ts +189 -3
  46. package/lib/instrumentor/base/configuration/AutoStartupConfiguration.js +0 -28
  47. package/lib/instrumentor/base/configuration/interface/IAutoConfiguration.js +0 -2
  48. /package/lib/instrumentor/base/configuration/{interface/IManualConfiguration.js → IConfiguration.js} +0 -0
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.DynatraceClassWrapper = exports.DynatraceFnWrapper = void 0;
4
- const React = require("react");
5
- const Configuration_1 = require("../instrumentor/base/configuration/Configuration");
4
+ const react_1 = require("react");
5
+ const ConfigurationHandler_1 = require("../instrumentor/base/configuration/ConfigurationHandler");
6
6
  const Logger_1 = require("../instrumentor/base/Logger");
7
7
  const NullAction_1 = require("../instrumentor/base/NullAction");
8
8
  const Dynatrace_1 = require("../instrumentor/base/Dynatrace");
@@ -12,24 +12,24 @@ const DynatraceFnWrapper = (props) => {
12
12
  if (action instanceof NullAction_1.NullAction) {
13
13
  Logger_1.Logger.logInfo(`Component ${componentName}: React Native plugin has not been started yet! Component will not be reported!`);
14
14
  }
15
- React.useEffect(() => {
15
+ (0, react_1.useEffect)(() => {
16
16
  action.leaveAction();
17
17
  });
18
18
  return props.children;
19
19
  };
20
20
  exports.DynatraceFnWrapper = DynatraceFnWrapper;
21
- class DynatraceClassWrapper extends React.Component {
21
+ class DynatraceClassWrapper extends react_1.Component {
22
22
  constructor(props) {
23
23
  super(props);
24
24
  this.wrappingName = getNameFromComponent(props);
25
25
  this.componentMounted = false;
26
26
  }
27
27
  render() {
28
- if (!Configuration_1.Configuration.isConfigurationAvailable()) {
28
+ if (!ConfigurationHandler_1.ConfigurationHandler.isConfigurationAvailable()) {
29
29
  Logger_1.Logger.logInfo(`Component ${this.wrappingName}: React Native plugin has not been started yet! Component will not be reported!`);
30
30
  }
31
31
  else {
32
- if ((this.componentMounted && Configuration_1.Configuration.isLifecycleUpdateEnabled()) ||
32
+ if ((this.componentMounted && ConfigurationHandler_1.ConfigurationHandler.isLifecycleUpdateEnabled()) ||
33
33
  !this.componentMounted) {
34
34
  const actionPrefix = !this.componentMounted ? 'Render ' : 'Update ';
35
35
  this.internalAction = Dynatrace_1.Dynatrace.enterAutoAction(actionPrefix + this.wrappingName);
@@ -0,0 +1,22 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.registerListener = void 0;
4
+ const React = require("react");
5
+ const Logger_1 = require("../instrumentor/base/Logger");
6
+ let isRegistered = false;
7
+ const registerListener = (navContainer) => {
8
+ React.useEffect(() => {
9
+ if (isRegistered && navContainer.current != null && navContainer.current.addListener != null) {
10
+ isRegistered = true;
11
+ navContainer.current.addListener('__unsafe_action__', (data) => {
12
+ if (data != null && data.data != null && data.data.action != null) {
13
+ Logger_1.Logger.logDebug(`ReactNavigation Listener Dispatch: ${JSON.stringify(data.data.action)}`);
14
+ }
15
+ });
16
+ navContainer.current.addListener('state', (state) => {
17
+ Logger_1.Logger.logDebug(`ReactNavigation Listener State: ${JSON.stringify(state)}`);
18
+ });
19
+ }
20
+ });
21
+ };
22
+ exports.registerListener = registerListener;
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"@dynatrace/react-native-plugin","version":"2.275.1","description":"This plugin gives you the ability to use the Dynatrace Mobile agent in your react native application.","main":"index.js","types":"typings/react-native-dynatrace.d.ts","bin":{"instrumentDynatrace":"scripts/Instrument.js","configDynatrace":"scripts/CheckConfig.js"},"keywords":["react-native","dynatrace","mobile","android","ios","performance","monitoring"],"rnpm":{"plugin":"./command/command.js"},"scripts":{"uninstall":"node ./scripts/Uninstall.js","test":"jest --runInBand","test:debug":"node --inspect-brk ./node_modules/jest/bin/jest.js --runInBand","tsc":"tsc","tsc:prod":"tsc -p tsconfig.release.json","lint":"eslint --cache src/**/*.ts --ignore-pattern .gitignore","lint:spec":"eslint --cache tests/**/*.ts --cache-file tests/.eslintcache --ignore-pattern .gitignore --fix"},"jest":{"preset":"react-native","moduleDirectories":["node_modules"],"unmockedModulePathPatterns":["node_modules"],"modulePathIgnorePatterns":["<rootDir>/src","<rootDir>/tests/commandTestTmp","node_modules/react-native/local-cli"],"transform":{"^.+\\.(ts|tsx)$":"ts-jest"},"testPathIgnorePatterns":["<rootDir>/src","<rootDir>/tests/commandTestTmp"],"transformIgnorePatterns":["node_modules/(?!(@react-native|react-native)/)"],"setupFiles":["<rootDir>/tests/setup/setup.js"],"testResultsProcessor":"jest-junit","testRegex":["(/__tests__/.*|(\\.|/)(Test|spec))\\.[jt]sx?$"]},"jest-junit":{"suiteName":"jest tests","outputDirectory":".","outputName":"junit.xml","uniqueOutputName":"true","ancestorSeparator":" › ","usePathForSuiteName":"true"},"author":"Dynatrace","license":"SEE LICENSE IN LICENSE.md","dependencies":{"@babel/runtime":"^7.22.15","jscodeshift":"^0.15.0","plist":"^3.1.0","proxy-polyfill":"^0.3.2","semver":"^7.5.4"},"homepage":"https://www.dynatrace.com/","peerDependencies":{"@babel/parser":">=7.4.4","@react-native-picker/picker":">=1.0.0","react":">=16.8.0","react-native":">=0.59.0"},"devDependencies":{"@babel/cli":"^7.22.9","@babel/plugin-proposal-class-properties":"^7.8.3","@babel/plugin-proposal-nullish-coalescing-operator":"^7.8.3","@babel/plugin-proposal-optional-chaining":"^7.8.3","@babel/plugin-transform-flow-strip-types":"^7.8.3","@babel/plugin-transform-runtime":"^7.12.1","@babel/preset-env":"^7.4.4","@babel/preset-react":"^7.8.3","@testing-library/react-native":"^7.0.2","@types/jest":"^26.0.19","@types/jscodeshift":"^0.11.6","@types/libxmljs":"^0.18.3","@types/node":"^18.17.12","@types/plist":"^3.0.2","@types/react-native":"^0.63.32","@types/semver":"^7.5.0","@types/shelljs":"^0.8.8","@types/uglify-js":"^3.17.1","@typescript-eslint/eslint-plugin":"^5.16.0","@typescript-eslint/parser":"^5.16.0","compressing":"^1.5.1","eslint":"^8.45.0","eslint-config-prettier":"^8.5.0","eslint-plugin-import":"^2.26.0","eslint-plugin-jsdoc":"^39.1.0","eslint-plugin-prefer-arrow":"^1.2.3","eslint-plugin-unicorn":"^42.0.0","jest":"24.9.0","jest-each":"^28.1.3","jest-junit":"^14.0.0","jest-mock":"^28.1.3","npm-check-updates":"^16.10.12","prettier":"^2.6.1","shelljs":"^0.8.5","ts-jest":"24.3.0","ts-mockito":"^2.6.1","typescript":"^4.7.4","uglify-js":"^3.17.4","react-native":"0.71.3","react":"18.2.0","react-test-renderer":"18.2.0"},"files":["command/command.js","command/util/*","command/interface/*","android/build.gradle","android/src/main/**/*","ios/**/*","files/*","lib/instrumentor/base/*.js","lib/instrumentor/base/model/*.js","lib/instrumentor/base/configuration/*.js","lib/instrumentor/base/configuration/interface/*.js","lib/instrumentor/base/interface/*.js","lib/instrumentor/base/util/*.js","lib/instrumentor/model/*.js","lib/instrumentor/parser/*.js","lib/instrumentor/DynatraceInstrumentation.js","lib/*.js","lib/community/*.js","lib/community/gesture-handler/*.js","lib/react-native/*.js","lib/react/*.js","lib/metro/*.js","lib/util/*.js","react-native.config.js","react-native-dynatrace.js","react-native-dynatrace.podspec","README.md","LICENSE.md","scripts/*","scripts/api/*","scripts/core/*","scripts/api/model/*","scripts/util/*","typings/*","package.json","jsx-runtime.js"]}
1
+ {"name":"@dynatrace/react-native-plugin","version":"2.279.1","description":"This plugin gives you the ability to use the Dynatrace Mobile agent in your react native application.","main":"index.js","types":"typings/react-native-dynatrace.d.ts","bin":{"instrumentDynatrace":"scripts/Instrument.js","configDynatrace":"scripts/CheckConfig.js"},"keywords":["react-native","dynatrace","mobile","android","ios","performance","monitoring"],"rnpm":{"plugin":"./command/command.js"},"scripts":{"uninstall":"node ./scripts/Uninstall.js","test":"jest --runInBand","test:debug":"node --inspect-brk ./node_modules/jest/bin/jest.js --runInBand","tsc":"tsc","tsc:prod":"tsc -p tsconfig.release.json","lint":"eslint --cache src/**/*.ts --ignore-pattern .gitignore","lint:spec":"eslint --cache tests/**/*.ts --cache-file tests/.eslintcache --ignore-pattern .gitignore --fix"},"jest":{"preset":"react-native","moduleDirectories":["node_modules"],"unmockedModulePathPatterns":["node_modules"],"modulePathIgnorePatterns":["<rootDir>/src","<rootDir>/tests/commandTestTmp","node_modules/react-native/local-cli"],"transform":{"^.+\\.(ts|tsx)$":"ts-jest"},"testPathIgnorePatterns":["<rootDir>/src","<rootDir>/tests/commandTestTmp"],"transformIgnorePatterns":["node_modules/(?!(@react-native|react-native)/)"],"setupFiles":["<rootDir>/tests/setup/setup.js"],"testResultsProcessor":"jest-junit","testRegex":["(/__tests__/.*|(\\.|/)(Test|spec))\\.[jt]sx?$"]},"jest-junit":{"suiteName":"jest tests","outputDirectory":".","outputName":"junit.xml","uniqueOutputName":"true","ancestorSeparator":" › ","usePathForSuiteName":"true"},"author":"Dynatrace","license":"SEE LICENSE IN LICENSE.md","dependencies":{"@babel/runtime":"^7.23.2","jscodeshift":"^0.15.1","plist":"^3.1.0","proxy-polyfill":"^0.3.2","semver":"^7.5.4"},"homepage":"https://www.dynatrace.com/","peerDependencies":{"@babel/parser":">=7.4.4","@react-native-picker/picker":">=1.0.0","react":">=16.8.0","react-native":">=0.59.0"},"devDependencies":{"@babel/cli":"^7.22.9","@babel/plugin-proposal-class-properties":"^7.8.3","@babel/plugin-proposal-nullish-coalescing-operator":"^7.8.3","@babel/plugin-proposal-optional-chaining":"^7.8.3","@babel/plugin-transform-flow-strip-types":"^7.8.3","@babel/plugin-transform-runtime":"^7.12.1","@babel/preset-env":"^7.4.4","@babel/preset-react":"^7.8.3","@testing-library/react-native":"^7.0.2","@types/jest":"^26.0.19","@types/jscodeshift":"^0.11.6","@types/libxmljs":"^0.18.3","@types/node":"^18.17.12","@types/plist":"^3.0.2","@types/react-native":"^0.63.32","@types/semver":"^7.5.0","@types/shelljs":"^0.8.8","@types/uglify-js":"^3.17.1","@typescript-eslint/eslint-plugin":"^5.16.0","@typescript-eslint/parser":"^5.16.0","compressing":"^1.5.1","eslint":"^8.45.0","eslint-config-prettier":"^8.5.0","eslint-plugin-import":"^2.26.0","eslint-plugin-jsdoc":"^39.1.0","eslint-plugin-prefer-arrow":"^1.2.3","eslint-plugin-unicorn":"^42.0.0","jest":"24.9.0","jest-each":"^28.1.3","jest-junit":"^14.0.0","jest-mock":"^28.1.3","npm-check-updates":"^16.10.12","prettier":"^2.6.1","shelljs":"^0.8.5","ts-jest":"24.3.0","ts-mockito":"^2.6.1","typescript":"^4.7.4","uglify-js":"^3.17.4","react-native":"0.71.3","react":"18.2.0","react-test-renderer":"18.2.0"},"files":["command/command.js","command/util/*","command/interface/*","android/build.gradle","android/src/main/**/*","ios/**/*","files/*","lib/instrumentor/base/*.js","lib/instrumentor/base/model/*.js","lib/instrumentor/base/configuration/*.js","lib/instrumentor/base/configuration/interface/*.js","lib/instrumentor/base/interface/*.js","lib/instrumentor/base/util/*.js","lib/instrumentor/model/*.js","lib/instrumentor/parser/*.js","lib/instrumentor/DynatraceInstrumentation.js","lib/*.js","lib/community/*.js","lib/community/gesture-handler/*.js","lib/react-navigation/*.js","lib/react-native/*.js","lib/react/*.js","lib/metro/*.js","lib/util/*.js","react-native.config.js","react-native-dynatrace.js","react-native-dynatrace.podspec","README.md","LICENSE.md","scripts/*","scripts/api/*","scripts/core/*","scripts/api/model/*","scripts/util/*","typings/*","package.json","jsx-runtime.js"]}
package/scripts/Config.js CHANGED
@@ -27,6 +27,9 @@ exports.defaultConfig = {
27
27
  instrument: (filename) => true,
28
28
  actionNamePrivacy: false,
29
29
  },
30
+ custom: {
31
+ reactnavigation: false,
32
+ },
30
33
  },
31
34
  };
32
35
  const readConfig = (pathToConfig) => {
@@ -81,9 +81,9 @@ export declare const Dynatrace: {
81
81
  * in case of manual startup and will be ignored in auto startup scenarios. The start method will
82
82
  * set the error handler for reporting crashes and will apply the provided configuration globally.
83
83
  *
84
- * @param {ManualStartupConfiguration} configuration Configuration for a manual startup of the plugin
84
+ * @param {IConfiguration} configuration Configuration for a manual startup of the plugin
85
85
  */
86
- start(configuration: ManualStartupConfiguration): Promise<void>;
86
+ start(configuration: IConfiguration): Promise<void>;
87
87
 
88
88
  /**
89
89
  * This call allows to monitor the passed in component. Depending on the type of the component
@@ -545,10 +545,75 @@ export declare class UserPrivacyOptions {
545
545
  set crashReportingOptedIn(crashReportingOptedIn: boolean);
546
546
  }
547
547
 
548
+ /**
549
+ * Configuration interface which should be used during a manual startup
550
+ */
551
+ export declare interface IConfiguration {
552
+
553
+ /**
554
+ * Beacon url which is used for communicate with the beacon endpoint. This value is mandatory.
555
+ *
556
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
557
+ * native agent configuration.
558
+ */
559
+ readonly beaconUrl: string;
560
+
561
+ /**
562
+ * Needed to identify and report data for this application. This value is mandatory.
563
+ *
564
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
565
+ * native agent configuration.
566
+ */
567
+ readonly applicationId: string;
568
+
569
+ /**
570
+ * Enables reporting of crashes. By default this value is true if nothing is passed.
571
+ *
572
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
573
+ * native agent configuration.
574
+ */
575
+ readonly reportCrash: boolean;
576
+
577
+ /**
578
+ * Log level of our plugin during application runtime. By default this values is LogLevel.Info, if nothing is passed.
579
+ */
580
+ readonly logLevel: LogLevel;
581
+
582
+ /**
583
+ * Decide if you want to see update cycles on lifecycle actions as well.
584
+ * By default this value is false, if nothing is passed. Be aware as this creates a lot more data.
585
+ */
586
+ readonly lifecycleUpdate: boolean;
587
+
588
+ /**
589
+ * Activates the privacy mode when set to true. User consent must be queried and set.
590
+ * The privacy settings for data collection and crash reporting can be changed via OneAgent SDK
591
+ * for Mobile as described under Data privacy. By default this value is false, if nothing is passed.
592
+ *
593
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
594
+ * native agent configuration.
595
+ */
596
+ readonly userOptIn: boolean;
597
+
598
+ /**
599
+ * Activates a privacy mode especially for Touchables and Buttons. Setting this option to true
600
+ * means that a name for the control will no longer be shown, e.g. "Touch on Button".
601
+ * When setting a dtActionName onto the component this setting will be ignored. By default this value is false,
602
+ * if nothing is passed.
603
+ */
604
+ readonly actionNamePrivacy: boolean;
605
+
606
+ /**
607
+ * Will define the bundle name which will prefix internal action ids.
608
+ */
609
+ readonly bundleName?: string;
610
+ }
611
+
548
612
  /**
549
613
  * Manual startup configuration which is used for Dynatrace.start()
614
+ * @deprecated Use ConfigurationBuilder and IConfiguration instead
550
615
  */
551
- export declare class ManualStartupConfiguration {
616
+ export declare class ManualStartupConfiguration implements IConfiguration {
552
617
  /**
553
618
  * Creates a Manual Startup configuration instance
554
619
  *
@@ -560,8 +625,129 @@ export declare class ManualStartupConfiguration {
560
625
  * @param {boolean} userOptIn Activates the privacy mode when set to `true`. User consent must be queried and set.
561
626
  * @param {boolean} actionNamePrivacy Activates a privacy mode especially for Touchables and Buttons. Setting this option to true means that a name for the control will no longer be shown, e.g. "Touch on Button". When setting a dtActionName onto the component this setting will be ignored.
562
627
  * @param {string} bundleName Will define the bundle name which will prefix internal action ids.
628
+ *
629
+ * @deprecated Use ConfigurationBuilder and IConfiguration instead
563
630
  */
564
631
  constructor(beaconUrl: string, applicationId: string, reportCrash?: boolean,
565
632
  logLevel?: LogLevel, lifecycleUpdate?: boolean, userOptIn?: boolean,
566
633
  actionNamePrivacy?: boolean, bundleName?: string);
634
+
635
+ /**
636
+ * Beacon url which is used for communicate with the beacon endpoint. This value is mandatory.
637
+ *
638
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
639
+ * native agent configuration.
640
+ */
641
+ readonly beaconUrl: string;
642
+
643
+ /**
644
+ * Needed to identify and report data for this application. This value is mandatory.
645
+ *
646
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
647
+ * native agent configuration.
648
+ */
649
+ readonly applicationId: string;
650
+
651
+ /**
652
+ * Enables reporting of crashes. By default this value is true if nothing is passed.
653
+ *
654
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
655
+ * native agent configuration.
656
+ */
657
+ readonly reportCrash: boolean;
658
+
659
+ /**
660
+ * Log level of our plugin during application runtime. By default this values is LogLevel.Info, if nothing is passed.
661
+ */
662
+ readonly logLevel: LogLevel;
663
+
664
+ /**
665
+ * Decide if you want to see update cycles on lifecycle actions as well.
666
+ * By default this value is false, if nothing is passed. Be aware as this creates a lot more data.
667
+ */
668
+ readonly lifecycleUpdate: boolean;
669
+
670
+ /**
671
+ * Activates the privacy mode when set to true. User consent must be queried and set.
672
+ * The privacy settings for data collection and crash reporting can be changed via OneAgent SDK
673
+ * for Mobile as described under Data privacy. By default this value is false, if nothing is passed.
674
+ *
675
+ * Be aware this value is only important for manual startup. In case of auto startup this needs to be handled via
676
+ * native agent configuration.
677
+ */
678
+ readonly userOptIn: boolean;
679
+
680
+ /**
681
+ * Activates a privacy mode especially for Touchables and Buttons. Setting this option to true
682
+ * means that a name for the control will no longer be shown, e.g. "Touch on Button".
683
+ * When setting a dtActionName onto the component this setting will be ignored. By default this value is false,
684
+ * if nothing is passed.
685
+ */
686
+ readonly actionNamePrivacy: boolean;
687
+
688
+ /**
689
+ * Will define the bundle name which will prefix internal action ids.
690
+ */
691
+ readonly bundleName?: string;
692
+ }
693
+
694
+ /**
695
+ * Builder for Manual startup configuration which is used for Dynatrace.start()
696
+ */
697
+ export declare class ConfigurationBuilder {
698
+
699
+ /**
700
+ * Creates a builder for Manual Startup configuration
701
+ *
702
+ * @param {string} beaconUrl Identifies your environment within Dynatrace. This property is mandatory for manual startup
703
+ * @param {string} applicationId Identifies your mobile app. This property is mandatory for manual startup
704
+ */
705
+ constructor(beaconUrl: string, applicationId: string);
706
+
707
+ /**
708
+ * Builder function to handle crash reporting property
709
+ *
710
+ * @param {boolean} reportCrash Allows reporting React Native crashes.
711
+ */
712
+ public withCrashReporting(reportCrash: boolean): ConfigurationBuilder;
713
+
714
+ /**
715
+ * Builder function to handle loglevel property
716
+ *
717
+ * @param {LogLevel} logLevel Allows you to choose between `LogLevel.Info` and `LogLevel.Debug`. Debug returns more logs. This is especially important when something is not functioning correctly.
718
+ */
719
+ public withLogLevel(logLevel: LogLevel): ConfigurationBuilder;
720
+
721
+ /**
722
+ * Builder function to handle lifecycle update property
723
+ *
724
+ * @param {boolean} lifecycleUpdate Decide if you want to see update cycles on lifecycle actions as well. This is per default false as it creates a lot more actions.
725
+ */
726
+ public withLifecycleUpdate(lifecycleUpdate: boolean): ConfigurationBuilder
727
+
728
+ /**
729
+ * Builder function to handle user opt in property
730
+ *
731
+ * @param {boolean} userOptIn Activates the privacy mode when set to `true`. User consent must be queried and set.
732
+ */
733
+ public withUserOptIn(userOptIn: boolean): ConfigurationBuilder;
734
+
735
+ /**
736
+ * Builder function to handle action name privacy property
737
+ *
738
+ * @param {boolean} actionNamePrivacy Activates a privacy mode especially for Touchables and Buttons. Setting this option to true means that a name for the control will no longer be shown, e.g. "Touch on Button". When setting a dtActionName onto the component this setting will be ignored.
739
+ */
740
+ public withActionNamePrivacy(actionNamePrivacy: boolean): ConfigurationBuilder;
741
+
742
+ /**
743
+ * Builder function to handle bundle name property
744
+ *
745
+ * @param {string} bundleName Will define the bundle name which will prefix internal action ids.
746
+ */
747
+ public withBundleName(bundleName: string): ConfigurationBuilder;
748
+
749
+ /**
750
+ * Build configuration which is used for startup
751
+ */
752
+ public buildConfiguration(): IConfiguration;
567
753
  }
@@ -1,28 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.AutoStartupConfiguration = void 0;
4
- const ConfigurationDefaults_1 = require("./ConfigurationDefaults");
5
- class AutoStartupConfiguration {
6
- constructor(optionalAutoStartParameters) {
7
- this.lifecycleUpdate = ConfigurationDefaults_1.DEFAULT_LIFECYCLE_UPDATE_AUTO;
8
- this.logLevel = ConfigurationDefaults_1.DEFAULT_LOGLEVEL_AUTO;
9
- this.actionNamePrivacy = ConfigurationDefaults_1.DEFAULT_ACTION_NAME_PRIVACY;
10
- this.bundleName = ConfigurationDefaults_1.DEFAULT_BUNDLE_NAME_AUTO;
11
- if (optionalAutoStartParameters === undefined) {
12
- return;
13
- }
14
- if (optionalAutoStartParameters.lifecycleUpdate !== undefined) {
15
- this.lifecycleUpdate = optionalAutoStartParameters.lifecycleUpdate;
16
- }
17
- if (optionalAutoStartParameters.logLevel !== undefined) {
18
- this.logLevel = optionalAutoStartParameters.logLevel;
19
- }
20
- if (optionalAutoStartParameters.actionNamePrivacy !== undefined) {
21
- this.actionNamePrivacy = optionalAutoStartParameters.actionNamePrivacy;
22
- }
23
- if (optionalAutoStartParameters.bundleName !== undefined) {
24
- this.bundleName = optionalAutoStartParameters.bundleName;
25
- }
26
- }
27
- }
28
- exports.AutoStartupConfiguration = AutoStartupConfiguration;
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });