diff --git a/create-streamr-xcframework.pl b/create-streamr-xcframework.pl new file mode 100755 index 00000000..5348586a --- /dev/null +++ b/create-streamr-xcframework.pl @@ -0,0 +1,48 @@ +#!/usr/bin/perl + +use strict; +use warnings; +use File::Find; +use File::Path qw(make_path); +use File::Copy::Recursive qw(dircopy); +use Cwd; + +my $abs_path = getcwd; +my $root_build = "build/ios"; +my $build_include = "$abs_path/$root_build/include"; +my $build_lib = "$abs_path/$root_build/lib"; +my $dist_path = "$abs_path/dist/ios"; + +print "Please wait, building xcframework.\n"; + +`rm -rf $build_include`; +`rm -rf $build_lib`; +`rm -rf $dist_path`; + +make_path($build_include); +make_path($build_lib); + +# Copy streamr headers +dircopy("$abs_path/packages/streamr-proto-rpc/include", $build_include); +dircopy("$abs_path/packages/streamr-logger/include", $build_include); +dircopy("$abs_path/packages/streamr-json/include", $build_include); +dircopy("$abs_path/packages/streamr-eventemitter/include", $build_include); + +# Find all include and lib directories and process them +find(\&process_dir, "./build/vcpkg_installed/arm64-ios"); +dircopy("$abs_path/build/vcpkg_installed/arm64-ios/lib", $build_lib); +`libtool -static -o $build_lib/libstreamr.a $build_lib/*.a`; +`xcodebuild -create-xcframework -library $build_lib/libstreamr.a -headers $build_include -output $dist_path/streamr.xcframework`; +print "\nstreamr.xcframework was created in the directory: dist/ios.\n"; + +# Subroutine to process each directory +sub process_dir { + my $dir = $File::Find::name; + print "Current dir: $dir\n"; + if ($dir =~ m|^\./build/vcpkg_installed/arm64-ios/include$|) { + # Copy includes from vcpkg-packages (vcpkg/packages//include) + dircopy("$abs_path/$dir", $build_include); + print "cp $abs_path/$dir $build_include\n"; + } +} + diff --git a/install-prerequisities.sh b/install-prerequisities.sh index b95a0a71..d279b475 100644 --- a/install-prerequisities.sh +++ b/install-prerequisities.sh @@ -11,9 +11,9 @@ if [[ "$OSTYPE" == "darwin"* ]]; then #PROFILE_FILE=~/.zprofile PROFILE_FILE=./setenvs.sh - xcode-select --install + xcode-select --install || true brew install jq - brew uninstall llvm + brew uninstall llvm || true brew install llvm@17 brew install cmake brew install pkg-config @@ -95,7 +95,7 @@ echo $TEMP_PROFILE_CONTENTS touch $PROFILE_FILE # Remove old version of the block -sed -i '/# streamr-native-sdk added start/,/# streamr-native-sdk added end/d' $PROFILE_FILE +sed -i '/# streamr-native-sdk added start/,/# streamr-native-sdk added end/d' $PROFILE_FILE || true # Add new block to profile file echo -e "# streamr-native-sdk added start\n$TEMP_PROFILE_CONTENTS# streamr-native-sdk added end" >> $PROFILE_FILE diff --git a/install.sh b/install.sh index b0d21f86..84d0bdfb 100755 --- a/install.sh +++ b/install.sh @@ -25,6 +25,7 @@ while [[ "$#" -gt 0 ]]; do --prod) PROD_BUILD=true ;; --ios) TARGET_TRIPLET="arm64-ios"; CHAINLOAD_TOOLCHAIN_FILE="$(pwd)/overlaytriplets/arm64-ios.cmake"; PLATFORM="OS64" ;; --android) TARGET_TRIPLET="arm64-android"; CHAINLOAD_TOOLCHAIN_FILE="$(pwd)/overlaytriplets/arm64-android.cmake"; PLATFORM="android" ;; + --xcframework) CREATE_XCFRAMEWORK=true ;; *) echo "Unknown parameter passed: $1. Usage: ./install.sh [--prod] [--ios] [--android]"; exit 1 ;; esac shift @@ -72,3 +73,6 @@ else cd build && cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE .. && cmake --build . && cd .. fi +if [ "$CREATE_XCFRAMEWORK" = true ]; then + ./create-streamr-xcframework.pl +fi diff --git a/iostest.sh b/iostest.sh new file mode 100755 index 00000000..cf2d4ea8 --- /dev/null +++ b/iostest.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +rm -rf build/ios + +brew install chargepoint/xcparse/xcparse + +# Run tests +xcodebuild test -project test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj -scheme iOSUnitTesting -destination 'platform=macOS' -configuration Debug -resultBundlePath build/ios/TestResults.xcresult + +# Check if xcodebuild was successful +if [ $? -ne 0 ]; then + echo "xcodebuild failed to run tests" + exit 2 +fi + +# Process results +RESULT=$(xcrun xcresulttool get --format json --path build/ios/TestResults.xcresult) + +# Check if xcresulttool was successful +if [ $? -ne 0 ]; then + echo "Failed to process test results" + exit 3 +fi + +# Extract test status +TEST_STATUS=$(echo $RESULT | jq -r '.issues.testFailureSummaries | length') + +if [ "$TEST_STATUS" -eq "0" ]; then + echo "All tests passed" + EXIT_CODE=0 +else + echo "Some tests failed. Details:" + echo $RESULT | jq '.issues.testFailureSummaries' + EXIT_CODE=1 +fi + +xcparse logs build/ios/TestResults.xcresult build/ios/TestResults +find build/ios -name StandardOutputAndStandardError.txt -exec cat {} + + +exit $EXIT_CODE diff --git a/packages/streamr-eventemitter/test/unit/EventEmitterTest.cpp b/packages/streamr-eventemitter/test/unit/EventEmitterTest.cpp index 2d40ba6e..36d3d028 100644 --- a/packages/streamr-eventemitter/test/unit/EventEmitterTest.cpp +++ b/packages/streamr-eventemitter/test/unit/EventEmitterTest.cpp @@ -1,3 +1,5 @@ +#define GLOG_USE_GLOG_EXPORT + #include #include #include diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.pbxproj b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.pbxproj new file mode 100644 index 00000000..25c37576 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.pbxproj @@ -0,0 +1,635 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + 413E46C32C7867670030132D /* LocationShareApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46C22C7867670030132D /* LocationShareApp.swift */; }; + 413E46C52C7867670030132D /* LocationShareView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46C42C7867670030132D /* LocationShareView.swift */; }; + 413E46C72C78676A0030132D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 413E46C62C78676A0030132D /* Assets.xcassets */; }; + 413E46CA2C78676A0030132D /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 413E46C92C78676A0030132D /* Preview Assets.xcassets */; }; + 413E46D42C78676A0030132D /* LocationShareTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46D32C78676A0030132D /* LocationShareTests.swift */; }; + 413E46DE2C78676A0030132D /* LocationShareUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46DD2C78676A0030132D /* LocationShareUITests.swift */; }; + 413E46E02C78676A0030132D /* LocationShareUITestsLaunchTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46DF2C78676A0030132D /* LocationShareUITestsLaunchTests.swift */; }; + 413E46ED2C7875CE0030132D /* LocationShareViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46EC2C7875CD0030132D /* LocationShareViewModel.swift */; }; + 413E46EF2C78773C0030132D /* LocationManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46EE2C78773C0030132D /* LocationManager.swift */; }; + 413E46F22C7895900030132D /* StreamrProxyClient.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46F12C7895900030132D /* StreamrProxyClient.swift */; }; + 413E46F62C7898D40030132D /* PeerDescriptor.swift in Sources */ = {isa = PBXBuildFile; fileRef = 413E46F52C7898D40030132D /* PeerDescriptor.swift */; }; + 4176FEC02C7B9078004F8A48 /* ProxyClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4176FEBE2C7B9078004F8A48 /* ProxyClient.cpp */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 413E46D02C78676A0030132D /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 413E46B72C7867670030132D /* Project object */; + proxyType = 1; + remoteGlobalIDString = 413E46BE2C7867670030132D; + remoteInfo = LocationShare; + }; + 413E46DA2C78676A0030132D /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 413E46B72C7867670030132D /* Project object */; + proxyType = 1; + remoteGlobalIDString = 413E46BE2C7867670030132D; + remoteInfo = LocationShare; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 413E46BF2C7867670030132D /* LocationShare.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = LocationShare.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 413E46C22C7867670030132D /* LocationShareApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationShareApp.swift; sourceTree = ""; }; + 413E46C42C7867670030132D /* LocationShareView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationShareView.swift; sourceTree = ""; }; + 413E46C62C78676A0030132D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 413E46C92C78676A0030132D /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + 413E46CF2C78676A0030132D /* LocationShareTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = LocationShareTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 413E46D32C78676A0030132D /* LocationShareTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationShareTests.swift; sourceTree = ""; }; + 413E46D92C78676A0030132D /* LocationShareUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = LocationShareUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 413E46DD2C78676A0030132D /* LocationShareUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationShareUITests.swift; sourceTree = ""; }; + 413E46DF2C78676A0030132D /* LocationShareUITestsLaunchTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationShareUITestsLaunchTests.swift; sourceTree = ""; }; + 413E46EC2C7875CD0030132D /* LocationShareViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationShareViewModel.swift; sourceTree = ""; }; + 413E46EE2C78773C0030132D /* LocationManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationManager.swift; sourceTree = ""; }; + 413E46F02C787E820030132D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; + 413E46F12C7895900030132D /* StreamrProxyClient.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StreamrProxyClient.swift; sourceTree = ""; }; + 413E46F52C7898D40030132D /* PeerDescriptor.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PeerDescriptor.swift; sourceTree = ""; }; + 4176FEBD2C7B9077004F8A48 /* LocationShare-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "LocationShare-Bridging-Header.h"; sourceTree = ""; }; + 4176FEBE2C7B9078004F8A48 /* ProxyClient.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = ProxyClient.cpp; sourceTree = ""; }; + 4176FEBF2C7B9078004F8A48 /* ProxyClient.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = ProxyClient.hpp; sourceTree = ""; }; + 4176FEC12C7B9204004F8A48 /* Result.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = Result.hpp; sourceTree = ""; }; + 4176FEC22C7B92DA004F8A48 /* PeerDescriptor.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = PeerDescriptor.hpp; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 413E46BC2C7867670030132D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 413E46CC2C78676A0030132D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 413E46D62C78676A0030132D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 413E46B62C7867670030132D = { + isa = PBXGroup; + children = ( + 413E46C12C7867670030132D /* LocationShare */, + 413E46D22C78676A0030132D /* LocationShareTests */, + 413E46DC2C78676A0030132D /* LocationShareUITests */, + 413E46C02C7867670030132D /* Products */, + ); + sourceTree = ""; + }; + 413E46C02C7867670030132D /* Products */ = { + isa = PBXGroup; + children = ( + 413E46BF2C7867670030132D /* LocationShare.app */, + 413E46CF2C78676A0030132D /* LocationShareTests.xctest */, + 413E46D92C78676A0030132D /* LocationShareUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 413E46C12C7867670030132D /* LocationShare */ = { + isa = PBXGroup; + children = ( + 413E46F02C787E820030132D /* Info.plist */, + 413E46C22C7867670030132D /* LocationShareApp.swift */, + 413E46C42C7867670030132D /* LocationShareView.swift */, + 413E46C62C78676A0030132D /* Assets.xcassets */, + 413E46C82C78676A0030132D /* Preview Content */, + 413E46EC2C7875CD0030132D /* LocationShareViewModel.swift */, + 413E46EE2C78773C0030132D /* LocationManager.swift */, + 413E46F12C7895900030132D /* StreamrProxyClient.swift */, + 413E46F52C7898D40030132D /* PeerDescriptor.swift */, + 4176FEBE2C7B9078004F8A48 /* ProxyClient.cpp */, + 4176FEBF2C7B9078004F8A48 /* ProxyClient.hpp */, + 4176FEBD2C7B9077004F8A48 /* LocationShare-Bridging-Header.h */, + 4176FEC12C7B9204004F8A48 /* Result.hpp */, + 4176FEC22C7B92DA004F8A48 /* PeerDescriptor.hpp */, + ); + path = LocationShare; + sourceTree = ""; + }; + 413E46C82C78676A0030132D /* Preview Content */ = { + isa = PBXGroup; + children = ( + 413E46C92C78676A0030132D /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; + 413E46D22C78676A0030132D /* LocationShareTests */ = { + isa = PBXGroup; + children = ( + 413E46D32C78676A0030132D /* LocationShareTests.swift */, + ); + path = LocationShareTests; + sourceTree = ""; + }; + 413E46DC2C78676A0030132D /* LocationShareUITests */ = { + isa = PBXGroup; + children = ( + 413E46DD2C78676A0030132D /* LocationShareUITests.swift */, + 413E46DF2C78676A0030132D /* LocationShareUITestsLaunchTests.swift */, + ); + path = LocationShareUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 413E46BE2C7867670030132D /* LocationShare */ = { + isa = PBXNativeTarget; + buildConfigurationList = 413E46E32C78676A0030132D /* Build configuration list for PBXNativeTarget "LocationShare" */; + buildPhases = ( + 413E46BB2C7867670030132D /* Sources */, + 413E46BC2C7867670030132D /* Frameworks */, + 413E46BD2C7867670030132D /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = LocationShare; + productName = LocationShare; + productReference = 413E46BF2C7867670030132D /* LocationShare.app */; + productType = "com.apple.product-type.application"; + }; + 413E46CE2C78676A0030132D /* LocationShareTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 413E46E62C78676A0030132D /* Build configuration list for PBXNativeTarget "LocationShareTests" */; + buildPhases = ( + 413E46CB2C78676A0030132D /* Sources */, + 413E46CC2C78676A0030132D /* Frameworks */, + 413E46CD2C78676A0030132D /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 413E46D12C78676A0030132D /* PBXTargetDependency */, + ); + name = LocationShareTests; + productName = LocationShareTests; + productReference = 413E46CF2C78676A0030132D /* LocationShareTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 413E46D82C78676A0030132D /* LocationShareUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 413E46E92C78676A0030132D /* Build configuration list for PBXNativeTarget "LocationShareUITests" */; + buildPhases = ( + 413E46D52C78676A0030132D /* Sources */, + 413E46D62C78676A0030132D /* Frameworks */, + 413E46D72C78676A0030132D /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 413E46DB2C78676A0030132D /* PBXTargetDependency */, + ); + name = LocationShareUITests; + productName = LocationShareUITests; + productReference = 413E46D92C78676A0030132D /* LocationShareUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 413E46B72C7867670030132D /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1540; + LastUpgradeCheck = 1540; + TargetAttributes = { + 413E46BE2C7867670030132D = { + CreatedOnToolsVersion = 15.4; + LastSwiftMigration = 1540; + }; + 413E46CE2C78676A0030132D = { + CreatedOnToolsVersion = 15.4; + TestTargetID = 413E46BE2C7867670030132D; + }; + 413E46D82C78676A0030132D = { + CreatedOnToolsVersion = 15.4; + TestTargetID = 413E46BE2C7867670030132D; + }; + }; + }; + buildConfigurationList = 413E46BA2C7867670030132D /* Build configuration list for PBXProject "LocationShare" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 413E46B62C7867670030132D; + productRefGroup = 413E46C02C7867670030132D /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 413E46BE2C7867670030132D /* LocationShare */, + 413E46CE2C78676A0030132D /* LocationShareTests */, + 413E46D82C78676A0030132D /* LocationShareUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 413E46BD2C7867670030132D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 413E46CA2C78676A0030132D /* Preview Assets.xcassets in Resources */, + 413E46C72C78676A0030132D /* Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 413E46CD2C78676A0030132D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 413E46D72C78676A0030132D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 413E46BB2C7867670030132D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 413E46F62C7898D40030132D /* PeerDescriptor.swift in Sources */, + 413E46EF2C78773C0030132D /* LocationManager.swift in Sources */, + 413E46C52C7867670030132D /* LocationShareView.swift in Sources */, + 413E46F22C7895900030132D /* StreamrProxyClient.swift in Sources */, + 413E46ED2C7875CE0030132D /* LocationShareViewModel.swift in Sources */, + 4176FEC02C7B9078004F8A48 /* ProxyClient.cpp in Sources */, + 413E46C32C7867670030132D /* LocationShareApp.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 413E46CB2C78676A0030132D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 413E46D42C78676A0030132D /* LocationShareTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 413E46D52C78676A0030132D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 413E46DE2C78676A0030132D /* LocationShareUITests.swift in Sources */, + 413E46E02C78676A0030132D /* LocationShareUITestsLaunchTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 413E46D12C78676A0030132D /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 413E46BE2C7867670030132D /* LocationShare */; + targetProxy = 413E46D02C78676A0030132D /* PBXContainerItemProxy */; + }; + 413E46DB2C78676A0030132D /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 413E46BE2C7867670030132D /* LocationShare */; + targetProxy = 413E46DA2C78676A0030132D /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 413E46E12C78676A0030132D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; + SWIFT_OBJC_INTEROP_MODE = objcxx; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 413E46E22C78676A0030132D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OBJC_INTEROP_MODE = objcxx; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 413E46E42C78676A0030132D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"LocationShare/Preview Content\""; + DEVELOPMENT_TEAM = S933S46DZS; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = LocationShare/Info.plist; + INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "The app needs access to your location to provide location-based services."; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.LocationShare; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_OBJC_BRIDGING_HEADER = "LocationShare/LocationShare-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 413E46E52C78676A0030132D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"LocationShare/Preview Content\""; + DEVELOPMENT_TEAM = S933S46DZS; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = LocationShare/Info.plist; + INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "The app needs access to your location to provide location-based services."; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.LocationShare; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_OBJC_BRIDGING_HEADER = "LocationShare/LocationShare-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + 413E46E72C78676A0030132D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = S933S46DZS; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.LocationShareTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/LocationShare.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/LocationShare"; + }; + name = Debug; + }; + 413E46E82C78676A0030132D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = S933S46DZS; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.LocationShareTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/LocationShare.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/LocationShare"; + }; + name = Release; + }; + 413E46EA2C78676A0030132D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = S933S46DZS; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.LocationShareUITests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = LocationShare; + }; + name = Debug; + }; + 413E46EB2C78676A0030132D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = S933S46DZS; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.LocationShareUITests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = LocationShare; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 413E46BA2C7867670030132D /* Build configuration list for PBXProject "LocationShare" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 413E46E12C78676A0030132D /* Debug */, + 413E46E22C78676A0030132D /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 413E46E32C78676A0030132D /* Build configuration list for PBXNativeTarget "LocationShare" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 413E46E42C78676A0030132D /* Debug */, + 413E46E52C78676A0030132D /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 413E46E62C78676A0030132D /* Build configuration list for PBXNativeTarget "LocationShareTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 413E46E72C78676A0030132D /* Debug */, + 413E46E82C78676A0030132D /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 413E46E92C78676A0030132D /* Build configuration list for PBXNativeTarget "LocationShareUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 413E46EA2C78676A0030132D /* Debug */, + 413E46EB2C78676A0030132D /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 413E46B72C7867670030132D /* Project object */; +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..919434a6 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 00000000..49daff59 Binary files /dev/null and b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcshareddata/xcschemes/LocationShare.xcscheme b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcshareddata/xcschemes/LocationShare.xcscheme new file mode 100644 index 00000000..6cd4e489 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcshareddata/xcschemes/LocationShare.xcscheme @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist new file mode 100644 index 00000000..29d2c24a --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -0,0 +1,184 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 00000000..29fff48f --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,32 @@ + + + + + SchemeUserState + + LocationShare.xcscheme_^#shared#^_ + + orderHint + 0 + + + SuppressBuildableAutocreation + + 413E46BE2C7867670030132D + + primary + + + 413E46CE2C78676A0030132D + + primary + + + 413E46D82C78676A0030132D + + primary + + + + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/AccentColor.colorset/Contents.json b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/AccentColor.colorset/Contents.json new file mode 100644 index 00000000..eb878970 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/AccentColor.colorset/Contents.json @@ -0,0 +1,11 @@ +{ + "colors" : [ + { + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/AppIcon.appiconset/Contents.json b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..13613e3e --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/Contents.json b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Info.plist b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Info.plist new file mode 100644 index 00000000..0c67376e --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Info.plist @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationManager.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationManager.swift new file mode 100644 index 00000000..6b8594c7 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationManager.swift @@ -0,0 +1,31 @@ +// +// LocationManager.swift +// LocationShare +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import SwiftUI +import CoreLocation + +@Observable +class LocationManager { + + @MainActor var location: (latitude: Double, longitude: Double)? = nil + private let locationManager = CLLocationManager() + + func requestUserAuthorization() async throws { + locationManager.requestWhenInUseAuthorization() + } + + func startCurrentLocationUpdates() async throws { + for try await locationUpdate in CLLocationUpdate.liveUpdates() { + if let coodinate = locationUpdate.location?.coordinate { + await MainActor.run() { + print("Thread: startCurrentLocationUpdates: \(Thread.current)") + self.location = (coodinate.latitude, coodinate.longitude) + } + } + } + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShare-Bridging-Header.h b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShare-Bridging-Header.h new file mode 100644 index 00000000..12a3284b --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShare-Bridging-Header.h @@ -0,0 +1,5 @@ +// +// Use this file to import your target's public headers that you would like to expose to Swift. +// + +#include "ProxyClient.hpp" diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareApp.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareApp.swift new file mode 100644 index 00000000..73e9a89b --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareApp.swift @@ -0,0 +1,17 @@ +// +// LocationShareApp.swift +// LocationShare +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import SwiftUI + +@main +struct LocationShareApp: App { + var body: some Scene { + WindowGroup { + LocationShareView() + } + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareView.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareView.swift new file mode 100644 index 00000000..4759b046 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareView.swift @@ -0,0 +1,63 @@ +// +// ContentView.swift +// LocationShare +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import SwiftUI + +struct LocationShareView: View { + @State var viewModel = LocationShareViewModel() + + var body: some View { + ZStack { + List { + Section(header: Text("Proxy Information")) { + TextField( + "Enter proxy address", + text: $viewModel.proxyAddress + ) + TextField( + "Enter proxy ID", + text: $viewModel.proxyId + ) + Text(viewModel.status) + } + Section(header: Text("Publishing Interval")) { + TextField( + "Enter interval in seconds", + text: $viewModel.publishingIntervalInSeconds + ) + } + Section(header: Text("GPS Location")) { + Text("\(viewModel.latitude), \(viewModel.longitude)") + } + } + VStack { + Spacer() + Button { + viewModel.buttonClicked() + } label: { + Text(viewModel.buttonText) + .frame(maxWidth: .infinity) + }.buttonStyle(.borderedProminent) + .controlSize(.large) + .padding([.leading, .trailing, .top, .bottom]) + .disabled(viewModel.proxyAddress == "" || + viewModel.proxyId == "" || + viewModel.publishingIntervalInSeconds == "") + } + + } + .task { + await viewModel.initialize() + } + } +} + +/* +#Preview { + ContentView() +} +*/ diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareViewModel.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareViewModel.swift new file mode 100644 index 00000000..dc9197ce --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/LocationShareViewModel.swift @@ -0,0 +1,103 @@ +// +// LocationShareViewModel.swift +// LocationShare +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import Foundation + +struct LocationShareViewModel { + private var locationManager: LocationManager + var streamrProxyClient: StreamrProxyClient + + init() { + self.locationManager = LocationManager() + self.streamrProxyClient = StreamrProxyClient(locationManager: locationManager) + } + + @MainActor + var status: String { + "Status: \(streamrProxyClient.status)" + } + + @MainActor + var buttonText: String { + streamrProxyClient.status == .stopped ? "Start Sharing" : "Stop Sharing" + } + + @MainActor + var proxyAddress: String { + get { + streamrProxyClient.proxyInfo.peerAddress + } + set(newProxyAddress) { + streamrProxyClient.proxyInfo.peerAddress = newProxyAddress + } + } + + @MainActor + var proxyId: String { + get { + streamrProxyClient.proxyInfo.peerId + } + set(newProxyId) { + streamrProxyClient.proxyInfo.peerId = newProxyId + } + } + + @MainActor + var publishingIntervalInSeconds: String { + get { + print("Thread: publishingIntervalInSeconds: \(Thread.current)") + + return String(streamrProxyClient.publishingIntervalInSeconds) + } + set(newProxyId) { + streamrProxyClient.publishingIntervalInSeconds = + TimeInterval(newProxyId) ?? StreamrProxyClient.defaultPublishingIntervalInSeconds + } + } + + @MainActor + private var locationCoordinates: (latitude: String, longitude: String) { + guard let location = locationManager.location else { + return (latitude: "Unknown", longitude: "Unknown") + } + return (latitude: String(location.latitude), longitude: String(location.longitude)) + } + + @MainActor + var latitude: String { + locationCoordinates.latitude + } + + @MainActor + var longitude: String { + locationCoordinates.longitude + } + + @MainActor + func buttonClicked() { + switch(streamrProxyClient.status) { + case .stopped: + streamrProxyClient.startPublishing() + case .proxySet: + streamrProxyClient.startPublishing() + case .publishing: + streamrProxyClient.stopPublishing() + } + } + + func initialize() async { + try? await locationManager.requestUserAuthorization() + try? await locationManager.startCurrentLocationUpdates() + } + + func setProxyAndStartPublishing() { + streamrProxyClient.startPublishing() + } + + +} + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/PeerDescriptor.hpp b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/PeerDescriptor.hpp new file mode 100644 index 00000000..c1d7c0ca --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/PeerDescriptor.hpp @@ -0,0 +1,18 @@ +// +// PeerDescriptor.h +// LocationShare +// +// Created by Santtu Rantanen on 25.8.2024. +// + +#ifndef PeerDescriptor_hpp +#define PeerDescriptor_hpp + +#include + +struct PeerDescriptor { + std::string peerId; + std::string peerAddress; +}; + +#endif /* PeerDescriptor_hpp */ diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/PeerDescriptor.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/PeerDescriptor.swift new file mode 100644 index 00000000..3b6b4472 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/PeerDescriptor.swift @@ -0,0 +1,13 @@ +// +// PeerDescriptor.swift +// LocationShare +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import Foundation + +struct PeerDesc { + var peerId: String + var peerAddress: String +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Preview Content/Preview Assets.xcassets/Contents.json b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Preview Content/Preview Assets.xcassets/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Preview Content/Preview Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/ProxyClient.cpp b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/ProxyClient.cpp new file mode 100644 index 00000000..deb21ca8 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/ProxyClient.cpp @@ -0,0 +1,33 @@ +// +// ProxyClient.cpp +// LocationShare +// +// Created by Santtu Rantanen on 25.8.2024. +// + +#include "ProxyClient.hpp" +#include "PeerDescriptor.hpp" +#include +#include +#include + +using namespace std::chrono_literals; + +ProxyClientHandle ProxyClient::newClient() const { + return 1; +} + +Result ProxyClient::deleteClient(ProxyClientHandle proxyClientHandle) const { + return Result{Result::ResultCode::Ok, ""}; +} + +Result ProxyClient::publish(ProxyClientHandle proxyClientHandle, std::string data) const { + std::this_thread::sleep_for(1s); + return Result{Result::ResultCode::Ok, ""}; +} + +Result ProxyClient::setProxies(ProxyClientHandle proxyClientHandle, std::vector proxy) const { + std::this_thread::sleep_for(1s); + return Result{Result::ResultCode::Ok, ""}; +} + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/ProxyClient.hpp b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/ProxyClient.hpp new file mode 100644 index 00000000..40e30865 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/ProxyClient.hpp @@ -0,0 +1,25 @@ +// +// ProxyClient.hpp +// LocationShare +// +// Created by Santtu Rantanen on 25.8.2024. +// + +#ifndef ProxyClient_hpp +#define ProxyClient_hpp + +#include +#include "Result.hpp" +#include "PeerDescriptor.hpp" + +using ProxyClientHandle = int; + +class ProxyClient { +public: + ProxyClient() { } + ProxyClientHandle newClient() const; + Result deleteClient(ProxyClientHandle proxyClientHandle) const; + Result publish(ProxyClientHandle proxyClientHandle, std::string data) const; + Result setProxies(ProxyClientHandle proxyClientHandle, std::vector proxy) const; +}; +#endif /* ProxyClient_hpp */ diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Result.hpp b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Result.hpp new file mode 100644 index 00000000..3291a4f4 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/Result.hpp @@ -0,0 +1,19 @@ +// +// Result.h +// LocationShare +// +// Created by Santtu Rantanen on 25.8.2024. +// + +#ifndef Result_hpp +#define Result_hpp + +#include + +struct Result { + enum class ResultCode{ Ok, Error }; + ResultCode code; + std::string message; +}; + +#endif /* Result_h */ diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/StreamrProxyClient.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/StreamrProxyClient.swift new file mode 100644 index 00000000..630063c6 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShare/StreamrProxyClient.swift @@ -0,0 +1,97 @@ +// +// StreamrProxyClient.swift +// LocationShare +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import Foundation +import Combine + +@Observable +class StreamrProxyClient { + @MainActor var proxyInfo: PeerDesc = PeerDesc(peerId: "", peerAddress: "") + @MainActor var publishingIntervalInSeconds: TimeInterval = defaultPublishingIntervalInSeconds + var status: Status = .stopped + private let locationManager: LocationManager + private let proxyClient = ProxyClient() + static let defaultPublishingIntervalInSeconds: TimeInterval = 5 + @ObservationIgnored private var proxyClientHandle: ProxyClientHandle = 0 + @ObservationIgnored private var task: Task? + @ObservationIgnored private var timerSequence = Timer + .publish(every: 1, on: .main, in: .default) + .autoconnect() + .values + + enum Status { + case stopped + case proxySet + case publishing + } + + init(locationManager: LocationManager) { + self.locationManager = locationManager + proxyClientHandle = self.proxyClient.newClient() + } + + @MainActor + private func setProxy() async -> Result { + print("Set Proxy start") + let peerDescriptor = PeerDescriptor(peerId: std.string(proxyInfo.peerId), peerAddress: std.string(proxyInfo.peerAddress)) + let result = await Task.detached { + self.proxyClient.setProxies(self.proxyClientHandle, [peerDescriptor]) + }.value + print("Set Proxy end") + return result + } + + @MainActor + private func publish() async -> Result { + print("Publish start") + let latitude = locationManager.location?.latitude ?? 0 + let longitude = locationManager.location?.longitude ?? 0 + self.status = .publishing + let result = await Task.detached { + self.proxyClient.publish(self.proxyClientHandle, std.string("\(latitude) \(longitude)")) + }.value + print("Publish end") + return result + } + + func startPublishing() { + print("startPublishing start") + Task { @MainActor in + status = .proxySet + let result = await setProxy() + if result.code == Result.ResultCode.Error { + status = .stopped + return + } + timerSequence = Timer + .publish(every: publishingIntervalInSeconds, on: .main, in: .default) + .autoconnect() + .values + task = Task { + for await _ in timerSequence { + await publish() + if Task.isCancelled { return } + } + } + } + print("startPublishing end") + } + + func stopPublishing() { + print("stopPublishing start") + task?.cancel() + task = nil + Task { @MainActor in + status = .stopped + } + print("stopPublishing stop") + } + + +} + + diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareTests/LocationShareTests.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareTests/LocationShareTests.swift new file mode 100644 index 00000000..b3d78ced --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareTests/LocationShareTests.swift @@ -0,0 +1,36 @@ +// +// LocationShareTests.swift +// LocationShareTests +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import XCTest +@testable import LocationShare + +final class LocationShareTests: XCTestCase { + + override func setUpWithError() throws { + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDownWithError() throws { + // Put teardown code here. This method is called after the invocation of each test method in the class. + } + + func testExample() throws { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + // Any test you write for XCTest can be annotated as throws and async. + // Mark your test throws to produce an unexpected failure when your test encounters an uncaught error. + // Mark your test async to allow awaiting for asynchronous code to complete. Check the results with assertions afterwards. + } + + func testPerformanceExample() throws { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareUITests/LocationShareUITests.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareUITests/LocationShareUITests.swift new file mode 100644 index 00000000..adef20a5 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareUITests/LocationShareUITests.swift @@ -0,0 +1,41 @@ +// +// LocationShareUITests.swift +// LocationShareUITests +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import XCTest + +final class LocationShareUITests: XCTestCase { + + override func setUpWithError() throws { + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDownWithError() throws { + // Put teardown code here. This method is called after the invocation of each test method in the class. + } + + func testExample() throws { + // UI tests must launch the application that they test. + let app = XCUIApplication() + app.launch() + + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testLaunchPerformance() throws { + if #available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 7.0, *) { + // This measures how long it takes to launch your application. + measure(metrics: [XCTApplicationLaunchMetric()]) { + XCUIApplication().launch() + } + } + } +} diff --git a/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareUITests/LocationShareUITestsLaunchTests.swift b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareUITests/LocationShareUITestsLaunchTests.swift new file mode 100644 index 00000000..64991924 --- /dev/null +++ b/packages/streamr-libstreamrproxyclient/examples/ios/LocationShare/LocationShareUITests/LocationShareUITestsLaunchTests.swift @@ -0,0 +1,32 @@ +// +// LocationShareUITestsLaunchTests.swift +// LocationShareUITests +// +// Created by Santtu Rantanen on 23.8.2024. +// + +import XCTest + +final class LocationShareUITestsLaunchTests: XCTestCase { + + override class var runsForEachTargetApplicationUIConfiguration: Bool { + true + } + + override func setUpWithError() throws { + continueAfterFailure = false + } + + func testLaunch() throws { + let app = XCUIApplication() + app.launch() + + // Insert steps here to perform after app launch but before taking a screenshot, + // such as logging into a test account or navigating somewhere in the app + + let attachment = XCTAttachment(screenshot: app.screenshot()) + attachment.name = "Launch Screen" + attachment.lifetime = .keepAlways + add(attachment) + } +} diff --git a/packages/streamr-logger/test/unit/LoggerTest.cpp b/packages/streamr-logger/test/unit/LoggerTest.cpp index bacc77c3..987d87b4 100644 --- a/packages/streamr-logger/test/unit/LoggerTest.cpp +++ b/packages/streamr-logger/test/unit/LoggerTest.cpp @@ -1,3 +1,5 @@ +#define GLOG_USE_GLOG_EXPORT + #include "streamr-logger/Logger.hpp" #include #include diff --git a/packages/streamr-logger/test/unit/StreamrLogFormatterTest.cpp b/packages/streamr-logger/test/unit/StreamrLogFormatterTest.cpp index a3b724a2..41abcbd2 100644 --- a/packages/streamr-logger/test/unit/StreamrLogFormatterTest.cpp +++ b/packages/streamr-logger/test/unit/StreamrLogFormatterTest.cpp @@ -1,3 +1,5 @@ +#define GLOG_USE_GLOG_EXPORT + #include #include #include diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.pbxproj b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.pbxproj new file mode 100644 index 00000000..6dc8c29b --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.pbxproj @@ -0,0 +1,413 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + 417762BC2C7609FD000CA1B3 /* StreamrProtoRpcExampleAppApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 417762BB2C7609FD000CA1B3 /* StreamrProtoRpcExampleAppApp.swift */; }; + 417762BE2C7609FD000CA1B3 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 417762BD2C7609FD000CA1B3 /* ContentView.swift */; }; + 417762C02C7609FF000CA1B3 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 417762BF2C7609FF000CA1B3 /* Assets.xcassets */; }; + 417762C32C7609FF000CA1B3 /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 417762C22C7609FF000CA1B3 /* Preview Assets.xcassets */; }; + 417762CD2C7610EC000CA1B3 /* Wrapper.mm in Sources */ = {isa = PBXBuildFile; fileRef = 417762CC2C7610EC000CA1B3 /* Wrapper.mm */; }; + 417762D92C76182A000CA1B3 /* Hello.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 417762D72C76182A000CA1B3 /* Hello.cpp */; }; + 417762F32C764712000CA1B3 /* HelloRpc.pb.cc in Sources */ = {isa = PBXBuildFile; fileRef = 417762F22C764711000CA1B3 /* HelloRpc.pb.cc */; }; + 417762F52C7648D7000CA1B3 /* ProtoRpc.pb.cc in Sources */ = {isa = PBXBuildFile; fileRef = 417762F42C7648D7000CA1B3 /* ProtoRpc.pb.cc */; }; + 417762F72C765648000CA1B3 /* streamr.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 417762F62C765648000CA1B3 /* streamr.xcframework */; }; + 417762FA2C767117000CA1B3 /* libc++abi.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 417762F92C767117000CA1B3 /* libc++abi.tbd */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 417762B82C7609FD000CA1B3 /* StreamrProtoRpcExampleApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = StreamrProtoRpcExampleApp.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 417762BB2C7609FD000CA1B3 /* StreamrProtoRpcExampleAppApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StreamrProtoRpcExampleAppApp.swift; sourceTree = ""; }; + 417762BD2C7609FD000CA1B3 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; + 417762BF2C7609FF000CA1B3 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 417762C22C7609FF000CA1B3 /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + 417762CB2C7610EB000CA1B3 /* StreamrProtoRpcExampleApp-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "StreamrProtoRpcExampleApp-Bridging-Header.h"; sourceTree = ""; }; + 417762CC2C7610EC000CA1B3 /* Wrapper.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = Wrapper.mm; sourceTree = ""; }; + 417762CE2C761123000CA1B3 /* Wrapper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Wrapper.h; sourceTree = ""; }; + 417762D72C76182A000CA1B3 /* Hello.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = Hello.cpp; sourceTree = ""; }; + 417762D82C76182A000CA1B3 /* Hello.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = Hello.hpp; sourceTree = ""; }; + 417762EC2C763CC9000CA1B3 /* HelloRpc.client.pb.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HelloRpc.client.pb.h; sourceTree = ""; }; + 417762ED2C763D7B000CA1B3 /* HelloRpc.pb.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HelloRpc.pb.h; sourceTree = ""; }; + 417762F02C764569000CA1B3 /* ProtoRpc.pb.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ProtoRpc.pb.h; sourceTree = ""; }; + 417762F12C7645A0000CA1B3 /* HelloRpc.server.pb.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HelloRpc.server.pb.h; sourceTree = ""; }; + 417762F22C764711000CA1B3 /* HelloRpc.pb.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HelloRpc.pb.cc; sourceTree = ""; }; + 417762F42C7648D7000CA1B3 /* ProtoRpc.pb.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ProtoRpc.pb.cc; sourceTree = ""; }; + 417762F62C765648000CA1B3 /* streamr.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = streamr.xcframework; path = "../../../../../../dist/ios/streamr.xcframework"; sourceTree = ""; }; + 417762F92C767117000CA1B3 /* libc++abi.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++abi.tbd"; path = "usr/lib/libc++abi.tbd"; sourceTree = SDKROOT; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 417762B52C7609FD000CA1B3 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 417762FA2C767117000CA1B3 /* libc++abi.tbd in Frameworks */, + 417762F72C765648000CA1B3 /* streamr.xcframework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 417762AF2C7609FD000CA1B3 = { + isa = PBXGroup; + children = ( + 417762BA2C7609FD000CA1B3 /* StreamrProtoRpcExampleApp */, + 417762B92C7609FD000CA1B3 /* Products */, + 417762F82C767117000CA1B3 /* Frameworks */, + ); + sourceTree = ""; + }; + 417762B92C7609FD000CA1B3 /* Products */ = { + isa = PBXGroup; + children = ( + 417762B82C7609FD000CA1B3 /* StreamrProtoRpcExampleApp.app */, + ); + name = Products; + sourceTree = ""; + }; + 417762BA2C7609FD000CA1B3 /* StreamrProtoRpcExampleApp */ = { + isa = PBXGroup; + children = ( + 417762F62C765648000CA1B3 /* streamr.xcframework */, + 417762F22C764711000CA1B3 /* HelloRpc.pb.cc */, + 417762F42C7648D7000CA1B3 /* ProtoRpc.pb.cc */, + 417762F02C764569000CA1B3 /* ProtoRpc.pb.h */, + 417762EC2C763CC9000CA1B3 /* HelloRpc.client.pb.h */, + 417762F12C7645A0000CA1B3 /* HelloRpc.server.pb.h */, + 417762ED2C763D7B000CA1B3 /* HelloRpc.pb.h */, + 417762BB2C7609FD000CA1B3 /* StreamrProtoRpcExampleAppApp.swift */, + 417762BD2C7609FD000CA1B3 /* ContentView.swift */, + 417762BF2C7609FF000CA1B3 /* Assets.xcassets */, + 417762C12C7609FF000CA1B3 /* Preview Content */, + 417762CC2C7610EC000CA1B3 /* Wrapper.mm */, + 417762CB2C7610EB000CA1B3 /* StreamrProtoRpcExampleApp-Bridging-Header.h */, + 417762CE2C761123000CA1B3 /* Wrapper.h */, + 417762D72C76182A000CA1B3 /* Hello.cpp */, + 417762D82C76182A000CA1B3 /* Hello.hpp */, + ); + path = StreamrProtoRpcExampleApp; + sourceTree = ""; + }; + 417762C12C7609FF000CA1B3 /* Preview Content */ = { + isa = PBXGroup; + children = ( + 417762C22C7609FF000CA1B3 /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; + 417762F82C767117000CA1B3 /* Frameworks */ = { + isa = PBXGroup; + children = ( + 417762F92C767117000CA1B3 /* libc++abi.tbd */, + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 417762B72C7609FD000CA1B3 /* StreamrProtoRpcExampleApp */ = { + isa = PBXNativeTarget; + buildConfigurationList = 417762C62C7609FF000CA1B3 /* Build configuration list for PBXNativeTarget "StreamrProtoRpcExampleApp" */; + buildPhases = ( + 417762B42C7609FD000CA1B3 /* Sources */, + 417762B52C7609FD000CA1B3 /* Frameworks */, + 417762B62C7609FD000CA1B3 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = StreamrProtoRpcExampleApp; + productName = StreamrProtoRpcExampleApp; + productReference = 417762B82C7609FD000CA1B3 /* StreamrProtoRpcExampleApp.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 417762B02C7609FD000CA1B3 /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1540; + LastUpgradeCheck = 1540; + TargetAttributes = { + 417762B72C7609FD000CA1B3 = { + CreatedOnToolsVersion = 15.4; + LastSwiftMigration = 1540; + }; + }; + }; + buildConfigurationList = 417762B32C7609FD000CA1B3 /* Build configuration list for PBXProject "StreamrProtoRpcExampleApp" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 417762AF2C7609FD000CA1B3; + productRefGroup = 417762B92C7609FD000CA1B3 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 417762B72C7609FD000CA1B3 /* StreamrProtoRpcExampleApp */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 417762B62C7609FD000CA1B3 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 417762C32C7609FF000CA1B3 /* Preview Assets.xcassets in Resources */, + 417762C02C7609FF000CA1B3 /* Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 417762B42C7609FD000CA1B3 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 417762BE2C7609FD000CA1B3 /* ContentView.swift in Sources */, + 417762BC2C7609FD000CA1B3 /* StreamrProtoRpcExampleAppApp.swift in Sources */, + 417762F32C764712000CA1B3 /* HelloRpc.pb.cc in Sources */, + 417762F52C7648D7000CA1B3 /* ProtoRpc.pb.cc in Sources */, + 417762D92C76182A000CA1B3 /* Hello.cpp in Sources */, + 417762CD2C7610EC000CA1B3 /* Wrapper.mm in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + 417762C42C7609FF000CA1B3 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + OTHER_LDFLAGS = "\"-L c++abi\""; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; + SWIFT_OBJC_INTEROP_MODE = objcxx; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 417762C52C7609FF000CA1B3 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "\"-L c++abi\""; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OBJC_INTEROP_MODE = objcxx; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 417762C72C7609FF000CA1B3 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"StreamrProtoRpcExampleApp/Preview Content\""; + DEVELOPMENT_TEAM = S933S46DZS; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.StreamrProtoRpcExampleApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; + SUPPORTS_MACCATALYST = NO; + SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; + SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_OBJC_BRIDGING_HEADER = "StreamrProtoRpcExampleApp/StreamrProtoRpcExampleApp-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = 1; + }; + name = Debug; + }; + 417762C82C7609FF000CA1B3 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"StreamrProtoRpcExampleApp/Preview Content\""; + DEVELOPMENT_TEAM = S933S46DZS; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.StreamrProtoRpcExampleApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; + SUPPORTS_MACCATALYST = NO; + SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; + SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_OBJC_BRIDGING_HEADER = "StreamrProtoRpcExampleApp/StreamrProtoRpcExampleApp-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = 1; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 417762B32C7609FD000CA1B3 /* Build configuration list for PBXProject "StreamrProtoRpcExampleApp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 417762C42C7609FF000CA1B3 /* Debug */, + 417762C52C7609FF000CA1B3 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 417762C62C7609FF000CA1B3 /* Build configuration list for PBXNativeTarget "StreamrProtoRpcExampleApp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 417762C72C7609FF000CA1B3 /* Debug */, + 417762C82C7609FF000CA1B3 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 417762B02C7609FD000CA1B3 /* Project object */; +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..919434a6 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 00000000..3dc95311 Binary files /dev/null and b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 00000000..7067f053 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,14 @@ + + + + + SchemeUserState + + StreamrProtoRpcExampleApp.xcscheme_^#shared#^_ + + orderHint + 0 + + + + diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/AccentColor.colorset/Contents.json b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/AccentColor.colorset/Contents.json new file mode 100644 index 00000000..eb878970 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/AccentColor.colorset/Contents.json @@ -0,0 +1,11 @@ +{ + "colors" : [ + { + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/AppIcon.appiconset/Contents.json b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..13613e3e --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/Contents.json b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ContentView.swift b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ContentView.swift new file mode 100644 index 00000000..8eb49d1e --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ContentView.swift @@ -0,0 +1,20 @@ +// +// ContentView.swift +// StreamrProtoRpcExampleApp +// +// Created by Santtu Rantanen on 21.8.2024. +// + +import SwiftUI + +struct ContentView: View { + var body: some View { + VStack { + Image(systemName: "globe") + .imageScale(.large) + .foregroundStyle(.tint) + Text(Wrapper().greetingWrapper()) + } + .padding() + } +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Hello.cpp b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Hello.cpp new file mode 100644 index 00000000..44a18993 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Hello.cpp @@ -0,0 +1,75 @@ +// +// Hello.cpp +// StreamrProtoRpcExampleApp +// +// Created by Santtu Rantanen on 21.8.2024. +// +#define GLOG_USE_GLOG_EXPORT + +#include "Hello.hpp" +#include +#include +#include "HelloRpc.client.pb.h" +#include "HelloRpc.pb.h" +#include "HelloRpc.server.pb.h" +#include "streamr-proto-rpc/ProtoCallContext.hpp" +#include "streamr-proto-rpc/RpcCommunicator.hpp" + +using streamr::protorpc::HelloRpcService; +using streamr::protorpc::HelloRpcServiceClient; +using streamr::protorpc::ProtoCallContext; +using streamr::protorpc::RpcCommunicator; +using streamr::protorpc::RpcMessage; + +class HelloService : public HelloRpcService { +public: + HelloResponse sayHello( + const HelloRequest& request, + const ProtoCallContext& /* callContext */) override { + HelloResponse response; + response.set_greeting("Hello, " + request.myname()); + return response; + } +}; + +std::string sayHello() { + RpcCommunicator communicator1; + HelloService helloService; + + communicator1.registerRpcMethod( + "sayHello", + std::bind( // NOLINT(modernize-avoid-bind) + &HelloService::sayHello, + &helloService, + std::placeholders::_1, + std::placeholders::_2)); + + // Setup client + RpcCommunicator communicator2; + HelloRpcServiceClient helloClient(communicator2); + + // Simulate a network connection between the client and server + communicator1.setOutgoingMessageCallback( + [&communicator2]( + const RpcMessage& message, + const std::string& /* requestId */, + const ProtoCallContext& /* context */) -> void { + communicator2.handleIncomingMessage(message, ProtoCallContext()); + }); + + communicator2.setOutgoingMessageCallback( + [&communicator1]( + const RpcMessage& message, + const std::string& /* requestId */, + const ProtoCallContext& /* context */) -> void { + communicator1.handleIncomingMessage(message, ProtoCallContext()); + }); + + // Make the RPC call + + HelloRequest request; + request.set_myname("Alice"); + auto response = folly::coro::blockingWait( + helloClient.sayHello(request, ProtoCallContext())); + return response.greeting(); +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Hello.hpp b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Hello.hpp new file mode 100644 index 00000000..98cf27c4 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Hello.hpp @@ -0,0 +1,15 @@ +// +// Hello.hpp +// StreamrProtoRpcExampleApp +// +// Created by Santtu Rantanen on 21.8.2024. +// + +#ifndef Hello_hpp +#define Hello_hpp + +#include + +std::string sayHello(); + +#endif /* Hello_hpp */ diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.client.pb.h b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.client.pb.h new file mode 100644 index 00000000..222d435e --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.client.pb.h @@ -0,0 +1,26 @@ +// generated by the protocol buffer streamr pluging. DO NOT EDIT! +// generated from protobuf file "HelloRpc.proto" + +#ifndef STREAMR_PROTORPC_HELLORPC_CLIENT_PB_H +#define STREAMR_PROTORPC_HELLORPC_CLIENT_PB_H + +#include +#include "HelloRpc.pb.h" // NOLINT +#include "streamr-proto-rpc/ProtoCallContext.hpp" +#include "streamr-proto-rpc/RpcCommunicator.hpp" + + +namespace streamr::protorpc { +class HelloRpcServiceClient { +private: +RpcCommunicator& communicator; +public: + HelloRpcServiceClient(RpcCommunicator& communicator) : communicator(communicator) {} + folly::coro::Task sayHello(const HelloRequest& request, const ProtoCallContext& callContext) { + return communicator.request("sayHello", request, callContext); + } +}; // class HelloRpcServiceClient +}; // namespace streamr::protorpc + +#endif // STREAMR_PROTORPC_HELLORPC_CLIENT_PB_H + diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.pb.cc b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.pb.cc new file mode 100644 index 00000000..13ea014c --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.pb.cc @@ -0,0 +1,270 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: HelloRpc.proto + +#include "HelloRpc.pb.h" + +#include +#include "google/protobuf/io/coded_stream.h" +#include "google/protobuf/extension_set.h" +#include "google/protobuf/wire_format_lite.h" +#include "google/protobuf/descriptor.h" +#include "google/protobuf/generated_message_reflection.h" +#include "google/protobuf/reflection_ops.h" +#include "google/protobuf/wire_format.h" +// @@protoc_insertion_point(includes) + +// Must be included last. +#include "google/protobuf/port_def.inc" +PROTOBUF_PRAGMA_INIT_SEG +namespace _pb = ::google::protobuf; +namespace _pbi = ::google::protobuf::internal; + +inline constexpr HelloResponse::Impl_::Impl_( + ::_pbi::ConstantInitialized) noexcept + : greeting_( + &::google::protobuf::internal::fixed_address_empty_string, + ::_pbi::ConstantInitialized()), + _cached_size_{0} {} + +template +PROTOBUF_CONSTEXPR HelloResponse::HelloResponse(::_pbi::ConstantInitialized) + : _impl_(::_pbi::ConstantInitialized()) {} +struct HelloResponseDefaultTypeInternal { + PROTOBUF_CONSTEXPR HelloResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} + ~HelloResponseDefaultTypeInternal() {} + union { + HelloResponse _instance; + }; +}; + +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT + PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 HelloResponseDefaultTypeInternal _HelloResponse_default_instance_; + +inline constexpr HelloRequest::Impl_::Impl_( + ::_pbi::ConstantInitialized) noexcept + : myname_( + &::google::protobuf::internal::fixed_address_empty_string, + ::_pbi::ConstantInitialized()), + _cached_size_{0} {} + +template +PROTOBUF_CONSTEXPR HelloRequest::HelloRequest(::_pbi::ConstantInitialized) + : _impl_(::_pbi::ConstantInitialized()) {} +struct HelloRequestDefaultTypeInternal { + PROTOBUF_CONSTEXPR HelloRequestDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} + ~HelloRequestDefaultTypeInternal() {} + union { + HelloRequest _instance; + }; +}; + +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT + PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 HelloRequestDefaultTypeInternal _HelloRequest_default_instance_; +static ::_pb::Metadata file_level_metadata_HelloRpc_2eproto[2]; +static constexpr const ::_pb::EnumDescriptor** + file_level_enum_descriptors_HelloRpc_2eproto = nullptr; +static constexpr const ::_pb::ServiceDescriptor** + file_level_service_descriptors_HelloRpc_2eproto = nullptr; +const ::uint32_t TableStruct_HelloRpc_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE( + protodesc_cold) = { + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::HelloRequest, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + ~0u, // no _split_ + ~0u, // no sizeof(Split) + PROTOBUF_FIELD_OFFSET(::HelloRequest, _impl_.myname_), + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::HelloResponse, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + ~0u, // no _split_ + ~0u, // no sizeof(Split) + PROTOBUF_FIELD_OFFSET(::HelloResponse, _impl_.greeting_), +}; + +static const ::_pbi::MigrationSchema + schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { + {0, -1, -1, sizeof(::HelloRequest)}, + {9, -1, -1, sizeof(::HelloResponse)}, +}; + +static const ::_pb::Message* const file_default_instances[] = { + &::_HelloRequest_default_instance_._instance, + &::_HelloResponse_default_instance_._instance, +}; +const char descriptor_table_protodef_HelloRpc_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { + "\n\016HelloRpc.proto\"\036\n\014HelloRequest\022\016\n\006myNa" + "me\030\001 \001(\t\"!\n\rHelloResponse\022\020\n\010greeting\030\001 " + "\001(\t2<\n\017HelloRpcService\022)\n\010sayHello\022\r.Hel" + "loRequest\032\016.HelloResponseB\002H\002b\006proto3" +}; +static ::absl::once_flag descriptor_table_HelloRpc_2eproto_once; +const ::_pbi::DescriptorTable descriptor_table_HelloRpc_2eproto = { + false, + false, + 157, + descriptor_table_protodef_HelloRpc_2eproto, + "HelloRpc.proto", + &descriptor_table_HelloRpc_2eproto_once, + nullptr, + 0, + 2, + schemas, + file_default_instances, + TableStruct_HelloRpc_2eproto::offsets, + file_level_metadata_HelloRpc_2eproto, + file_level_enum_descriptors_HelloRpc_2eproto, + file_level_service_descriptors_HelloRpc_2eproto, +}; + +// This function exists to be marked as weak. +// It can significantly speed up compilation by breaking up LLVM's SCC +// in the .pb.cc translation units. Large translation units see a +// reduction of more than 35% of walltime for optimized builds. Without +// the weak attribute all the messages in the file, including all the +// vtables and everything they use become part of the same SCC through +// a cycle like: +// GetMetadata -> descriptor table -> default instances -> +// vtables -> GetMetadata +// By adding a weak function here we break the connection from the +// individual vtables back into the descriptor table. +PROTOBUF_ATTRIBUTE_WEAK const ::_pbi::DescriptorTable* descriptor_table_HelloRpc_2eproto_getter() { + return &descriptor_table_HelloRpc_2eproto; +} +// Force running AddDescriptors() at dynamic initialization time. +PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 +static ::_pbi::AddDescriptorsRunner dynamic_init_dummy_HelloRpc_2eproto(&descriptor_table_HelloRpc_2eproto); +// =================================================================== + +class HelloRequest::_Internal { + public: +}; + +HelloRequest::HelloRequest(::google::protobuf::Arena* arena) + : ::google::protobuf::Message(arena) { + SharedCtor(arena); + // @@protoc_insertion_point(arena_constructor:HelloRequest) +} +inline PROTOBUF_NDEBUG_INLINE HelloRequest::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, ::google::protobuf::Arena* arena, + const Impl_& from) + : myname_(arena, from.myname_), + _cached_size_{0} {} + +HelloRequest::HelloRequest( + ::google::protobuf::Arena* arena, + const HelloRequest& from) + : ::google::protobuf::Message(arena) { + HelloRequest* const _this = this; + (void)_this; + _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>( + from._internal_metadata_); + new (&_impl_) Impl_(internal_visibility(), arena, from._impl_); + + // @@protoc_insertion_point(copy_constructor:HelloRequest) +} +inline PROTOBUF_NDEBUG_INLINE HelloRequest::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena) + : myname_(arena), + _cached_size_{0} {} + +inline void HelloRequest::SharedCtor(::_pb::Arena* arena) { + new (&_impl_) Impl_(internal_visibility(), arena); +} +HelloRequest::~HelloRequest() { + // @@protoc_insertion_point(destructor:HelloRequest) + _internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>(); + SharedDtor(); +} +inline void HelloRequest::SharedDtor() { + ABSL_DCHECK(GetArena() == nullptr); + _impl_.myname_.Destroy(); + _impl_.~Impl_(); +} + +::_pbi::CachedSize* HelloRequest::AccessCachedSize() const { + return &_impl_._cached_size_; +} +void HelloRequest::InternalSwap(HelloRequest* PROTOBUF_RESTRICT other) { + using std::swap; + GetReflection()->Swap(this, other);} + +::google::protobuf::Metadata HelloRequest::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_HelloRpc_2eproto_getter, &descriptor_table_HelloRpc_2eproto_once, + file_level_metadata_HelloRpc_2eproto[0]); +} +// =================================================================== + +class HelloResponse::_Internal { + public: +}; + +HelloResponse::HelloResponse(::google::protobuf::Arena* arena) + : ::google::protobuf::Message(arena) { + SharedCtor(arena); + // @@protoc_insertion_point(arena_constructor:HelloResponse) +} +inline PROTOBUF_NDEBUG_INLINE HelloResponse::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, ::google::protobuf::Arena* arena, + const Impl_& from) + : greeting_(arena, from.greeting_), + _cached_size_{0} {} + +HelloResponse::HelloResponse( + ::google::protobuf::Arena* arena, + const HelloResponse& from) + : ::google::protobuf::Message(arena) { + HelloResponse* const _this = this; + (void)_this; + _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>( + from._internal_metadata_); + new (&_impl_) Impl_(internal_visibility(), arena, from._impl_); + + // @@protoc_insertion_point(copy_constructor:HelloResponse) +} +inline PROTOBUF_NDEBUG_INLINE HelloResponse::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena) + : greeting_(arena), + _cached_size_{0} {} + +inline void HelloResponse::SharedCtor(::_pb::Arena* arena) { + new (&_impl_) Impl_(internal_visibility(), arena); +} +HelloResponse::~HelloResponse() { + // @@protoc_insertion_point(destructor:HelloResponse) + _internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>(); + SharedDtor(); +} +inline void HelloResponse::SharedDtor() { + ABSL_DCHECK(GetArena() == nullptr); + _impl_.greeting_.Destroy(); + _impl_.~Impl_(); +} + +::_pbi::CachedSize* HelloResponse::AccessCachedSize() const { + return &_impl_._cached_size_; +} +void HelloResponse::InternalSwap(HelloResponse* PROTOBUF_RESTRICT other) { + using std::swap; + GetReflection()->Swap(this, other);} + +::google::protobuf::Metadata HelloResponse::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_HelloRpc_2eproto_getter, &descriptor_table_HelloRpc_2eproto_once, + file_level_metadata_HelloRpc_2eproto[1]); +} +// @@protoc_insertion_point(namespace_scope) +namespace google { +namespace protobuf { +} // namespace protobuf +} // namespace google +// @@protoc_insertion_point(global_scope) +#include "google/protobuf/port_undef.inc" diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.pb.h b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.pb.h new file mode 100644 index 00000000..894d25a3 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.pb.h @@ -0,0 +1,525 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: HelloRpc.proto +// Protobuf C++ Version: 4.25.1 + +#ifndef GOOGLE_PROTOBUF_INCLUDED_HelloRpc_2eproto_2epb_2eh +#define GOOGLE_PROTOBUF_INCLUDED_HelloRpc_2eproto_2epb_2eh + +#include +#include +#include +#include + +#include "google/protobuf/port_def.inc" +#if PROTOBUF_VERSION < 4025000 +#error "This file was generated by a newer version of protoc which is" +#error "incompatible with your Protocol Buffer headers. Please update" +#error "your headers." +#endif // PROTOBUF_VERSION + +#if 4025001 < PROTOBUF_MIN_PROTOC_VERSION +#error "This file was generated by an older version of protoc which is" +#error "incompatible with your Protocol Buffer headers. Please" +#error "regenerate this file with a newer version of protoc." +#endif // PROTOBUF_MIN_PROTOC_VERSION +#include "google/protobuf/port_undef.inc" +#include "google/protobuf/io/coded_stream.h" +#include "google/protobuf/arena.h" +#include "google/protobuf/arenastring.h" +#include "google/protobuf/generated_message_util.h" +#include "google/protobuf/metadata_lite.h" +#include "google/protobuf/generated_message_reflection.h" +#include "google/protobuf/message.h" +#include "google/protobuf/repeated_field.h" // IWYU pragma: export +#include "google/protobuf/extension_set.h" // IWYU pragma: export +#include "google/protobuf/unknown_field_set.h" +// @@protoc_insertion_point(includes) + +// Must be included last. +#include "google/protobuf/port_def.inc" + +#define PROTOBUF_INTERNAL_EXPORT_HelloRpc_2eproto + +namespace google { +namespace protobuf { +namespace internal { +class AnyMetadata; +} // namespace internal +} // namespace protobuf +} // namespace google + +// Internal implementation detail -- do not use these members. +struct TableStruct_HelloRpc_2eproto { + static const ::uint32_t offsets[]; +}; +extern const ::google::protobuf::internal::DescriptorTable + descriptor_table_HelloRpc_2eproto; +class HelloRequest; +struct HelloRequestDefaultTypeInternal; +extern HelloRequestDefaultTypeInternal _HelloRequest_default_instance_; +class HelloResponse; +struct HelloResponseDefaultTypeInternal; +extern HelloResponseDefaultTypeInternal _HelloResponse_default_instance_; +namespace google { +namespace protobuf { +} // namespace protobuf +} // namespace google + + +// =================================================================== + + +// ------------------------------------------------------------------- + +class HelloResponse final : + public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:HelloResponse) */ { + public: + inline HelloResponse() : HelloResponse(nullptr) {} + ~HelloResponse() override; + template + explicit PROTOBUF_CONSTEXPR HelloResponse(::google::protobuf::internal::ConstantInitialized); + + inline HelloResponse(const HelloResponse& from) + : HelloResponse(nullptr, from) {} + HelloResponse(HelloResponse&& from) noexcept + : HelloResponse() { + *this = ::std::move(from); + } + + inline HelloResponse& operator=(const HelloResponse& from) { + CopyFrom(from); + return *this; + } + inline HelloResponse& operator=(HelloResponse&& from) noexcept { + if (this == &from) return *this; + if (GetArena() == from.GetArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance); + } + inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.mutable_unknown_fields<::google::protobuf::UnknownFieldSet>(); + } + + static const ::google::protobuf::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::google::protobuf::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::google::protobuf::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const HelloResponse& default_instance() { + return *internal_default_instance(); + } + static inline const HelloResponse* internal_default_instance() { + return reinterpret_cast( + &_HelloResponse_default_instance_); + } + static constexpr int kIndexInFileMessages = + 1; + + friend void swap(HelloResponse& a, HelloResponse& b) { + a.Swap(&b); + } + inline void Swap(HelloResponse* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() != nullptr && + GetArena() == other->GetArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() == other->GetArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::google::protobuf::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(HelloResponse* other) { + if (other == this) return; + ABSL_DCHECK(GetArena() == other->GetArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + HelloResponse* New(::google::protobuf::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + int GetCachedSize() const { return _impl_._cached_size_.Get(); } + + private: + ::google::protobuf::internal::CachedSize* AccessCachedSize() const final; + void SharedCtor(::google::protobuf::Arena* arena); + void SharedDtor(); + void InternalSwap(HelloResponse* other); + + private: + friend class ::google::protobuf::internal::AnyMetadata; + static ::absl::string_view FullMessageName() { + return "HelloResponse"; + } + protected: + explicit HelloResponse(::google::protobuf::Arena* arena); + HelloResponse(::google::protobuf::Arena* arena, const HelloResponse& from); + public: + + ::google::protobuf::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int { + kGreetingFieldNumber = 1, + }; + // string greeting = 1; + void clear_greeting() ; + const std::string& greeting() const; + template + void set_greeting(Arg_&& arg, Args_... args); + std::string* mutable_greeting(); + PROTOBUF_NODISCARD std::string* release_greeting(); + void set_allocated_greeting(std::string* value); + + private: + const std::string& _internal_greeting() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_greeting( + const std::string& value); + std::string* _internal_mutable_greeting(); + + public: + // @@protoc_insertion_point(class_scope:HelloResponse) + private: + class _Internal; + + friend class ::google::protobuf::MessageLite; + friend class ::google::protobuf::Arena; + template + friend class ::google::protobuf::Arena::InternalHelper; + using InternalArenaConstructable_ = void; + using DestructorSkippable_ = void; + struct Impl_ { + + inline explicit constexpr Impl_( + ::google::protobuf::internal::ConstantInitialized) noexcept; + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena); + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena, const Impl_& from); + ::google::protobuf::internal::ArenaStringPtr greeting_; + mutable ::google::protobuf::internal::CachedSize _cached_size_; + PROTOBUF_TSAN_DECLARE_MEMBER + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_HelloRpc_2eproto; +};// ------------------------------------------------------------------- + +class HelloRequest final : + public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:HelloRequest) */ { + public: + inline HelloRequest() : HelloRequest(nullptr) {} + ~HelloRequest() override; + template + explicit PROTOBUF_CONSTEXPR HelloRequest(::google::protobuf::internal::ConstantInitialized); + + inline HelloRequest(const HelloRequest& from) + : HelloRequest(nullptr, from) {} + HelloRequest(HelloRequest&& from) noexcept + : HelloRequest() { + *this = ::std::move(from); + } + + inline HelloRequest& operator=(const HelloRequest& from) { + CopyFrom(from); + return *this; + } + inline HelloRequest& operator=(HelloRequest&& from) noexcept { + if (this == &from) return *this; + if (GetArena() == from.GetArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance); + } + inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.mutable_unknown_fields<::google::protobuf::UnknownFieldSet>(); + } + + static const ::google::protobuf::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::google::protobuf::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::google::protobuf::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const HelloRequest& default_instance() { + return *internal_default_instance(); + } + static inline const HelloRequest* internal_default_instance() { + return reinterpret_cast( + &_HelloRequest_default_instance_); + } + static constexpr int kIndexInFileMessages = + 0; + + friend void swap(HelloRequest& a, HelloRequest& b) { + a.Swap(&b); + } + inline void Swap(HelloRequest* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() != nullptr && + GetArena() == other->GetArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() == other->GetArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::google::protobuf::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(HelloRequest* other) { + if (other == this) return; + ABSL_DCHECK(GetArena() == other->GetArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + HelloRequest* New(::google::protobuf::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + int GetCachedSize() const { return _impl_._cached_size_.Get(); } + + private: + ::google::protobuf::internal::CachedSize* AccessCachedSize() const final; + void SharedCtor(::google::protobuf::Arena* arena); + void SharedDtor(); + void InternalSwap(HelloRequest* other); + + private: + friend class ::google::protobuf::internal::AnyMetadata; + static ::absl::string_view FullMessageName() { + return "HelloRequest"; + } + protected: + explicit HelloRequest(::google::protobuf::Arena* arena); + HelloRequest(::google::protobuf::Arena* arena, const HelloRequest& from); + public: + + ::google::protobuf::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int { + kMyNameFieldNumber = 1, + }; + // string myName = 1; + void clear_myname() ; + const std::string& myname() const; + template + void set_myname(Arg_&& arg, Args_... args); + std::string* mutable_myname(); + PROTOBUF_NODISCARD std::string* release_myname(); + void set_allocated_myname(std::string* value); + + private: + const std::string& _internal_myname() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_myname( + const std::string& value); + std::string* _internal_mutable_myname(); + + public: + // @@protoc_insertion_point(class_scope:HelloRequest) + private: + class _Internal; + + friend class ::google::protobuf::MessageLite; + friend class ::google::protobuf::Arena; + template + friend class ::google::protobuf::Arena::InternalHelper; + using InternalArenaConstructable_ = void; + using DestructorSkippable_ = void; + struct Impl_ { + + inline explicit constexpr Impl_( + ::google::protobuf::internal::ConstantInitialized) noexcept; + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena); + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena, const Impl_& from); + ::google::protobuf::internal::ArenaStringPtr myname_; + mutable ::google::protobuf::internal::CachedSize _cached_size_; + PROTOBUF_TSAN_DECLARE_MEMBER + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_HelloRpc_2eproto; +}; + +// =================================================================== + + + + +// =================================================================== + + +#ifdef __GNUC__ +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wstrict-aliasing" +#endif // __GNUC__ +// ------------------------------------------------------------------- + +// HelloRequest + +// string myName = 1; +inline void HelloRequest::clear_myname() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.myname_.ClearToEmpty(); +} +inline const std::string& HelloRequest::myname() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:HelloRequest.myName) + return _internal_myname(); +} +template +inline PROTOBUF_ALWAYS_INLINE void HelloRequest::set_myname(Arg_&& arg, + Args_... args) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + _impl_.myname_.Set(static_cast(arg), args..., GetArena()); + // @@protoc_insertion_point(field_set:HelloRequest.myName) +} +inline std::string* HelloRequest::mutable_myname() ABSL_ATTRIBUTE_LIFETIME_BOUND { + std::string* _s = _internal_mutable_myname(); + // @@protoc_insertion_point(field_mutable:HelloRequest.myName) + return _s; +} +inline const std::string& HelloRequest::_internal_myname() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.myname_.Get(); +} +inline void HelloRequest::_internal_set_myname(const std::string& value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + _impl_.myname_.Set(value, GetArena()); +} +inline std::string* HelloRequest::_internal_mutable_myname() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + return _impl_.myname_.Mutable( GetArena()); +} +inline std::string* HelloRequest::release_myname() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:HelloRequest.myName) + return _impl_.myname_.Release(); +} +inline void HelloRequest::set_allocated_myname(std::string* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.myname_.SetAllocated(value, GetArena()); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.myname_.IsDefault()) { + _impl_.myname_.Set("", GetArena()); + } + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:HelloRequest.myName) +} + +// ------------------------------------------------------------------- + +// HelloResponse + +// string greeting = 1; +inline void HelloResponse::clear_greeting() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.greeting_.ClearToEmpty(); +} +inline const std::string& HelloResponse::greeting() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:HelloResponse.greeting) + return _internal_greeting(); +} +template +inline PROTOBUF_ALWAYS_INLINE void HelloResponse::set_greeting(Arg_&& arg, + Args_... args) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + _impl_.greeting_.Set(static_cast(arg), args..., GetArena()); + // @@protoc_insertion_point(field_set:HelloResponse.greeting) +} +inline std::string* HelloResponse::mutable_greeting() ABSL_ATTRIBUTE_LIFETIME_BOUND { + std::string* _s = _internal_mutable_greeting(); + // @@protoc_insertion_point(field_mutable:HelloResponse.greeting) + return _s; +} +inline const std::string& HelloResponse::_internal_greeting() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.greeting_.Get(); +} +inline void HelloResponse::_internal_set_greeting(const std::string& value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + _impl_.greeting_.Set(value, GetArena()); +} +inline std::string* HelloResponse::_internal_mutable_greeting() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + return _impl_.greeting_.Mutable( GetArena()); +} +inline std::string* HelloResponse::release_greeting() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:HelloResponse.greeting) + return _impl_.greeting_.Release(); +} +inline void HelloResponse::set_allocated_greeting(std::string* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.greeting_.SetAllocated(value, GetArena()); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.greeting_.IsDefault()) { + _impl_.greeting_.Set("", GetArena()); + } + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:HelloResponse.greeting) +} + +#ifdef __GNUC__ +#pragma GCC diagnostic pop +#endif // __GNUC__ + +// @@protoc_insertion_point(namespace_scope) + + +// @@protoc_insertion_point(global_scope) + +#include "google/protobuf/port_undef.inc" + +#endif // GOOGLE_PROTOBUF_INCLUDED_HelloRpc_2eproto_2epb_2eh diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.server.pb.h b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.server.pb.h new file mode 100644 index 00000000..be6e45e0 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/HelloRpc.server.pb.h @@ -0,0 +1,19 @@ +// Generated by the protocol buffer streamr pluging. DO NOT EDIT! +// Generated from protobuf file "HelloRpc.proto" + +#ifndef STREAMR_PROTORPC_HELLORPC_SERVER_PB_H +#define STREAMR_PROTORPC_HELLORPC_SERVER_PB_H + +#include "HelloRpc.pb.h" // NOLINT +#include + +namespace streamr::protorpc { +class HelloRpcService { +public: + virtual ~HelloRpcService() = default; + virtual HelloResponse sayHello(const HelloRequest& request, const ProtoCallContext& callContext) = 0; +}; // class HelloRpcService +}; // namespace streamr::protorpc + +#endif // STREAMR_PROTORPC_HELLORPC_SERVER_PB_H + diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Preview Content/Preview Assets.xcassets/Contents.json b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Preview Content/Preview Assets.xcassets/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Preview Content/Preview Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ProtoRpc.pb.cc b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ProtoRpc.pb.cc new file mode 100644 index 00000000..ce6fc9ca --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ProtoRpc.pb.cc @@ -0,0 +1,430 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: ProtoRpc.proto + +#include "ProtoRpc.pb.h" + +#include +#include "google/protobuf/io/coded_stream.h" +#include "google/protobuf/extension_set.h" +#include "google/protobuf/wire_format_lite.h" +#include "google/protobuf/descriptor.h" +#include "google/protobuf/generated_message_reflection.h" +#include "google/protobuf/reflection_ops.h" +#include "google/protobuf/wire_format.h" +// @@protoc_insertion_point(includes) + +// Must be included last. +#include "google/protobuf/port_def.inc" +PROTOBUF_PRAGMA_INIT_SEG +namespace _pb = ::google::protobuf; +namespace _pbi = ::google::protobuf::internal; +namespace protorpc { + template +PROTOBUF_CONSTEXPR RpcMessage_HeaderEntry_DoNotUse::RpcMessage_HeaderEntry_DoNotUse(::_pbi::ConstantInitialized) {} +struct RpcMessage_HeaderEntry_DoNotUseDefaultTypeInternal { + PROTOBUF_CONSTEXPR RpcMessage_HeaderEntry_DoNotUseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} + ~RpcMessage_HeaderEntry_DoNotUseDefaultTypeInternal() {} + union { + RpcMessage_HeaderEntry_DoNotUse _instance; + }; +}; + +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT + PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 RpcMessage_HeaderEntry_DoNotUseDefaultTypeInternal _RpcMessage_HeaderEntry_DoNotUse_default_instance_; + +inline constexpr RpcMessage::Impl_::Impl_( + ::_pbi::ConstantInitialized) noexcept + : _cached_size_{0}, + header_{}, + requestid_( + &::google::protobuf::internal::fixed_address_empty_string, + ::_pbi::ConstantInitialized()), + errorclassname_( + &::google::protobuf::internal::fixed_address_empty_string, + ::_pbi::ConstantInitialized()), + errorcode_( + &::google::protobuf::internal::fixed_address_empty_string, + ::_pbi::ConstantInitialized()), + errormessage_( + &::google::protobuf::internal::fixed_address_empty_string, + ::_pbi::ConstantInitialized()), + body_{nullptr}, + errortype_{static_cast< ::protorpc::RpcErrorType >(0)} {} + +template +PROTOBUF_CONSTEXPR RpcMessage::RpcMessage(::_pbi::ConstantInitialized) + : _impl_(::_pbi::ConstantInitialized()) {} +struct RpcMessageDefaultTypeInternal { + PROTOBUF_CONSTEXPR RpcMessageDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} + ~RpcMessageDefaultTypeInternal() {} + union { + RpcMessage _instance; + }; +}; + +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT + PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 RpcMessageDefaultTypeInternal _RpcMessage_default_instance_; + +inline constexpr Mnfo2uhnf92hvqi2nviouq2hv9puhq::Impl_::Impl_( + ::_pbi::ConstantInitialized) noexcept + : _cached_size_{0}, + empty_{nullptr} {} + +template +PROTOBUF_CONSTEXPR Mnfo2uhnf92hvqi2nviouq2hv9puhq::Mnfo2uhnf92hvqi2nviouq2hv9puhq(::_pbi::ConstantInitialized) + : _impl_(::_pbi::ConstantInitialized()) {} +struct Mnfo2uhnf92hvqi2nviouq2hv9puhqDefaultTypeInternal { + PROTOBUF_CONSTEXPR Mnfo2uhnf92hvqi2nviouq2hv9puhqDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} + ~Mnfo2uhnf92hvqi2nviouq2hv9puhqDefaultTypeInternal() {} + union { + Mnfo2uhnf92hvqi2nviouq2hv9puhq _instance; + }; +}; + +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT + PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 Mnfo2uhnf92hvqi2nviouq2hv9puhqDefaultTypeInternal _Mnfo2uhnf92hvqi2nviouq2hv9puhq_default_instance_; +} // namespace protorpc +static ::_pb::Metadata file_level_metadata_ProtoRpc_2eproto[3]; +static const ::_pb::EnumDescriptor* file_level_enum_descriptors_ProtoRpc_2eproto[1]; +static constexpr const ::_pb::ServiceDescriptor** + file_level_service_descriptors_ProtoRpc_2eproto = nullptr; +const ::uint32_t TableStruct_ProtoRpc_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE( + protodesc_cold) = { + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage_HeaderEntry_DoNotUse, _has_bits_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage_HeaderEntry_DoNotUse, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + ~0u, // no _split_ + ~0u, // no sizeof(Split) + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage_HeaderEntry_DoNotUse, key_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage_HeaderEntry_DoNotUse, value_), + 0, + 1, + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_._has_bits_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + ~0u, // no _split_ + ~0u, // no sizeof(Split) + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.header_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.body_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.requestid_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.errortype_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.errorclassname_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.errorcode_), + PROTOBUF_FIELD_OFFSET(::protorpc::RpcMessage, _impl_.errormessage_), + ~0u, + 3, + ~0u, + 4, + 0, + 1, + 2, + PROTOBUF_FIELD_OFFSET(::protorpc::Mnfo2uhnf92hvqi2nviouq2hv9puhq, _impl_._has_bits_), + PROTOBUF_FIELD_OFFSET(::protorpc::Mnfo2uhnf92hvqi2nviouq2hv9puhq, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + ~0u, // no _split_ + ~0u, // no sizeof(Split) + PROTOBUF_FIELD_OFFSET(::protorpc::Mnfo2uhnf92hvqi2nviouq2hv9puhq, _impl_.empty_), + 0, +}; + +static const ::_pbi::MigrationSchema + schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { + {0, 10, -1, sizeof(::protorpc::RpcMessage_HeaderEntry_DoNotUse)}, + {12, 27, -1, sizeof(::protorpc::RpcMessage)}, + {34, 43, -1, sizeof(::protorpc::Mnfo2uhnf92hvqi2nviouq2hv9puhq)}, +}; + +static const ::_pb::Message* const file_default_instances[] = { + &::protorpc::_RpcMessage_HeaderEntry_DoNotUse_default_instance_._instance, + &::protorpc::_RpcMessage_default_instance_._instance, + &::protorpc::_Mnfo2uhnf92hvqi2nviouq2hv9puhq_default_instance_._instance, +}; +const char descriptor_table_protodef_ProtoRpc_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { + "\n\016ProtoRpc.proto\022\010protorpc\032\033google/proto" + "buf/empty.proto\032\031google/protobuf/any.pro" + "to\"\344\002\n\nRpcMessage\0220\n\006header\030\001 \003(\0132 .prot" + "orpc.RpcMessage.HeaderEntry\022\"\n\004body\030\002 \001(" + "\0132\024.google.protobuf.Any\022\021\n\trequestId\030\003 \001" + "(\t\022.\n\terrorType\030\004 \001(\0162\026.protorpc.RpcErro" + "rTypeH\000\210\001\001\022\033\n\016errorClassName\030\005 \001(\tH\001\210\001\001\022" + "\026\n\terrorCode\030\006 \001(\tH\002\210\001\001\022\031\n\014errorMessage\030" + "\007 \001(\tH\003\210\001\001\032-\n\013HeaderEntry\022\013\n\003key\030\001 \001(\t\022\r" + "\n\005value\030\002 \001(\t:\0028\001B\014\n\n_errorTypeB\021\n\017_erro" + "rClassNameB\014\n\n_errorCodeB\017\n\r_errorMessag" + "e\"G\n\036Mnfo2uhnf92hvqi2nviouq2hv9puhq\022%\n\005e" + "mpty\030\001 \001(\0132\026.google.protobuf.Empty*r\n\014Rp" + "cErrorType\022\022\n\016SERVER_TIMEOUT\020\000\022\022\n\016CLIENT" + "_TIMEOUT\020\001\022\026\n\022UNKNOWN_RPC_METHOD\020\002\022\020\n\014CL" + "IENT_ERROR\020\003\022\020\n\014SERVER_ERROR\020\004B\002H\002b\006prot" + "o3" +}; +static const ::_pbi::DescriptorTable* const descriptor_table_ProtoRpc_2eproto_deps[2] = + { + &::descriptor_table_google_2fprotobuf_2fany_2eproto, + &::descriptor_table_google_2fprotobuf_2fempty_2eproto, +}; +static ::absl::once_flag descriptor_table_ProtoRpc_2eproto_once; +const ::_pbi::DescriptorTable descriptor_table_ProtoRpc_2eproto = { + false, + false, + 642, + descriptor_table_protodef_ProtoRpc_2eproto, + "ProtoRpc.proto", + &descriptor_table_ProtoRpc_2eproto_once, + descriptor_table_ProtoRpc_2eproto_deps, + 2, + 3, + schemas, + file_default_instances, + TableStruct_ProtoRpc_2eproto::offsets, + file_level_metadata_ProtoRpc_2eproto, + file_level_enum_descriptors_ProtoRpc_2eproto, + file_level_service_descriptors_ProtoRpc_2eproto, +}; + +// This function exists to be marked as weak. +// It can significantly speed up compilation by breaking up LLVM's SCC +// in the .pb.cc translation units. Large translation units see a +// reduction of more than 35% of walltime for optimized builds. Without +// the weak attribute all the messages in the file, including all the +// vtables and everything they use become part of the same SCC through +// a cycle like: +// GetMetadata -> descriptor table -> default instances -> +// vtables -> GetMetadata +// By adding a weak function here we break the connection from the +// individual vtables back into the descriptor table. +PROTOBUF_ATTRIBUTE_WEAK const ::_pbi::DescriptorTable* descriptor_table_ProtoRpc_2eproto_getter() { + return &descriptor_table_ProtoRpc_2eproto; +} +// Force running AddDescriptors() at dynamic initialization time. +PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 +static ::_pbi::AddDescriptorsRunner dynamic_init_dummy_ProtoRpc_2eproto(&descriptor_table_ProtoRpc_2eproto); +namespace protorpc { +const ::google::protobuf::EnumDescriptor* RpcErrorType_descriptor() { + ::google::protobuf::internal::AssignDescriptors(&descriptor_table_ProtoRpc_2eproto); + return file_level_enum_descriptors_ProtoRpc_2eproto[0]; +} +PROTOBUF_CONSTINIT const uint32_t RpcErrorType_internal_data_[] = { + 327680u, 0u, }; +bool RpcErrorType_IsValid(int value) { + return 0 <= value && value <= 4; +} +// =================================================================== + +RpcMessage_HeaderEntry_DoNotUse::RpcMessage_HeaderEntry_DoNotUse() {} +RpcMessage_HeaderEntry_DoNotUse::RpcMessage_HeaderEntry_DoNotUse(::google::protobuf::Arena* arena) + : SuperType(arena) {} +::google::protobuf::Metadata RpcMessage_HeaderEntry_DoNotUse::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_ProtoRpc_2eproto_getter, &descriptor_table_ProtoRpc_2eproto_once, + file_level_metadata_ProtoRpc_2eproto[0]); +} +// =================================================================== + +class RpcMessage::_Internal { + public: + using HasBits = decltype(std::declval()._impl_._has_bits_); + static constexpr ::int32_t kHasBitsOffset = + 8 * PROTOBUF_FIELD_OFFSET(RpcMessage, _impl_._has_bits_); + static const ::google::protobuf::Any& body(const RpcMessage* msg); + static void set_has_body(HasBits* has_bits) { + (*has_bits)[0] |= 8u; + } + static void set_has_errortype(HasBits* has_bits) { + (*has_bits)[0] |= 16u; + } + static void set_has_errorclassname(HasBits* has_bits) { + (*has_bits)[0] |= 1u; + } + static void set_has_errorcode(HasBits* has_bits) { + (*has_bits)[0] |= 2u; + } + static void set_has_errormessage(HasBits* has_bits) { + (*has_bits)[0] |= 4u; + } +}; + +const ::google::protobuf::Any& RpcMessage::_Internal::body(const RpcMessage* msg) { + return *msg->_impl_.body_; +} +void RpcMessage::clear_body() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (_impl_.body_ != nullptr) _impl_.body_->Clear(); + _impl_._has_bits_[0] &= ~0x00000008u; +} +RpcMessage::RpcMessage(::google::protobuf::Arena* arena) + : ::google::protobuf::Message(arena) { + SharedCtor(arena); + // @@protoc_insertion_point(arena_constructor:protorpc.RpcMessage) +} +inline PROTOBUF_NDEBUG_INLINE RpcMessage::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, ::google::protobuf::Arena* arena, + const Impl_& from) + : _has_bits_{from._has_bits_}, + _cached_size_{0}, + header_{visibility, arena, from.header_}, + requestid_(arena, from.requestid_), + errorclassname_(arena, from.errorclassname_), + errorcode_(arena, from.errorcode_), + errormessage_(arena, from.errormessage_) {} + +RpcMessage::RpcMessage( + ::google::protobuf::Arena* arena, + const RpcMessage& from) + : ::google::protobuf::Message(arena) { + RpcMessage* const _this = this; + (void)_this; + _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>( + from._internal_metadata_); + new (&_impl_) Impl_(internal_visibility(), arena, from._impl_); + ::uint32_t cached_has_bits = _impl_._has_bits_[0]; + _impl_.body_ = (cached_has_bits & 0x00000008u) + ? CreateMaybeMessage<::google::protobuf::Any>(arena, *from._impl_.body_) + : nullptr; + _impl_.errortype_ = from._impl_.errortype_; + + // @@protoc_insertion_point(copy_constructor:protorpc.RpcMessage) +} +inline PROTOBUF_NDEBUG_INLINE RpcMessage::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena) + : _cached_size_{0}, + header_{visibility, arena}, + requestid_(arena), + errorclassname_(arena), + errorcode_(arena), + errormessage_(arena) {} + +inline void RpcMessage::SharedCtor(::_pb::Arena* arena) { + new (&_impl_) Impl_(internal_visibility(), arena); + ::memset(reinterpret_cast(&_impl_) + + offsetof(Impl_, body_), + 0, + offsetof(Impl_, errortype_) - + offsetof(Impl_, body_) + + sizeof(Impl_::errortype_)); +} +RpcMessage::~RpcMessage() { + // @@protoc_insertion_point(destructor:protorpc.RpcMessage) + _internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>(); + SharedDtor(); +} +inline void RpcMessage::SharedDtor() { + ABSL_DCHECK(GetArena() == nullptr); + _impl_.requestid_.Destroy(); + _impl_.errorclassname_.Destroy(); + _impl_.errorcode_.Destroy(); + _impl_.errormessage_.Destroy(); + delete _impl_.body_; + _impl_.~Impl_(); +} + +::_pbi::CachedSize* RpcMessage::AccessCachedSize() const { + return &_impl_._cached_size_; +} +void RpcMessage::InternalSwap(RpcMessage* PROTOBUF_RESTRICT other) { + using std::swap; + GetReflection()->Swap(this, other);} + +::google::protobuf::Metadata RpcMessage::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_ProtoRpc_2eproto_getter, &descriptor_table_ProtoRpc_2eproto_once, + file_level_metadata_ProtoRpc_2eproto[1]); +} +// =================================================================== + +class Mnfo2uhnf92hvqi2nviouq2hv9puhq::_Internal { + public: + using HasBits = decltype(std::declval()._impl_._has_bits_); + static constexpr ::int32_t kHasBitsOffset = + 8 * PROTOBUF_FIELD_OFFSET(Mnfo2uhnf92hvqi2nviouq2hv9puhq, _impl_._has_bits_); + static const ::google::protobuf::Empty& empty(const Mnfo2uhnf92hvqi2nviouq2hv9puhq* msg); + static void set_has_empty(HasBits* has_bits) { + (*has_bits)[0] |= 1u; + } +}; + +const ::google::protobuf::Empty& Mnfo2uhnf92hvqi2nviouq2hv9puhq::_Internal::empty(const Mnfo2uhnf92hvqi2nviouq2hv9puhq* msg) { + return *msg->_impl_.empty_; +} +void Mnfo2uhnf92hvqi2nviouq2hv9puhq::clear_empty() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (_impl_.empty_ != nullptr) _impl_.empty_->Clear(); + _impl_._has_bits_[0] &= ~0x00000001u; +} +Mnfo2uhnf92hvqi2nviouq2hv9puhq::Mnfo2uhnf92hvqi2nviouq2hv9puhq(::google::protobuf::Arena* arena) + : ::google::protobuf::Message(arena) { + SharedCtor(arena); + // @@protoc_insertion_point(arena_constructor:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq) +} +inline PROTOBUF_NDEBUG_INLINE Mnfo2uhnf92hvqi2nviouq2hv9puhq::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, ::google::protobuf::Arena* arena, + const Impl_& from) + : _has_bits_{from._has_bits_}, + _cached_size_{0} {} + +Mnfo2uhnf92hvqi2nviouq2hv9puhq::Mnfo2uhnf92hvqi2nviouq2hv9puhq( + ::google::protobuf::Arena* arena, + const Mnfo2uhnf92hvqi2nviouq2hv9puhq& from) + : ::google::protobuf::Message(arena) { + Mnfo2uhnf92hvqi2nviouq2hv9puhq* const _this = this; + (void)_this; + _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>( + from._internal_metadata_); + new (&_impl_) Impl_(internal_visibility(), arena, from._impl_); + ::uint32_t cached_has_bits = _impl_._has_bits_[0]; + _impl_.empty_ = (cached_has_bits & 0x00000001u) + ? CreateMaybeMessage<::google::protobuf::Empty>(arena, *from._impl_.empty_) + : nullptr; + + // @@protoc_insertion_point(copy_constructor:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq) +} +inline PROTOBUF_NDEBUG_INLINE Mnfo2uhnf92hvqi2nviouq2hv9puhq::Impl_::Impl_( + ::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena) + : _cached_size_{0} {} + +inline void Mnfo2uhnf92hvqi2nviouq2hv9puhq::SharedCtor(::_pb::Arena* arena) { + new (&_impl_) Impl_(internal_visibility(), arena); + _impl_.empty_ = {}; +} +Mnfo2uhnf92hvqi2nviouq2hv9puhq::~Mnfo2uhnf92hvqi2nviouq2hv9puhq() { + // @@protoc_insertion_point(destructor:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq) + _internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>(); + SharedDtor(); +} +inline void Mnfo2uhnf92hvqi2nviouq2hv9puhq::SharedDtor() { + ABSL_DCHECK(GetArena() == nullptr); + delete _impl_.empty_; + _impl_.~Impl_(); +} + +::_pbi::CachedSize* Mnfo2uhnf92hvqi2nviouq2hv9puhq::AccessCachedSize() const { + return &_impl_._cached_size_; +} +void Mnfo2uhnf92hvqi2nviouq2hv9puhq::InternalSwap(Mnfo2uhnf92hvqi2nviouq2hv9puhq* PROTOBUF_RESTRICT other) { + using std::swap; + GetReflection()->Swap(this, other);} + +::google::protobuf::Metadata Mnfo2uhnf92hvqi2nviouq2hv9puhq::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_ProtoRpc_2eproto_getter, &descriptor_table_ProtoRpc_2eproto_once, + file_level_metadata_ProtoRpc_2eproto[2]); +} +// @@protoc_insertion_point(namespace_scope) +} // namespace protorpc +namespace google { +namespace protobuf { +} // namespace protobuf +} // namespace google +// @@protoc_insertion_point(global_scope) +#include "google/protobuf/port_undef.inc" diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ProtoRpc.pb.h b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ProtoRpc.pb.h new file mode 100644 index 00000000..29b981ba --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/ProtoRpc.pb.h @@ -0,0 +1,1126 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: ProtoRpc.proto +// Protobuf C++ Version: 4.25.1 + +#ifndef GOOGLE_PROTOBUF_INCLUDED_ProtoRpc_2eproto_2epb_2eh +#define GOOGLE_PROTOBUF_INCLUDED_ProtoRpc_2eproto_2epb_2eh + +#include +#include +#include +#include + +#include "google/protobuf/port_def.inc" +#if PROTOBUF_VERSION < 4025000 +#error "This file was generated by a newer version of protoc which is" +#error "incompatible with your Protocol Buffer headers. Please update" +#error "your headers." +#endif // PROTOBUF_VERSION + +#if 4025001 < PROTOBUF_MIN_PROTOC_VERSION +#error "This file was generated by an older version of protoc which is" +#error "incompatible with your Protocol Buffer headers. Please" +#error "regenerate this file with a newer version of protoc." +#endif // PROTOBUF_MIN_PROTOC_VERSION +#include "google/protobuf/port_undef.inc" +#include "google/protobuf/io/coded_stream.h" +#include "google/protobuf/arena.h" +#include "google/protobuf/arenastring.h" +#include "google/protobuf/generated_message_util.h" +#include "google/protobuf/metadata_lite.h" +#include "google/protobuf/generated_message_reflection.h" +#include "google/protobuf/message.h" +#include "google/protobuf/repeated_field.h" // IWYU pragma: export +#include "google/protobuf/extension_set.h" // IWYU pragma: export +#include "google/protobuf/map.h" // IWYU pragma: export +#include "google/protobuf/map_entry.h" +#include "google/protobuf/map_field_inl.h" +#include "google/protobuf/generated_enum_reflection.h" +#include "google/protobuf/unknown_field_set.h" +#include "google/protobuf/empty.pb.h" +#include "google/protobuf/any.pb.h" +// @@protoc_insertion_point(includes) + +// Must be included last. +#include "google/protobuf/port_def.inc" + +#define PROTOBUF_INTERNAL_EXPORT_ProtoRpc_2eproto + +namespace google { +namespace protobuf { +namespace internal { +class AnyMetadata; +} // namespace internal +} // namespace protobuf +} // namespace google + +// Internal implementation detail -- do not use these members. +struct TableStruct_ProtoRpc_2eproto { + static const ::uint32_t offsets[]; +}; +extern const ::google::protobuf::internal::DescriptorTable + descriptor_table_ProtoRpc_2eproto; +namespace protorpc { +class Mnfo2uhnf92hvqi2nviouq2hv9puhq; +struct Mnfo2uhnf92hvqi2nviouq2hv9puhqDefaultTypeInternal; +extern Mnfo2uhnf92hvqi2nviouq2hv9puhqDefaultTypeInternal _Mnfo2uhnf92hvqi2nviouq2hv9puhq_default_instance_; +class RpcMessage; +struct RpcMessageDefaultTypeInternal; +extern RpcMessageDefaultTypeInternal _RpcMessage_default_instance_; +class RpcMessage_HeaderEntry_DoNotUse; +struct RpcMessage_HeaderEntry_DoNotUseDefaultTypeInternal; +extern RpcMessage_HeaderEntry_DoNotUseDefaultTypeInternal _RpcMessage_HeaderEntry_DoNotUse_default_instance_; +} // namespace protorpc +namespace google { +namespace protobuf { +} // namespace protobuf +} // namespace google + +namespace protorpc { +enum RpcErrorType : int { + SERVER_TIMEOUT = 0, + CLIENT_TIMEOUT = 1, + UNKNOWN_RPC_METHOD = 2, + CLIENT_ERROR = 3, + SERVER_ERROR = 4, + RpcErrorType_INT_MIN_SENTINEL_DO_NOT_USE_ = + std::numeric_limits<::int32_t>::min(), + RpcErrorType_INT_MAX_SENTINEL_DO_NOT_USE_ = + std::numeric_limits<::int32_t>::max(), +}; + +bool RpcErrorType_IsValid(int value); +extern const uint32_t RpcErrorType_internal_data_[]; +constexpr RpcErrorType RpcErrorType_MIN = static_cast(0); +constexpr RpcErrorType RpcErrorType_MAX = static_cast(4); +constexpr int RpcErrorType_ARRAYSIZE = 4 + 1; +const ::google::protobuf::EnumDescriptor* +RpcErrorType_descriptor(); +template +const std::string& RpcErrorType_Name(T value) { + static_assert(std::is_same::value || + std::is_integral::value, + "Incorrect type passed to RpcErrorType_Name()."); + return RpcErrorType_Name(static_cast(value)); +} +template <> +inline const std::string& RpcErrorType_Name(RpcErrorType value) { + return ::google::protobuf::internal::NameOfDenseEnum( + static_cast(value)); +} +inline bool RpcErrorType_Parse(absl::string_view name, RpcErrorType* value) { + return ::google::protobuf::internal::ParseNamedEnum( + RpcErrorType_descriptor(), name, value); +} + +// =================================================================== + + +// ------------------------------------------------------------------- + +class RpcMessage_HeaderEntry_DoNotUse final + : public ::google::protobuf::internal::MapEntry< + RpcMessage_HeaderEntry_DoNotUse, std::string, std::string, + ::google::protobuf::internal::WireFormatLite::TYPE_STRING, + ::google::protobuf::internal::WireFormatLite::TYPE_STRING> { + public: + using SuperType = ::google::protobuf::internal::MapEntry< + RpcMessage_HeaderEntry_DoNotUse, std::string, std::string, + ::google::protobuf::internal::WireFormatLite::TYPE_STRING, + ::google::protobuf::internal::WireFormatLite::TYPE_STRING>; + RpcMessage_HeaderEntry_DoNotUse(); + template + explicit PROTOBUF_CONSTEXPR RpcMessage_HeaderEntry_DoNotUse( + ::google::protobuf::internal::ConstantInitialized); + explicit RpcMessage_HeaderEntry_DoNotUse(::google::protobuf::Arena* arena); + static const RpcMessage_HeaderEntry_DoNotUse* internal_default_instance() { + return reinterpret_cast( + &_RpcMessage_HeaderEntry_DoNotUse_default_instance_); + } + static bool ValidateKey(std::string* s) { + return ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(s->data(), static_cast(s->size()), ::google::protobuf::internal::WireFormatLite::PARSE, "protorpc.RpcMessage.HeaderEntry.key"); + } + static bool ValidateValue(std::string* s) { + return ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(s->data(), static_cast(s->size()), ::google::protobuf::internal::WireFormatLite::PARSE, "protorpc.RpcMessage.HeaderEntry.value"); + } + ::google::protobuf::Metadata GetMetadata() const final; + friend struct ::TableStruct_ProtoRpc_2eproto; +}; +// ------------------------------------------------------------------- + +class RpcMessage final : + public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:protorpc.RpcMessage) */ { + public: + inline RpcMessage() : RpcMessage(nullptr) {} + ~RpcMessage() override; + template + explicit PROTOBUF_CONSTEXPR RpcMessage(::google::protobuf::internal::ConstantInitialized); + + inline RpcMessage(const RpcMessage& from) + : RpcMessage(nullptr, from) {} + RpcMessage(RpcMessage&& from) noexcept + : RpcMessage() { + *this = ::std::move(from); + } + + inline RpcMessage& operator=(const RpcMessage& from) { + CopyFrom(from); + return *this; + } + inline RpcMessage& operator=(RpcMessage&& from) noexcept { + if (this == &from) return *this; + if (GetArena() == from.GetArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance); + } + inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.mutable_unknown_fields<::google::protobuf::UnknownFieldSet>(); + } + + static const ::google::protobuf::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::google::protobuf::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::google::protobuf::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const RpcMessage& default_instance() { + return *internal_default_instance(); + } + static inline const RpcMessage* internal_default_instance() { + return reinterpret_cast( + &_RpcMessage_default_instance_); + } + static constexpr int kIndexInFileMessages = + 1; + + friend void swap(RpcMessage& a, RpcMessage& b) { + a.Swap(&b); + } + inline void Swap(RpcMessage* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() != nullptr && + GetArena() == other->GetArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() == other->GetArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::google::protobuf::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(RpcMessage* other) { + if (other == this) return; + ABSL_DCHECK(GetArena() == other->GetArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + RpcMessage* New(::google::protobuf::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + int GetCachedSize() const { return _impl_._cached_size_.Get(); } + + private: + ::google::protobuf::internal::CachedSize* AccessCachedSize() const final; + void SharedCtor(::google::protobuf::Arena* arena); + void SharedDtor(); + void InternalSwap(RpcMessage* other); + + private: + friend class ::google::protobuf::internal::AnyMetadata; + static ::absl::string_view FullMessageName() { + return "protorpc.RpcMessage"; + } + protected: + explicit RpcMessage(::google::protobuf::Arena* arena); + RpcMessage(::google::protobuf::Arena* arena, const RpcMessage& from); + public: + + ::google::protobuf::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + + // accessors ------------------------------------------------------- + + enum : int { + kHeaderFieldNumber = 1, + kRequestIdFieldNumber = 3, + kErrorClassNameFieldNumber = 5, + kErrorCodeFieldNumber = 6, + kErrorMessageFieldNumber = 7, + kBodyFieldNumber = 2, + kErrorTypeFieldNumber = 4, + }; + // map header = 1; + int header_size() const; + private: + int _internal_header_size() const; + + public: + void clear_header() ; + const ::google::protobuf::Map& header() const; + ::google::protobuf::Map* mutable_header(); + + private: + const ::google::protobuf::Map& _internal_header() const; + ::google::protobuf::Map* _internal_mutable_header(); + + public: + // string requestId = 3; + void clear_requestid() ; + const std::string& requestid() const; + template + void set_requestid(Arg_&& arg, Args_... args); + std::string* mutable_requestid(); + PROTOBUF_NODISCARD std::string* release_requestid(); + void set_allocated_requestid(std::string* value); + + private: + const std::string& _internal_requestid() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_requestid( + const std::string& value); + std::string* _internal_mutable_requestid(); + + public: + // optional string errorClassName = 5; + bool has_errorclassname() const; + void clear_errorclassname() ; + const std::string& errorclassname() const; + template + void set_errorclassname(Arg_&& arg, Args_... args); + std::string* mutable_errorclassname(); + PROTOBUF_NODISCARD std::string* release_errorclassname(); + void set_allocated_errorclassname(std::string* value); + + private: + const std::string& _internal_errorclassname() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_errorclassname( + const std::string& value); + std::string* _internal_mutable_errorclassname(); + + public: + // optional string errorCode = 6; + bool has_errorcode() const; + void clear_errorcode() ; + const std::string& errorcode() const; + template + void set_errorcode(Arg_&& arg, Args_... args); + std::string* mutable_errorcode(); + PROTOBUF_NODISCARD std::string* release_errorcode(); + void set_allocated_errorcode(std::string* value); + + private: + const std::string& _internal_errorcode() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_errorcode( + const std::string& value); + std::string* _internal_mutable_errorcode(); + + public: + // optional string errorMessage = 7; + bool has_errormessage() const; + void clear_errormessage() ; + const std::string& errormessage() const; + template + void set_errormessage(Arg_&& arg, Args_... args); + std::string* mutable_errormessage(); + PROTOBUF_NODISCARD std::string* release_errormessage(); + void set_allocated_errormessage(std::string* value); + + private: + const std::string& _internal_errormessage() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_errormessage( + const std::string& value); + std::string* _internal_mutable_errormessage(); + + public: + // .google.protobuf.Any body = 2; + bool has_body() const; + void clear_body() ; + const ::google::protobuf::Any& body() const; + PROTOBUF_NODISCARD ::google::protobuf::Any* release_body(); + ::google::protobuf::Any* mutable_body(); + void set_allocated_body(::google::protobuf::Any* value); + void unsafe_arena_set_allocated_body(::google::protobuf::Any* value); + ::google::protobuf::Any* unsafe_arena_release_body(); + + private: + const ::google::protobuf::Any& _internal_body() const; + ::google::protobuf::Any* _internal_mutable_body(); + + public: + // optional .protorpc.RpcErrorType errorType = 4; + bool has_errortype() const; + void clear_errortype() ; + ::protorpc::RpcErrorType errortype() const; + void set_errortype(::protorpc::RpcErrorType value); + + private: + ::protorpc::RpcErrorType _internal_errortype() const; + void _internal_set_errortype(::protorpc::RpcErrorType value); + + public: + // @@protoc_insertion_point(class_scope:protorpc.RpcMessage) + private: + class _Internal; + + friend class ::google::protobuf::MessageLite; + friend class ::google::protobuf::Arena; + template + friend class ::google::protobuf::Arena::InternalHelper; + using InternalArenaConstructable_ = void; + using DestructorSkippable_ = void; + struct Impl_ { + + inline explicit constexpr Impl_( + ::google::protobuf::internal::ConstantInitialized) noexcept; + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena); + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena, const Impl_& from); + ::google::protobuf::internal::HasBits<1> _has_bits_; + mutable ::google::protobuf::internal::CachedSize _cached_size_; + ::google::protobuf::internal::MapField + header_; + ::google::protobuf::internal::ArenaStringPtr requestid_; + ::google::protobuf::internal::ArenaStringPtr errorclassname_; + ::google::protobuf::internal::ArenaStringPtr errorcode_; + ::google::protobuf::internal::ArenaStringPtr errormessage_; + ::google::protobuf::Any* body_; + int errortype_; + PROTOBUF_TSAN_DECLARE_MEMBER + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_ProtoRpc_2eproto; +};// ------------------------------------------------------------------- + +class Mnfo2uhnf92hvqi2nviouq2hv9puhq final : + public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq) */ { + public: + inline Mnfo2uhnf92hvqi2nviouq2hv9puhq() : Mnfo2uhnf92hvqi2nviouq2hv9puhq(nullptr) {} + ~Mnfo2uhnf92hvqi2nviouq2hv9puhq() override; + template + explicit PROTOBUF_CONSTEXPR Mnfo2uhnf92hvqi2nviouq2hv9puhq(::google::protobuf::internal::ConstantInitialized); + + inline Mnfo2uhnf92hvqi2nviouq2hv9puhq(const Mnfo2uhnf92hvqi2nviouq2hv9puhq& from) + : Mnfo2uhnf92hvqi2nviouq2hv9puhq(nullptr, from) {} + Mnfo2uhnf92hvqi2nviouq2hv9puhq(Mnfo2uhnf92hvqi2nviouq2hv9puhq&& from) noexcept + : Mnfo2uhnf92hvqi2nviouq2hv9puhq() { + *this = ::std::move(from); + } + + inline Mnfo2uhnf92hvqi2nviouq2hv9puhq& operator=(const Mnfo2uhnf92hvqi2nviouq2hv9puhq& from) { + CopyFrom(from); + return *this; + } + inline Mnfo2uhnf92hvqi2nviouq2hv9puhq& operator=(Mnfo2uhnf92hvqi2nviouq2hv9puhq&& from) noexcept { + if (this == &from) return *this; + if (GetArena() == from.GetArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + inline const ::google::protobuf::UnknownFieldSet& unknown_fields() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance); + } + inline ::google::protobuf::UnknownFieldSet* mutable_unknown_fields() + ABSL_ATTRIBUTE_LIFETIME_BOUND { + return _internal_metadata_.mutable_unknown_fields<::google::protobuf::UnknownFieldSet>(); + } + + static const ::google::protobuf::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::google::protobuf::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::google::protobuf::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const Mnfo2uhnf92hvqi2nviouq2hv9puhq& default_instance() { + return *internal_default_instance(); + } + static inline const Mnfo2uhnf92hvqi2nviouq2hv9puhq* internal_default_instance() { + return reinterpret_cast( + &_Mnfo2uhnf92hvqi2nviouq2hv9puhq_default_instance_); + } + static constexpr int kIndexInFileMessages = + 2; + + friend void swap(Mnfo2uhnf92hvqi2nviouq2hv9puhq& a, Mnfo2uhnf92hvqi2nviouq2hv9puhq& b) { + a.Swap(&b); + } + inline void Swap(Mnfo2uhnf92hvqi2nviouq2hv9puhq* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() != nullptr && + GetArena() == other->GetArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetArena() == other->GetArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::google::protobuf::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(Mnfo2uhnf92hvqi2nviouq2hv9puhq* other) { + if (other == this) return; + ABSL_DCHECK(GetArena() == other->GetArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + Mnfo2uhnf92hvqi2nviouq2hv9puhq* New(::google::protobuf::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + int GetCachedSize() const { return _impl_._cached_size_.Get(); } + + private: + ::google::protobuf::internal::CachedSize* AccessCachedSize() const final; + void SharedCtor(::google::protobuf::Arena* arena); + void SharedDtor(); + void InternalSwap(Mnfo2uhnf92hvqi2nviouq2hv9puhq* other); + + private: + friend class ::google::protobuf::internal::AnyMetadata; + static ::absl::string_view FullMessageName() { + return "protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq"; + } + protected: + explicit Mnfo2uhnf92hvqi2nviouq2hv9puhq(::google::protobuf::Arena* arena); + Mnfo2uhnf92hvqi2nviouq2hv9puhq(::google::protobuf::Arena* arena, const Mnfo2uhnf92hvqi2nviouq2hv9puhq& from); + public: + + ::google::protobuf::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int { + kEmptyFieldNumber = 1, + }; + // .google.protobuf.Empty empty = 1; + bool has_empty() const; + void clear_empty() ; + const ::google::protobuf::Empty& empty() const; + PROTOBUF_NODISCARD ::google::protobuf::Empty* release_empty(); + ::google::protobuf::Empty* mutable_empty(); + void set_allocated_empty(::google::protobuf::Empty* value); + void unsafe_arena_set_allocated_empty(::google::protobuf::Empty* value); + ::google::protobuf::Empty* unsafe_arena_release_empty(); + + private: + const ::google::protobuf::Empty& _internal_empty() const; + ::google::protobuf::Empty* _internal_mutable_empty(); + + public: + // @@protoc_insertion_point(class_scope:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq) + private: + class _Internal; + + friend class ::google::protobuf::MessageLite; + friend class ::google::protobuf::Arena; + template + friend class ::google::protobuf::Arena::InternalHelper; + using InternalArenaConstructable_ = void; + using DestructorSkippable_ = void; + struct Impl_ { + + inline explicit constexpr Impl_( + ::google::protobuf::internal::ConstantInitialized) noexcept; + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena); + inline explicit Impl_(::google::protobuf::internal::InternalVisibility visibility, + ::google::protobuf::Arena* arena, const Impl_& from); + ::google::protobuf::internal::HasBits<1> _has_bits_; + mutable ::google::protobuf::internal::CachedSize _cached_size_; + ::google::protobuf::Empty* empty_; + PROTOBUF_TSAN_DECLARE_MEMBER + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_ProtoRpc_2eproto; +}; + +// =================================================================== + + + + +// =================================================================== + + +#ifdef __GNUC__ +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wstrict-aliasing" +#endif // __GNUC__ +// ------------------------------------------------------------------- + +// ------------------------------------------------------------------- + +// RpcMessage + +// map header = 1; +inline int RpcMessage::_internal_header_size() const { + return _internal_header().size(); +} +inline int RpcMessage::header_size() const { + return _internal_header_size(); +} +inline void RpcMessage::clear_header() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.header_.Clear(); +} +inline const ::google::protobuf::Map& RpcMessage::_internal_header() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.header_.GetMap(); +} +inline const ::google::protobuf::Map& RpcMessage::header() const ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_map:protorpc.RpcMessage.header) + return _internal_header(); +} +inline ::google::protobuf::Map* RpcMessage::_internal_mutable_header() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + return _impl_.header_.MutableMap(); +} +inline ::google::protobuf::Map* RpcMessage::mutable_header() ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_mutable_map:protorpc.RpcMessage.header) + return _internal_mutable_header(); +} + +// .google.protobuf.Any body = 2; +inline bool RpcMessage::has_body() const { + bool value = (_impl_._has_bits_[0] & 0x00000008u) != 0; + PROTOBUF_ASSUME(!value || _impl_.body_ != nullptr); + return value; +} +inline const ::google::protobuf::Any& RpcMessage::_internal_body() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + const ::google::protobuf::Any* p = _impl_.body_; + return p != nullptr ? *p : reinterpret_cast(::google::protobuf::_Any_default_instance_); +} +inline const ::google::protobuf::Any& RpcMessage::body() const ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:protorpc.RpcMessage.body) + return _internal_body(); +} +inline void RpcMessage::unsafe_arena_set_allocated_body(::google::protobuf::Any* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (GetArena() == nullptr) { + delete reinterpret_cast<::google::protobuf::MessageLite*>(_impl_.body_); + } + _impl_.body_ = reinterpret_cast<::google::protobuf::Any*>(value); + if (value != nullptr) { + _impl_._has_bits_[0] |= 0x00000008u; + } else { + _impl_._has_bits_[0] &= ~0x00000008u; + } + // @@protoc_insertion_point(field_unsafe_arena_set_allocated:protorpc.RpcMessage.body) +} +inline ::google::protobuf::Any* RpcMessage::release_body() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + + _impl_._has_bits_[0] &= ~0x00000008u; + ::google::protobuf::Any* released = _impl_.body_; + _impl_.body_ = nullptr; +#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE + auto* old = reinterpret_cast<::google::protobuf::MessageLite*>(released); + released = ::google::protobuf::internal::DuplicateIfNonNull(released); + if (GetArena() == nullptr) { + delete old; + } +#else // PROTOBUF_FORCE_COPY_IN_RELEASE + if (GetArena() != nullptr) { + released = ::google::protobuf::internal::DuplicateIfNonNull(released); + } +#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE + return released; +} +inline ::google::protobuf::Any* RpcMessage::unsafe_arena_release_body() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:protorpc.RpcMessage.body) + + _impl_._has_bits_[0] &= ~0x00000008u; + ::google::protobuf::Any* temp = _impl_.body_; + _impl_.body_ = nullptr; + return temp; +} +inline ::google::protobuf::Any* RpcMessage::_internal_mutable_body() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000008u; + if (_impl_.body_ == nullptr) { + auto* p = CreateMaybeMessage<::google::protobuf::Any>(GetArena()); + _impl_.body_ = reinterpret_cast<::google::protobuf::Any*>(p); + } + return _impl_.body_; +} +inline ::google::protobuf::Any* RpcMessage::mutable_body() ABSL_ATTRIBUTE_LIFETIME_BOUND { + ::google::protobuf::Any* _msg = _internal_mutable_body(); + // @@protoc_insertion_point(field_mutable:protorpc.RpcMessage.body) + return _msg; +} +inline void RpcMessage::set_allocated_body(::google::protobuf::Any* value) { + ::google::protobuf::Arena* message_arena = GetArena(); + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (message_arena == nullptr) { + delete reinterpret_cast<::google::protobuf::MessageLite*>(_impl_.body_); + } + + if (value != nullptr) { + ::google::protobuf::Arena* submessage_arena = reinterpret_cast<::google::protobuf::MessageLite*>(value)->GetArena(); + if (message_arena != submessage_arena) { + value = ::google::protobuf::internal::GetOwnedMessage(message_arena, value, submessage_arena); + } + _impl_._has_bits_[0] |= 0x00000008u; + } else { + _impl_._has_bits_[0] &= ~0x00000008u; + } + + _impl_.body_ = reinterpret_cast<::google::protobuf::Any*>(value); + // @@protoc_insertion_point(field_set_allocated:protorpc.RpcMessage.body) +} + +// string requestId = 3; +inline void RpcMessage::clear_requestid() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.requestid_.ClearToEmpty(); +} +inline const std::string& RpcMessage::requestid() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:protorpc.RpcMessage.requestId) + return _internal_requestid(); +} +template +inline PROTOBUF_ALWAYS_INLINE void RpcMessage::set_requestid(Arg_&& arg, + Args_... args) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + _impl_.requestid_.Set(static_cast(arg), args..., GetArena()); + // @@protoc_insertion_point(field_set:protorpc.RpcMessage.requestId) +} +inline std::string* RpcMessage::mutable_requestid() ABSL_ATTRIBUTE_LIFETIME_BOUND { + std::string* _s = _internal_mutable_requestid(); + // @@protoc_insertion_point(field_mutable:protorpc.RpcMessage.requestId) + return _s; +} +inline const std::string& RpcMessage::_internal_requestid() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.requestid_.Get(); +} +inline void RpcMessage::_internal_set_requestid(const std::string& value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + _impl_.requestid_.Set(value, GetArena()); +} +inline std::string* RpcMessage::_internal_mutable_requestid() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + ; + return _impl_.requestid_.Mutable( GetArena()); +} +inline std::string* RpcMessage::release_requestid() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:protorpc.RpcMessage.requestId) + return _impl_.requestid_.Release(); +} +inline void RpcMessage::set_allocated_requestid(std::string* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.requestid_.SetAllocated(value, GetArena()); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.requestid_.IsDefault()) { + _impl_.requestid_.Set("", GetArena()); + } + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:protorpc.RpcMessage.requestId) +} + +// optional .protorpc.RpcErrorType errorType = 4; +inline bool RpcMessage::has_errortype() const { + bool value = (_impl_._has_bits_[0] & 0x00000010u) != 0; + return value; +} +inline void RpcMessage::clear_errortype() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.errortype_ = 0; + _impl_._has_bits_[0] &= ~0x00000010u; +} +inline ::protorpc::RpcErrorType RpcMessage::errortype() const { + // @@protoc_insertion_point(field_get:protorpc.RpcMessage.errorType) + return _internal_errortype(); +} +inline void RpcMessage::set_errortype(::protorpc::RpcErrorType value) { + _internal_set_errortype(value); + // @@protoc_insertion_point(field_set:protorpc.RpcMessage.errorType) +} +inline ::protorpc::RpcErrorType RpcMessage::_internal_errortype() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return static_cast<::protorpc::RpcErrorType>(_impl_.errortype_); +} +inline void RpcMessage::_internal_set_errortype(::protorpc::RpcErrorType value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000010u; + _impl_.errortype_ = value; +} + +// optional string errorClassName = 5; +inline bool RpcMessage::has_errorclassname() const { + bool value = (_impl_._has_bits_[0] & 0x00000001u) != 0; + return value; +} +inline void RpcMessage::clear_errorclassname() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.errorclassname_.ClearToEmpty(); + _impl_._has_bits_[0] &= ~0x00000001u; +} +inline const std::string& RpcMessage::errorclassname() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:protorpc.RpcMessage.errorClassName) + return _internal_errorclassname(); +} +template +inline PROTOBUF_ALWAYS_INLINE void RpcMessage::set_errorclassname(Arg_&& arg, + Args_... args) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.errorclassname_.Set(static_cast(arg), args..., GetArena()); + // @@protoc_insertion_point(field_set:protorpc.RpcMessage.errorClassName) +} +inline std::string* RpcMessage::mutable_errorclassname() ABSL_ATTRIBUTE_LIFETIME_BOUND { + std::string* _s = _internal_mutable_errorclassname(); + // @@protoc_insertion_point(field_mutable:protorpc.RpcMessage.errorClassName) + return _s; +} +inline const std::string& RpcMessage::_internal_errorclassname() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.errorclassname_.Get(); +} +inline void RpcMessage::_internal_set_errorclassname(const std::string& value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.errorclassname_.Set(value, GetArena()); +} +inline std::string* RpcMessage::_internal_mutable_errorclassname() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000001u; + return _impl_.errorclassname_.Mutable( GetArena()); +} +inline std::string* RpcMessage::release_errorclassname() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:protorpc.RpcMessage.errorClassName) + if ((_impl_._has_bits_[0] & 0x00000001u) == 0) { + return nullptr; + } + _impl_._has_bits_[0] &= ~0x00000001u; + auto* released = _impl_.errorclassname_.Release(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.errorclassname_.Set("", GetArena()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + return released; +} +inline void RpcMessage::set_allocated_errorclassname(std::string* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (value != nullptr) { + _impl_._has_bits_[0] |= 0x00000001u; + } else { + _impl_._has_bits_[0] &= ~0x00000001u; + } + _impl_.errorclassname_.SetAllocated(value, GetArena()); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.errorclassname_.IsDefault()) { + _impl_.errorclassname_.Set("", GetArena()); + } + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:protorpc.RpcMessage.errorClassName) +} + +// optional string errorCode = 6; +inline bool RpcMessage::has_errorcode() const { + bool value = (_impl_._has_bits_[0] & 0x00000002u) != 0; + return value; +} +inline void RpcMessage::clear_errorcode() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.errorcode_.ClearToEmpty(); + _impl_._has_bits_[0] &= ~0x00000002u; +} +inline const std::string& RpcMessage::errorcode() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:protorpc.RpcMessage.errorCode) + return _internal_errorcode(); +} +template +inline PROTOBUF_ALWAYS_INLINE void RpcMessage::set_errorcode(Arg_&& arg, + Args_... args) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.errorcode_.Set(static_cast(arg), args..., GetArena()); + // @@protoc_insertion_point(field_set:protorpc.RpcMessage.errorCode) +} +inline std::string* RpcMessage::mutable_errorcode() ABSL_ATTRIBUTE_LIFETIME_BOUND { + std::string* _s = _internal_mutable_errorcode(); + // @@protoc_insertion_point(field_mutable:protorpc.RpcMessage.errorCode) + return _s; +} +inline const std::string& RpcMessage::_internal_errorcode() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.errorcode_.Get(); +} +inline void RpcMessage::_internal_set_errorcode(const std::string& value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.errorcode_.Set(value, GetArena()); +} +inline std::string* RpcMessage::_internal_mutable_errorcode() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000002u; + return _impl_.errorcode_.Mutable( GetArena()); +} +inline std::string* RpcMessage::release_errorcode() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:protorpc.RpcMessage.errorCode) + if ((_impl_._has_bits_[0] & 0x00000002u) == 0) { + return nullptr; + } + _impl_._has_bits_[0] &= ~0x00000002u; + auto* released = _impl_.errorcode_.Release(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.errorcode_.Set("", GetArena()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + return released; +} +inline void RpcMessage::set_allocated_errorcode(std::string* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (value != nullptr) { + _impl_._has_bits_[0] |= 0x00000002u; + } else { + _impl_._has_bits_[0] &= ~0x00000002u; + } + _impl_.errorcode_.SetAllocated(value, GetArena()); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.errorcode_.IsDefault()) { + _impl_.errorcode_.Set("", GetArena()); + } + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:protorpc.RpcMessage.errorCode) +} + +// optional string errorMessage = 7; +inline bool RpcMessage::has_errormessage() const { + bool value = (_impl_._has_bits_[0] & 0x00000004u) != 0; + return value; +} +inline void RpcMessage::clear_errormessage() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_.errormessage_.ClearToEmpty(); + _impl_._has_bits_[0] &= ~0x00000004u; +} +inline const std::string& RpcMessage::errormessage() const + ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:protorpc.RpcMessage.errorMessage) + return _internal_errormessage(); +} +template +inline PROTOBUF_ALWAYS_INLINE void RpcMessage::set_errormessage(Arg_&& arg, + Args_... args) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.errormessage_.Set(static_cast(arg), args..., GetArena()); + // @@protoc_insertion_point(field_set:protorpc.RpcMessage.errorMessage) +} +inline std::string* RpcMessage::mutable_errormessage() ABSL_ATTRIBUTE_LIFETIME_BOUND { + std::string* _s = _internal_mutable_errormessage(); + // @@protoc_insertion_point(field_mutable:protorpc.RpcMessage.errorMessage) + return _s; +} +inline const std::string& RpcMessage::_internal_errormessage() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + return _impl_.errormessage_.Get(); +} +inline void RpcMessage::_internal_set_errormessage(const std::string& value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.errormessage_.Set(value, GetArena()); +} +inline std::string* RpcMessage::_internal_mutable_errormessage() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000004u; + return _impl_.errormessage_.Mutable( GetArena()); +} +inline std::string* RpcMessage::release_errormessage() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:protorpc.RpcMessage.errorMessage) + if ((_impl_._has_bits_[0] & 0x00000004u) == 0) { + return nullptr; + } + _impl_._has_bits_[0] &= ~0x00000004u; + auto* released = _impl_.errormessage_.Release(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.errormessage_.Set("", GetArena()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + return released; +} +inline void RpcMessage::set_allocated_errormessage(std::string* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (value != nullptr) { + _impl_._has_bits_[0] |= 0x00000004u; + } else { + _impl_._has_bits_[0] &= ~0x00000004u; + } + _impl_.errormessage_.SetAllocated(value, GetArena()); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.errormessage_.IsDefault()) { + _impl_.errormessage_.Set("", GetArena()); + } + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:protorpc.RpcMessage.errorMessage) +} + +// ------------------------------------------------------------------- + +// Mnfo2uhnf92hvqi2nviouq2hv9puhq + +// .google.protobuf.Empty empty = 1; +inline bool Mnfo2uhnf92hvqi2nviouq2hv9puhq::has_empty() const { + bool value = (_impl_._has_bits_[0] & 0x00000001u) != 0; + PROTOBUF_ASSUME(!value || _impl_.empty_ != nullptr); + return value; +} +inline const ::google::protobuf::Empty& Mnfo2uhnf92hvqi2nviouq2hv9puhq::_internal_empty() const { + PROTOBUF_TSAN_READ(&_impl_._tsan_detect_race); + const ::google::protobuf::Empty* p = _impl_.empty_; + return p != nullptr ? *p : reinterpret_cast(::google::protobuf::_Empty_default_instance_); +} +inline const ::google::protobuf::Empty& Mnfo2uhnf92hvqi2nviouq2hv9puhq::empty() const ABSL_ATTRIBUTE_LIFETIME_BOUND { + // @@protoc_insertion_point(field_get:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq.empty) + return _internal_empty(); +} +inline void Mnfo2uhnf92hvqi2nviouq2hv9puhq::unsafe_arena_set_allocated_empty(::google::protobuf::Empty* value) { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (GetArena() == nullptr) { + delete reinterpret_cast<::google::protobuf::MessageLite*>(_impl_.empty_); + } + _impl_.empty_ = reinterpret_cast<::google::protobuf::Empty*>(value); + if (value != nullptr) { + _impl_._has_bits_[0] |= 0x00000001u; + } else { + _impl_._has_bits_[0] &= ~0x00000001u; + } + // @@protoc_insertion_point(field_unsafe_arena_set_allocated:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq.empty) +} +inline ::google::protobuf::Empty* Mnfo2uhnf92hvqi2nviouq2hv9puhq::release_empty() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + + _impl_._has_bits_[0] &= ~0x00000001u; + ::google::protobuf::Empty* released = _impl_.empty_; + _impl_.empty_ = nullptr; +#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE + auto* old = reinterpret_cast<::google::protobuf::MessageLite*>(released); + released = ::google::protobuf::internal::DuplicateIfNonNull(released); + if (GetArena() == nullptr) { + delete old; + } +#else // PROTOBUF_FORCE_COPY_IN_RELEASE + if (GetArena() != nullptr) { + released = ::google::protobuf::internal::DuplicateIfNonNull(released); + } +#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE + return released; +} +inline ::google::protobuf::Empty* Mnfo2uhnf92hvqi2nviouq2hv9puhq::unsafe_arena_release_empty() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + // @@protoc_insertion_point(field_release:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq.empty) + + _impl_._has_bits_[0] &= ~0x00000001u; + ::google::protobuf::Empty* temp = _impl_.empty_; + _impl_.empty_ = nullptr; + return temp; +} +inline ::google::protobuf::Empty* Mnfo2uhnf92hvqi2nviouq2hv9puhq::_internal_mutable_empty() { + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + _impl_._has_bits_[0] |= 0x00000001u; + if (_impl_.empty_ == nullptr) { + auto* p = CreateMaybeMessage<::google::protobuf::Empty>(GetArena()); + _impl_.empty_ = reinterpret_cast<::google::protobuf::Empty*>(p); + } + return _impl_.empty_; +} +inline ::google::protobuf::Empty* Mnfo2uhnf92hvqi2nviouq2hv9puhq::mutable_empty() ABSL_ATTRIBUTE_LIFETIME_BOUND { + ::google::protobuf::Empty* _msg = _internal_mutable_empty(); + // @@protoc_insertion_point(field_mutable:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq.empty) + return _msg; +} +inline void Mnfo2uhnf92hvqi2nviouq2hv9puhq::set_allocated_empty(::google::protobuf::Empty* value) { + ::google::protobuf::Arena* message_arena = GetArena(); + PROTOBUF_TSAN_WRITE(&_impl_._tsan_detect_race); + if (message_arena == nullptr) { + delete reinterpret_cast<::google::protobuf::MessageLite*>(_impl_.empty_); + } + + if (value != nullptr) { + ::google::protobuf::Arena* submessage_arena = reinterpret_cast<::google::protobuf::MessageLite*>(value)->GetArena(); + if (message_arena != submessage_arena) { + value = ::google::protobuf::internal::GetOwnedMessage(message_arena, value, submessage_arena); + } + _impl_._has_bits_[0] |= 0x00000001u; + } else { + _impl_._has_bits_[0] &= ~0x00000001u; + } + + _impl_.empty_ = reinterpret_cast<::google::protobuf::Empty*>(value); + // @@protoc_insertion_point(field_set_allocated:protorpc.Mnfo2uhnf92hvqi2nviouq2hv9puhq.empty) +} + +#ifdef __GNUC__ +#pragma GCC diagnostic pop +#endif // __GNUC__ + +// @@protoc_insertion_point(namespace_scope) +} // namespace protorpc + + +namespace google { +namespace protobuf { + +template <> +struct is_proto_enum<::protorpc::RpcErrorType> : std::true_type {}; +template <> +inline const EnumDescriptor* GetEnumDescriptor<::protorpc::RpcErrorType>() { + return ::protorpc::RpcErrorType_descriptor(); +} + +} // namespace protobuf +} // namespace google + +// @@protoc_insertion_point(global_scope) + +#include "google/protobuf/port_undef.inc" + +#endif // GOOGLE_PROTOBUF_INCLUDED_ProtoRpc_2eproto_2epb_2eh diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/StreamrProtoRpcExampleApp-Bridging-Header.h b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/StreamrProtoRpcExampleApp-Bridging-Header.h new file mode 100644 index 00000000..c3dc66b1 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/StreamrProtoRpcExampleApp-Bridging-Header.h @@ -0,0 +1,5 @@ +// +// Use this file to import your target's public headers that you would like to expose to Swift. +// + +#include "Wrapper.h" diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/StreamrProtoRpcExampleAppApp.swift b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/StreamrProtoRpcExampleAppApp.swift new file mode 100644 index 00000000..971dc8c3 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/StreamrProtoRpcExampleAppApp.swift @@ -0,0 +1,17 @@ +// +// StreamrProtoRpcExampleAppApp.swift +// StreamrProtoRpcExampleApp +// +// Created by Santtu Rantanen on 21.8.2024. +// + +import SwiftUI + +@main +struct StreamrProtoRpcExampleAppApp: App { + var body: some Scene { + WindowGroup { + ContentView() + } + } +} diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Wrapper.h b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Wrapper.h new file mode 100644 index 00000000..b246b573 --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Wrapper.h @@ -0,0 +1,12 @@ +// +// Wrapper.h +// StreamrProtoRpcExampleApp +// +// Created by Santtu Rantanen on 21.8.2024. +// + +#import + +@interface Wrapper : NSObject +-(NSString*) greetingWrapper; +@end diff --git a/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Wrapper.mm b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Wrapper.mm new file mode 100644 index 00000000..7ffb91db --- /dev/null +++ b/packages/streamr-proto-rpc/examples/ios/xcframeworkexampleapp/StreamrProtoRpcExampleApp/Wrapper.mm @@ -0,0 +1,17 @@ +// +// Wrapper.m +// StreamrProtoRpcExampleApp +// +// Created by Santtu Rantanen on 21.8.2024. +// +#include "Wrapper.h" +#include "folly/Format.h" +#include "Hello.hpp" + +@implementation Wrapper + +- (NSString *)greetingWrapper { + return [NSString stringWithUTF8String:sayHello().c_str()]; +} + +@end diff --git a/packages/streamr-proto-rpc/test/unit/RpcCommunicatorTest.cpp b/packages/streamr-proto-rpc/test/unit/RpcCommunicatorTest.cpp index 04a7ff32..07875d4a 100644 --- a/packages/streamr-proto-rpc/test/unit/RpcCommunicatorTest.cpp +++ b/packages/streamr-proto-rpc/test/unit/RpcCommunicatorTest.cpp @@ -1,3 +1,5 @@ +#define GLOG_USE_GLOG_EXPORT + #include #include #include diff --git a/packages/streamr-proto-rpc/test/unit/ServerRegistryTest.cpp b/packages/streamr-proto-rpc/test/unit/ServerRegistryTest.cpp index b381a9fc..99f65837 100644 --- a/packages/streamr-proto-rpc/test/unit/ServerRegistryTest.cpp +++ b/packages/streamr-proto-rpc/test/unit/ServerRegistryTest.cpp @@ -1,3 +1,5 @@ +#define GLOG_USE_GLOG_EXPORT + #include #include @@ -88,4 +90,4 @@ TEST_F(ServerRegistryTest, HandleNotificationWithMissingMethodHeader) { } // namespace streamr::protorpc -// ENDNOLINT \ No newline at end of file +// ENDNOLINT diff --git a/test/ios/iOSUnitTesting/fastlane/Fastfile b/test/ios/iOSUnitTesting/fastlane/Fastfile new file mode 100644 index 00000000..5b03abb4 --- /dev/null +++ b/test/ios/iOSUnitTesting/fastlane/Fastfile @@ -0,0 +1,23 @@ +# This file contains the fastlane.tools configuration +# You can find the documentation at https://docs.fastlane.tools +# +# For a list of all available actions, check out +# +# https://docs.fastlane.tools/actions +# +# For a list of all available plugins, check out +# +# https://docs.fastlane.tools/plugins/available-plugins +# + +# Uncomment the line if you want fastlane to automatically update itself +# update_fastlane + + + lane :test do + scan( + scheme: 'iOSUnitTesting', # Project scheme name + clean: true, # Clean project folder before test execution + destination: 'platform=macOS' + ) + end diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.pbxproj b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.pbxproj new file mode 100644 index 00000000..b9b68449 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.pbxproj @@ -0,0 +1,604 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + 410E67B42C819BC900347AF3 /* iOSUnitTestingApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 410E67B32C819BC900347AF3 /* iOSUnitTestingApp.swift */; }; + 410E67B62C819BC900347AF3 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 410E67B52C819BC900347AF3 /* ContentView.swift */; }; + 410E67B82C819BCC00347AF3 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 410E67B72C819BCC00347AF3 /* Assets.xcassets */; }; + 410E67BB2C819BCC00347AF3 /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 410E67BA2C819BCC00347AF3 /* Preview Assets.xcassets */; }; + 410E67C52C819BCC00347AF3 /* StreamrTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 410E67C42C819BCC00347AF3 /* StreamrTests.swift */; }; + 410E69C82C81A4A100347AF3 /* gtest_main.cc in Sources */ = {isa = PBXBuildFile; fileRef = 410E69C62C81A4A100347AF3 /* gtest_main.cc */; }; + 410E69C92C81A4A100347AF3 /* gtest-all.cc in Sources */ = {isa = PBXBuildFile; fileRef = 410E69C72C81A4A100347AF3 /* gtest-all.cc */; }; + 410E69CC2C81B9E900347AF3 /* GoogleTestRunner.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E69CA2C81B9E900347AF3 /* GoogleTestRunner.cpp */; }; + 410E6A592C81F0C500347AF3 /* streamr.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 410E6A582C81F0C500347AF3 /* streamr.xcframework */; }; + 410E6A5C2C81F22000347AF3 /* libc++abi.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 410E6A5B2C81F22000347AF3 /* libc++abi.tbd */; }; + 410E6A5E2C81F2D000347AF3 /* libc++abi.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 410E6A5D2C81F2D000347AF3 /* libc++abi.tbd */; }; + 410E6AC02C82248400347AF3 /* EventEmitterTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6ABF2C82248400347AF3 /* EventEmitterTest.cpp */; }; + 410E6AC52C8224B200347AF3 /* toStringTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6AC12C8224B100347AF3 /* toStringTest.cpp */; }; + 410E6AC62C8224B200347AF3 /* toJsonTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6AC32C8224B200347AF3 /* toJsonTest.cpp */; }; + 410E6AC92C8224D300347AF3 /* StreamrLogFormatterTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6AC72C8224D300347AF3 /* StreamrLogFormatterTest.cpp */; }; + 410E6ACA2C8224D300347AF3 /* LoggerTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6AC82C8224D300347AF3 /* LoggerTest.cpp */; }; + 410E6ACD2C8224F500347AF3 /* RpcCommunicatorTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6ACB2C8224F500347AF3 /* RpcCommunicatorTest.cpp */; }; + 410E6ACE2C8224F500347AF3 /* ServerRegistryTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 410E6ACC2C8224F500347AF3 /* ServerRegistryTest.cpp */; }; + 410E6ADB2C82255D00347AF3 /* HelloRpc.pb.cc in Sources */ = {isa = PBXBuildFile; fileRef = 410E6ACF2C82255C00347AF3 /* HelloRpc.pb.cc */; }; + 410E6ADC2C82255D00347AF3 /* WakeUpRpc.pb.cc in Sources */ = {isa = PBXBuildFile; fileRef = 410E6AD12C82255C00347AF3 /* WakeUpRpc.pb.cc */; }; + 410E6ADD2C82255D00347AF3 /* TestProtos.pb.cc in Sources */ = {isa = PBXBuildFile; fileRef = 410E6AD62C82255D00347AF3 /* TestProtos.pb.cc */; }; + 410E6AE02C82258900347AF3 /* ProtoRpc.pb.cc in Sources */ = {isa = PBXBuildFile; fileRef = 410E6ADF2C82258900347AF3 /* ProtoRpc.pb.cc */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 410E67C12C819BCC00347AF3 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 410E67A82C819BC900347AF3 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 410E67AF2C819BC900347AF3; + remoteInfo = iOSUnitTesting; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 410E67B02C819BC900347AF3 /* iOSUnitTesting.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = iOSUnitTesting.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 410E67B32C819BC900347AF3 /* iOSUnitTestingApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = iOSUnitTestingApp.swift; sourceTree = ""; }; + 410E67B52C819BC900347AF3 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; + 410E67B72C819BCC00347AF3 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 410E67BA2C819BCC00347AF3 /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + 410E67C02C819BCC00347AF3 /* iOSUnitTestingTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = iOSUnitTestingTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 410E67C42C819BCC00347AF3 /* StreamrTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StreamrTests.swift; sourceTree = ""; }; + 410E69B92C819CF100347AF3 /* iOSUnitTestingTests-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "iOSUnitTestingTests-Bridging-Header.h"; sourceTree = ""; }; + 410E69C62C81A4A100347AF3 /* gtest_main.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = gtest_main.cc; path = ../../../vcpkg/packages/gtest_arm64-ios/src/gtest_main.cc; sourceTree = SOURCE_ROOT; }; + 410E69C72C81A4A100347AF3 /* gtest-all.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "gtest-all.cc"; path = "../../../vcpkg/packages/gtest_arm64-ios/src/gtest-all.cc"; sourceTree = SOURCE_ROOT; }; + 410E69CA2C81B9E900347AF3 /* GoogleTestRunner.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = GoogleTestRunner.cpp; sourceTree = ""; }; + 410E69CB2C81B9E900347AF3 /* GoogleTestRunner.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = GoogleTestRunner.hpp; sourceTree = ""; }; + 410E6A582C81F0C500347AF3 /* streamr.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = streamr.xcframework; path = ../../../../dist/ios/streamr.xcframework; sourceTree = ""; }; + 410E6A5B2C81F22000347AF3 /* libc++abi.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++abi.tbd"; path = "usr/lib/libc++abi.tbd"; sourceTree = SDKROOT; }; + 410E6A5D2C81F2D000347AF3 /* libc++abi.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++abi.tbd"; path = "Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.5.sdk/usr/lib/libc++abi.tbd"; sourceTree = DEVELOPER_DIR; }; + 410E6ABF2C82248400347AF3 /* EventEmitterTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = EventEmitterTest.cpp; path = "../../../../packages/streamr-eventemitter/test/unit/EventEmitterTest.cpp"; sourceTree = ""; }; + 410E6AC12C8224B100347AF3 /* toStringTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = toStringTest.cpp; path = "../../../../packages/streamr-json/test/unit/toStringTest.cpp"; sourceTree = ""; }; + 410E6AC22C8224B200347AF3 /* WeatherData.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = WeatherData.hpp; path = "../../../../packages/streamr-json/test/unit/WeatherData.hpp"; sourceTree = ""; }; + 410E6AC32C8224B200347AF3 /* toJsonTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = toJsonTest.cpp; path = "../../../../packages/streamr-json/test/unit/toJsonTest.cpp"; sourceTree = ""; }; + 410E6AC42C8224B200347AF3 /* TestClass.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = TestClass.hpp; path = "../../../../packages/streamr-json/test/unit/TestClass.hpp"; sourceTree = ""; }; + 410E6AC72C8224D300347AF3 /* StreamrLogFormatterTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = StreamrLogFormatterTest.cpp; path = "../../../../packages/streamr-logger/test/unit/StreamrLogFormatterTest.cpp"; sourceTree = ""; }; + 410E6AC82C8224D300347AF3 /* LoggerTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LoggerTest.cpp; path = "../../../../packages/streamr-logger/test/unit/LoggerTest.cpp"; sourceTree = ""; }; + 410E6ACB2C8224F500347AF3 /* RpcCommunicatorTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RpcCommunicatorTest.cpp; path = "../../../../packages/streamr-proto-rpc/test/unit/RpcCommunicatorTest.cpp"; sourceTree = ""; }; + 410E6ACC2C8224F500347AF3 /* ServerRegistryTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ServerRegistryTest.cpp; path = "../../../../packages/streamr-proto-rpc/test/unit/ServerRegistryTest.cpp"; sourceTree = ""; }; + 410E6ACF2C82255C00347AF3 /* HelloRpc.pb.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = HelloRpc.pb.cc; path = "../../../../packages/streamr-proto-rpc/test/proto/HelloRpc.pb.cc"; sourceTree = ""; }; + 410E6AD02C82255C00347AF3 /* TestProtos.client.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TestProtos.client.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/TestProtos.client.pb.h"; sourceTree = ""; }; + 410E6AD12C82255C00347AF3 /* WakeUpRpc.pb.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = WakeUpRpc.pb.cc; path = "../../../../packages/streamr-proto-rpc/test/proto/WakeUpRpc.pb.cc"; sourceTree = ""; }; + 410E6AD22C82255C00347AF3 /* WakeUpRpc.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WakeUpRpc.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/WakeUpRpc.pb.h"; sourceTree = ""; }; + 410E6AD32C82255D00347AF3 /* WakeUpRpc.server.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WakeUpRpc.server.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/WakeUpRpc.server.pb.h"; sourceTree = ""; }; + 410E6AD42C82255D00347AF3 /* WakeUpRpc.client.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WakeUpRpc.client.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/WakeUpRpc.client.pb.h"; sourceTree = ""; }; + 410E6AD52C82255D00347AF3 /* HelloRpc.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = HelloRpc.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/HelloRpc.pb.h"; sourceTree = ""; }; + 410E6AD62C82255D00347AF3 /* TestProtos.pb.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TestProtos.pb.cc; path = "../../../../packages/streamr-proto-rpc/test/proto/TestProtos.pb.cc"; sourceTree = ""; }; + 410E6AD72C82255D00347AF3 /* TestProtos.server.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TestProtos.server.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/TestProtos.server.pb.h"; sourceTree = ""; }; + 410E6AD82C82255D00347AF3 /* HelloRpc.client.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = HelloRpc.client.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/HelloRpc.client.pb.h"; sourceTree = ""; }; + 410E6AD92C82255D00347AF3 /* TestProtos.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TestProtos.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/TestProtos.pb.h"; sourceTree = ""; }; + 410E6ADA2C82255D00347AF3 /* HelloRpc.server.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = HelloRpc.server.pb.h; path = "../../../../packages/streamr-proto-rpc/test/proto/HelloRpc.server.pb.h"; sourceTree = ""; }; + 410E6ADE2C82258900347AF3 /* ProtoRpc.pb.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ProtoRpc.pb.h; path = "../../../../packages/streamr-proto-rpc/src/proto/ProtoRpc.pb.h"; sourceTree = ""; }; + 410E6ADF2C82258900347AF3 /* ProtoRpc.pb.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ProtoRpc.pb.cc; path = "../../../../packages/streamr-proto-rpc/src/proto/ProtoRpc.pb.cc"; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 410E67AD2C819BC900347AF3 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 410E6A5C2C81F22000347AF3 /* libc++abi.tbd in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 410E67BD2C819BCC00347AF3 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 410E6A5E2C81F2D000347AF3 /* libc++abi.tbd in Frameworks */, + 410E6A592C81F0C500347AF3 /* streamr.xcframework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 410E67A72C819BC900347AF3 = { + isa = PBXGroup; + children = ( + 410E67B22C819BC900347AF3 /* iOSUnitTesting */, + 410E67C32C819BCC00347AF3 /* iOSUnitTestingTests */, + 410E67B12C819BC900347AF3 /* Products */, + 410E6A5A2C81F21F00347AF3 /* Frameworks */, + ); + sourceTree = ""; + }; + 410E67B12C819BC900347AF3 /* Products */ = { + isa = PBXGroup; + children = ( + 410E67B02C819BC900347AF3 /* iOSUnitTesting.app */, + 410E67C02C819BCC00347AF3 /* iOSUnitTestingTests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 410E67B22C819BC900347AF3 /* iOSUnitTesting */ = { + isa = PBXGroup; + children = ( + 410E67B32C819BC900347AF3 /* iOSUnitTestingApp.swift */, + 410E67B52C819BC900347AF3 /* ContentView.swift */, + 410E67B72C819BCC00347AF3 /* Assets.xcassets */, + 410E67B92C819BCC00347AF3 /* Preview Content */, + ); + path = iOSUnitTesting; + sourceTree = ""; + }; + 410E67B92C819BCC00347AF3 /* Preview Content */ = { + isa = PBXGroup; + children = ( + 410E67BA2C819BCC00347AF3 /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; + 410E67C32C819BCC00347AF3 /* iOSUnitTestingTests */ = { + isa = PBXGroup; + children = ( + 410E6ADF2C82258900347AF3 /* ProtoRpc.pb.cc */, + 410E6ADE2C82258900347AF3 /* ProtoRpc.pb.h */, + 410E6AD82C82255D00347AF3 /* HelloRpc.client.pb.h */, + 410E6ACF2C82255C00347AF3 /* HelloRpc.pb.cc */, + 410E6AD52C82255D00347AF3 /* HelloRpc.pb.h */, + 410E6ADA2C82255D00347AF3 /* HelloRpc.server.pb.h */, + 410E6AD02C82255C00347AF3 /* TestProtos.client.pb.h */, + 410E6AD62C82255D00347AF3 /* TestProtos.pb.cc */, + 410E6AD92C82255D00347AF3 /* TestProtos.pb.h */, + 410E6AD72C82255D00347AF3 /* TestProtos.server.pb.h */, + 410E6AD42C82255D00347AF3 /* WakeUpRpc.client.pb.h */, + 410E6AD12C82255C00347AF3 /* WakeUpRpc.pb.cc */, + 410E6AD22C82255C00347AF3 /* WakeUpRpc.pb.h */, + 410E6AD32C82255D00347AF3 /* WakeUpRpc.server.pb.h */, + 410E6ACB2C8224F500347AF3 /* RpcCommunicatorTest.cpp */, + 410E6ACC2C8224F500347AF3 /* ServerRegistryTest.cpp */, + 410E6AC82C8224D300347AF3 /* LoggerTest.cpp */, + 410E6AC72C8224D300347AF3 /* StreamrLogFormatterTest.cpp */, + 410E6AC42C8224B200347AF3 /* TestClass.hpp */, + 410E6AC32C8224B200347AF3 /* toJsonTest.cpp */, + 410E6AC12C8224B100347AF3 /* toStringTest.cpp */, + 410E6AC22C8224B200347AF3 /* WeatherData.hpp */, + 410E6ABF2C82248400347AF3 /* EventEmitterTest.cpp */, + 410E6A582C81F0C500347AF3 /* streamr.xcframework */, + 410E69C62C81A4A100347AF3 /* gtest_main.cc */, + 410E69C72C81A4A100347AF3 /* gtest-all.cc */, + 410E67C42C819BCC00347AF3 /* StreamrTests.swift */, + 410E69B92C819CF100347AF3 /* iOSUnitTestingTests-Bridging-Header.h */, + 410E69CA2C81B9E900347AF3 /* GoogleTestRunner.cpp */, + 410E69CB2C81B9E900347AF3 /* GoogleTestRunner.hpp */, + ); + path = iOSUnitTestingTests; + sourceTree = ""; + }; + 410E6A5A2C81F21F00347AF3 /* Frameworks */ = { + isa = PBXGroup; + children = ( + 410E6A5D2C81F2D000347AF3 /* libc++abi.tbd */, + 410E6A5B2C81F22000347AF3 /* libc++abi.tbd */, + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 410E67AF2C819BC900347AF3 /* iOSUnitTesting */ = { + isa = PBXNativeTarget; + buildConfigurationList = 410E67D42C819BCC00347AF3 /* Build configuration list for PBXNativeTarget "iOSUnitTesting" */; + buildPhases = ( + 410E67AC2C819BC900347AF3 /* Sources */, + 410E67AD2C819BC900347AF3 /* Frameworks */, + 410E67AE2C819BC900347AF3 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = iOSUnitTesting; + productName = iOSUnitTesting; + productReference = 410E67B02C819BC900347AF3 /* iOSUnitTesting.app */; + productType = "com.apple.product-type.application"; + }; + 410E67BF2C819BCC00347AF3 /* iOSUnitTestingTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 410E67D72C819BCC00347AF3 /* Build configuration list for PBXNativeTarget "iOSUnitTestingTests" */; + buildPhases = ( + 410E67BC2C819BCC00347AF3 /* Sources */, + 410E67BD2C819BCC00347AF3 /* Frameworks */, + 410E67BE2C819BCC00347AF3 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 410E67C22C819BCC00347AF3 /* PBXTargetDependency */, + ); + name = iOSUnitTestingTests; + productName = iOSUnitTestingTests; + productReference = 410E67C02C819BCC00347AF3 /* iOSUnitTestingTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 410E67A82C819BC900347AF3 /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1540; + LastUpgradeCheck = 1540; + TargetAttributes = { + 410E67AF2C819BC900347AF3 = { + CreatedOnToolsVersion = 15.4; + LastSwiftMigration = 1540; + }; + 410E67BF2C819BCC00347AF3 = { + CreatedOnToolsVersion = 15.4; + LastSwiftMigration = 1540; + TestTargetID = 410E67AF2C819BC900347AF3; + }; + }; + }; + buildConfigurationList = 410E67AB2C819BC900347AF3 /* Build configuration list for PBXProject "iOSUnitTesting" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 410E67A72C819BC900347AF3; + productRefGroup = 410E67B12C819BC900347AF3 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 410E67AF2C819BC900347AF3 /* iOSUnitTesting */, + 410E67BF2C819BCC00347AF3 /* iOSUnitTestingTests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 410E67AE2C819BC900347AF3 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 410E67BB2C819BCC00347AF3 /* Preview Assets.xcassets in Resources */, + 410E67B82C819BCC00347AF3 /* Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 410E67BE2C819BCC00347AF3 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 410E67AC2C819BC900347AF3 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 410E67B62C819BC900347AF3 /* ContentView.swift in Sources */, + 410E67B42C819BC900347AF3 /* iOSUnitTestingApp.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 410E67BC2C819BCC00347AF3 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 410E6ACD2C8224F500347AF3 /* RpcCommunicatorTest.cpp in Sources */, + 410E6AC92C8224D300347AF3 /* StreamrLogFormatterTest.cpp in Sources */, + 410E6ADC2C82255D00347AF3 /* WakeUpRpc.pb.cc in Sources */, + 410E69C82C81A4A100347AF3 /* gtest_main.cc in Sources */, + 410E6AC52C8224B200347AF3 /* toStringTest.cpp in Sources */, + 410E67C52C819BCC00347AF3 /* StreamrTests.swift in Sources */, + 410E6AC62C8224B200347AF3 /* toJsonTest.cpp in Sources */, + 410E6ADD2C82255D00347AF3 /* TestProtos.pb.cc in Sources */, + 410E6ADB2C82255D00347AF3 /* HelloRpc.pb.cc in Sources */, + 410E6ACE2C8224F500347AF3 /* ServerRegistryTest.cpp in Sources */, + 410E6AE02C82258900347AF3 /* ProtoRpc.pb.cc in Sources */, + 410E6AC02C82248400347AF3 /* EventEmitterTest.cpp in Sources */, + 410E6ACA2C8224D300347AF3 /* LoggerTest.cpp in Sources */, + 410E69CC2C81B9E900347AF3 /* GoogleTestRunner.cpp in Sources */, + 410E69C92C81A4A100347AF3 /* gtest-all.cc in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 410E67C22C819BCC00347AF3 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 410E67AF2C819BC900347AF3 /* iOSUnitTesting */; + targetProxy = 410E67C12C819BCC00347AF3 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 410E67D22C819BCC00347AF3 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + HEADER_SEARCH_PATHS = ( + "$(SRCROOT)/../../../vcpkg/packages/gtest_arm64-ios/include", + "$(SRCROOT)/../../../vcpkg/packages/gtest_arm64-ios", + ); + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; + SWIFT_OBJC_INTEROP_MODE = objcxx; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 410E67D32C819BCC00347AF3 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + HEADER_SEARCH_PATHS = ( + "$(SRCROOT)/../../../vcpkg/packages/gtest_arm64-ios/include", + "$(SRCROOT)/../../../vcpkg/packages/gtest_arm64-ios", + ); + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OBJC_INTEROP_MODE = objcxx; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 410E67D52C819BCC00347AF3 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_IDENTITY = "Apple Development"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"iOSUnitTesting/Preview Content\""; + DEVELOPMENT_TEAM = 42FMY535TP; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.iOSUnitTesting; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 410E67D62C819BCC00347AF3 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_IDENTITY = "Apple Development"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"iOSUnitTesting/Preview Content\""; + DEVELOPMENT_TEAM = 42FMY535TP; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.iOSUnitTesting; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + 410E67D82C819BCC00347AF3 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = 42FMY535TP; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.iOSUnitTestingTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_OBJC_BRIDGING_HEADER = "iOSUnitTestingTests/iOSUnitTestingTests-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/iOSUnitTesting.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/iOSUnitTesting"; + }; + name = Debug; + }; + 410E67D92C819BCC00347AF3 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_IDENTITY = "Apple Development"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = 42FMY535TP; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.5; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = testing.iOSUnitTestingTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_OBJC_BRIDGING_HEADER = "iOSUnitTestingTests/iOSUnitTestingTests-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/iOSUnitTesting.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/iOSUnitTesting"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 410E67AB2C819BC900347AF3 /* Build configuration list for PBXProject "iOSUnitTesting" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 410E67D22C819BCC00347AF3 /* Debug */, + 410E67D32C819BCC00347AF3 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; + 410E67D42C819BCC00347AF3 /* Build configuration list for PBXNativeTarget "iOSUnitTesting" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 410E67D52C819BCC00347AF3 /* Debug */, + 410E67D62C819BCC00347AF3 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; + 410E67D72C819BCC00347AF3 /* Build configuration list for PBXNativeTarget "iOSUnitTestingTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 410E67D82C819BCC00347AF3 /* Debug */, + 410E67D92C819BCC00347AF3 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; +/* End XCConfigurationList section */ + }; + rootObject = 410E67A82C819BC900347AF3 /* Project object */; +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..919434a6 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 00000000..9bc95fb7 Binary files /dev/null and b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/project.xcworkspace/xcuserdata/santturantanen.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist new file mode 100644 index 00000000..0df42785 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 00000000..07f54868 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting.xcodeproj/xcuserdata/santturantanen.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,27 @@ + + + + + SchemeUserState + + iOSUnitTesting.xcscheme_^#shared#^_ + + orderHint + 0 + + + SuppressBuildableAutocreation + + 410E67AF2C819BC900347AF3 + + primary + + + 410E67BF2C819BCC00347AF3 + + primary + + + + + diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/AccentColor.colorset/Contents.json b/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/AccentColor.colorset/Contents.json new file mode 100644 index 00000000..eb878970 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/AccentColor.colorset/Contents.json @@ -0,0 +1,11 @@ +{ + "colors" : [ + { + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/AppIcon.appiconset/Contents.json b/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..13613e3e --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/Contents.json b/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting/ContentView.swift b/test/ios/iOSUnitTesting/iOSUnitTesting/ContentView.swift new file mode 100644 index 00000000..864b9583 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting/ContentView.swift @@ -0,0 +1,25 @@ +// +// ContentView.swift +// iOSUnitTesting +// +// Created by Santtu Rantanen on 30.8.2024. +// + +import SwiftUI + +struct ContentView: View { + var body: some View { + VStack { + Image(systemName: "globe") + .imageScale(.large) + .foregroundStyle(.tint) + Text("Testing!") + } + .padding() + } +} +/* +#Preview { + ContentView() +} +*/ diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting/Preview Content/Preview Assets.xcassets/Contents.json b/test/ios/iOSUnitTesting/iOSUnitTesting/Preview Content/Preview Assets.xcassets/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting/Preview Content/Preview Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTesting/iOSUnitTestingApp.swift b/test/ios/iOSUnitTesting/iOSUnitTesting/iOSUnitTestingApp.swift new file mode 100644 index 00000000..db2f28d6 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTesting/iOSUnitTestingApp.swift @@ -0,0 +1,17 @@ +// +// iOSUnitTestingApp.swift +// iOSUnitTesting +// +// Created by Santtu Rantanen on 30.8.2024. +// + +import SwiftUI + +@main +struct iOSUnitTestingApp: App { + var body: some Scene { + WindowGroup { + ContentView() + } + } +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTestingTests/GoogleTestRunner.cpp b/test/ios/iOSUnitTesting/iOSUnitTestingTests/GoogleTestRunner.cpp new file mode 100644 index 00000000..01c8f39f --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTestingTests/GoogleTestRunner.cpp @@ -0,0 +1,24 @@ +// +// GoogleTestRunner.cpp +// iOSUnitTestingTests +// +// Created by Santtu Rantanen on 30.8.2024. +// + +#define GLOG_USE_GLOG_EXPORT +#define GLOG_EXPORT + +#include "GoogleTestRunner.hpp" +#include "gtest/gtest.h" + +GoogleTestResult GoogleTestRunner::runAllTests(int argc, char** argv) const { + testing::internal::CaptureStdout(); + testing::InitGoogleTest(&argc, argv); + int result = RUN_ALL_TESTS(); + std::string output = testing::internal::GetCapturedStdout(); + GoogleTestResult googleTestResult = {output, result}; + return googleTestResult; +} + + + diff --git a/test/ios/iOSUnitTesting/iOSUnitTestingTests/GoogleTestRunner.hpp b/test/ios/iOSUnitTesting/iOSUnitTestingTests/GoogleTestRunner.hpp new file mode 100644 index 00000000..b966c80c --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTestingTests/GoogleTestRunner.hpp @@ -0,0 +1,24 @@ +// +// GoogleTestRunner.hpp +// iOSUnitTestingTests +// +// Created by Santtu Rantanen on 30.8.2024. +// + +#ifndef GoogleTestRunner_hpp +#define GoogleTestRunner_hpp + +#include + +struct GoogleTestResult { + std::string testOutput; + int result; +}; + +class GoogleTestRunner { +public: + GoogleTestRunner() { } + GoogleTestResult runAllTests(int argc, char** argv) const; +}; + +#endif /* GoogleTestRunner_hpp */ diff --git a/test/ios/iOSUnitTesting/iOSUnitTestingTests/StreamrTests.swift b/test/ios/iOSUnitTesting/iOSUnitTestingTests/StreamrTests.swift new file mode 100644 index 00000000..78ec5474 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTestingTests/StreamrTests.swift @@ -0,0 +1,22 @@ +// +// iOSUnitTestingTests.swift +// iOSUnitTestingTests +// +// Created by Santtu Rantanen on 30.8.2024. +// + +import XCTest + +class StreamrTests: XCTestCase { + + func testGoogleTests() { + let runner = GoogleTestRunner() + let argc: Int32 = 1 + var argv: [UnsafeMutablePointer?] = [strdup("GTests")] + let googleTestResult = runner.runAllTests(argc, &argv) + let resultInSwiftString = String(googleTestResult.testOutput) + print(resultInSwiftString) + XCTAssertEqual(googleTestResult.result, 0) + } + +} diff --git a/test/ios/iOSUnitTesting/iOSUnitTestingTests/gtest-all.cc b/test/ios/iOSUnitTesting/iOSUnitTestingTests/gtest-all.cc new file mode 100644 index 00000000..2a70ed88 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTestingTests/gtest-all.cc @@ -0,0 +1,49 @@ +// Copyright 2008, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +// +// Google C++ Testing and Mocking Framework (Google Test) +// +// Sometimes it's desirable to build Google Test by compiling a single file. +// This file serves this purpose. + +// This line ensures that gtest.h can be compiled on its own, even +// when it's fused. +#include "gtest/gtest.h" + +// The following lines pull in the real gtest *.cc files. +#include "src/gtest-assertion-result.cc" +#include "src/gtest-death-test.cc" +#include "src/gtest-filepath.cc" +#include "src/gtest-matchers.cc" +#include "src/gtest-port.cc" +#include "src/gtest-printers.cc" +#include "src/gtest-test-part.cc" +#include "src/gtest-typed-test.cc" +#include "src/gtest.cc" diff --git a/test/ios/iOSUnitTesting/iOSUnitTestingTests/gtest_main.cc b/test/ios/iOSUnitTesting/iOSUnitTestingTests/gtest_main.cc new file mode 100644 index 00000000..8141caf4 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTestingTests/gtest_main.cc @@ -0,0 +1,66 @@ +// Copyright 2006, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#include + +#include "gtest/gtest.h" + +#if defined(GTEST_OS_ESP8266) || defined(GTEST_OS_ESP32) || \ + (defined(GTEST_OS_NRF52) && defined(ARDUINO)) +// Arduino-like platforms: program entry points are setup/loop instead of main. + +#ifdef GTEST_OS_ESP8266 +extern "C" { +#endif + +void setup() { testing::InitGoogleTest(); } + +void loop() { RUN_ALL_TESTS(); } + +#ifdef GTEST_OS_ESP8266 +} +#endif + +#elif defined(GTEST_OS_QURT) +// QuRT: program entry point is main, but argc/argv are unusable. + +GTEST_API_ int main() { + printf("Running main() from %s\n", __FILE__); + testing::InitGoogleTest(); + return RUN_ALL_TESTS(); +} +#else +// Normal platforms: program entry point is main, argc/argv are initialized. + +GTEST_API_ int main(int argc, char **argv) { + printf("Running main() from %s\n", __FILE__); + testing::InitGoogleTest(&argc, argv); + return RUN_ALL_TESTS(); +} +#endif diff --git a/test/ios/iOSUnitTesting/iOSUnitTestingTests/iOSUnitTestingTests-Bridging-Header.h b/test/ios/iOSUnitTesting/iOSUnitTestingTests/iOSUnitTestingTests-Bridging-Header.h new file mode 100644 index 00000000..4761dee5 --- /dev/null +++ b/test/ios/iOSUnitTesting/iOSUnitTestingTests/iOSUnitTestingTests-Bridging-Header.h @@ -0,0 +1,5 @@ +// +// Use this file to import your target's public headers that you would like to expose to Swift. +// + +#include "GoogleTestRunner.hpp"