├── .github ├── FUNDING.yml └── workflows │ ├── build-and-test.yml │ └── documentation.yml ├── .gitignore ├── Images └── logo.jpg ├── LICENSE ├── Package.resolved ├── Package.swift ├── Package@swift-6.0.swift ├── README.md ├── Sources └── Bodega │ ├── CacheKey.swift │ ├── DiskStorageEngine.swift │ ├── Documentation.docc │ ├── Articles │ │ ├── Fundamentals │ │ │ ├── Bodega.md │ │ │ ├── Using ObjectStorage.md │ │ │ └── Using StorageEngines.md │ │ └── Walkthroughs │ │ │ └── Building An Image Cache.md │ └── Assets │ │ ├── ProfileHeaderview.png │ │ ├── StorageEngine-Read-Performance.png │ │ └── StorageEngine-Write-Performance.png │ ├── FileManager.Directory.swift │ ├── Internal │ └── String+Formatting.swift │ ├── ObjectStorage.swift │ ├── SQLiteStorageEngine+Default.swift │ ├── SQLiteStorageEngine.swift │ └── StorageEngine.swift ├── Tests └── BodegaTests │ ├── CacheKeyTests.swift │ ├── DiskStorageEngineTests.swift │ ├── ObjectStorageTests.swift │ ├── SQLiteStorageEngineTests.swift │ └── String+FormattingTests.swift └── docs ├── .gitkeep ├── css ├── documentation-topic.de084985.css ├── documentation-topic~topic~tutorials-overview.67b822e0.css ├── index.47bc740e.css ├── topic.2eb01958.css └── tutorials-overview.8754eb09.css ├── data └── documentation │ ├── bodega.json │ └── bodega │ ├── building-an-image-cache.json │ ├── cachekey.json │ ├── cachekey │ ├── !=(_:_:).json │ ├── equatable-implementations.json │ ├── init(_:).json │ ├── init(from:).json │ ├── init(url:).json │ ├── init(verbatim:).json │ └── value.json │ ├── diskstorageengine.json │ ├── diskstorageengine │ ├── allkeys().json │ ├── createdat(key:).json │ ├── init(directory:).json │ ├── keycount().json │ ├── keyexists(_:).json │ ├── lastaccessed(key:).json │ ├── read(key:).json │ ├── read(keys:).json │ ├── readalldata().json │ ├── readalldataandkeys().json │ ├── readdataandkeys(keys:).json │ ├── remove(key:).json │ ├── remove(keys:).json │ ├── removealldata().json │ ├── storageengine-implementations.json │ ├── updatedat(key:).json │ ├── write(_:).json │ └── write(_:key:).json │ ├── objectstorage.json │ ├── objectstorage │ ├── allkeys().json │ ├── allobjects().json │ ├── allobjectsandkeys().json │ ├── createdat(forkey:).json │ ├── init(storage:).json │ ├── keycount().json │ ├── object(forkey:).json │ ├── objects(forkeys:).json │ ├── objectsandkeys(keys:).json │ ├── removeallobjects().json │ ├── removeobject(forkey:).json │ ├── removeobject(forkeys:).json │ ├── store(_:).json │ ├── store(_:forkey:).json │ └── updatedat(forkey:).json │ ├── sqlitestorageengine.json │ ├── sqlitestorageengine │ ├── allkeys().json │ ├── createdat(key:).json │ ├── default(appendingpath:).json │ ├── default.json │ ├── init(directory:databasefilename:).json │ ├── keycount().json │ ├── keyexists(_:).json │ ├── read(key:).json │ ├── read(keys:).json │ ├── readalldata().json │ ├── readalldataandkeys().json │ ├── readdataandkeys(keys:).json │ ├── remove(key:).json │ ├── remove(keys:).json │ ├── removealldata().json │ ├── updatedat(key:).json │ ├── write(_:).json │ └── write(_:key:).json │ ├── storageengine.json │ ├── storageengine │ ├── allkeys().json │ ├── createdat(key:).json │ ├── keycount().json │ ├── keyexists(_:).json │ ├── read(key:).json │ ├── read(keys:)-1i8k4.json │ ├── read(keys:)-90zkt.json │ ├── readalldata()-1gzc6.json │ ├── readalldata()-56p4o.json │ ├── readalldataandkeys()-98wnz.json │ ├── readalldataandkeys()-9a3kk.json │ ├── readdataandkeys(keys:).json │ ├── remove(key:).json │ ├── remove(keys:)-2lqqc.json │ ├── remove(keys:)-fd9s.json │ ├── removealldata().json │ ├── updatedat(key:).json │ ├── write(_:).json │ └── write(_:key:).json │ ├── using-objectstorage.json │ └── using-storageengines.json ├── documentation └── bodega │ ├── building-an-image-cache │ └── index.html │ ├── cachekey │ ├── !=(_:_:) │ │ └── index.html │ ├── equatable-implementations │ │ └── index.html │ ├── index.html │ ├── init(_:) │ │ └── index.html │ ├── init(from:) │ │ └── index.html │ ├── init(url:) │ │ └── index.html │ ├── init(verbatim:) │ │ └── index.html │ └── value │ │ └── index.html │ ├── diskstorageengine │ ├── allkeys() │ │ └── index.html │ ├── createdat(key:) │ │ └── index.html │ ├── index.html │ ├── init(directory:) │ │ └── index.html │ ├── keycount() │ │ └── index.html │ ├── keyexists(_:) │ │ └── index.html │ ├── lastaccessed(key:) │ │ └── index.html │ ├── read(key:) │ │ └── index.html │ ├── read(keys:) │ │ └── index.html │ ├── readalldata() │ │ └── index.html │ ├── readalldataandkeys() │ │ └── index.html │ ├── readdataandkeys(keys:) │ │ └── index.html │ ├── remove(key:) │ │ └── index.html │ ├── remove(keys:) │ │ └── index.html │ ├── removealldata() │ │ └── index.html │ ├── storageengine-implementations │ │ └── index.html │ ├── updatedat(key:) │ │ └── index.html │ ├── write(_:) │ │ └── index.html │ └── write(_:key:) │ │ └── index.html │ ├── index.html │ ├── objectstorage │ ├── allkeys() │ │ └── index.html │ ├── allobjects() │ │ └── index.html │ ├── allobjectsandkeys() │ │ └── index.html │ ├── createdat(forkey:) │ │ └── index.html │ ├── index.html │ ├── init(storage:) │ │ └── index.html │ ├── keycount() │ │ └── index.html │ ├── object(forkey:) │ │ └── index.html │ ├── objects(forkeys:) │ │ └── index.html │ ├── objectsandkeys(keys:) │ │ └── index.html │ ├── removeallobjects() │ │ └── index.html │ ├── removeobject(forkey:) │ │ └── index.html │ ├── removeobject(forkeys:) │ │ └── index.html │ ├── store(_:) │ │ └── index.html │ ├── store(_:forkey:) │ │ └── index.html │ └── updatedat(forkey:) │ │ └── index.html │ ├── sqlitestorageengine │ ├── allkeys() │ │ └── index.html │ ├── createdat(key:) │ │ └── index.html │ ├── default(appendingpath:) │ │ └── index.html │ ├── default │ │ └── index.html │ ├── index.html │ ├── init(directory:databasefilename:) │ │ └── index.html │ ├── keycount() │ │ └── index.html │ ├── keyexists(_:) │ │ └── index.html │ ├── read(key:) │ │ └── index.html │ ├── read(keys:) │ │ └── index.html │ ├── readalldata() │ │ └── index.html │ ├── readalldataandkeys() │ │ └── index.html │ ├── readdataandkeys(keys:) │ │ └── index.html │ ├── remove(key:) │ │ └── index.html │ ├── remove(keys:) │ │ └── index.html │ ├── removealldata() │ │ └── index.html │ ├── updatedat(key:) │ │ └── index.html │ ├── write(_:) │ │ └── index.html │ └── write(_:key:) │ │ └── index.html │ ├── storageengine │ ├── allkeys() │ │ └── index.html │ ├── createdat(key:) │ │ └── index.html │ ├── index.html │ ├── keycount() │ │ └── index.html │ ├── keyexists(_:) │ │ └── index.html │ ├── read(key:) │ │ └── index.html │ ├── read(keys:)-1i8k4 │ │ └── index.html │ ├── read(keys:)-90zkt │ │ └── index.html │ ├── readalldata()-1gzc6 │ │ └── index.html │ ├── readalldata()-56p4o │ │ └── index.html │ ├── readalldataandkeys()-98wnz │ │ └── index.html │ ├── readalldataandkeys()-9a3kk │ │ └── index.html │ ├── readdataandkeys(keys:) │ │ └── index.html │ ├── remove(key:) │ │ └── index.html │ ├── remove(keys:)-2lqqc │ │ └── index.html │ ├── remove(keys:)-fd9s │ │ └── index.html │ ├── removealldata() │ │ └── index.html │ ├── updatedat(key:) │ │ └── index.html │ ├── write(_:) │ │ └── index.html │ └── write(_:key:) │ │ └── index.html │ ├── using-objectstorage │ └── index.html │ └── using-storageengines │ └── index.html ├── favicon.ico ├── favicon.svg ├── images ├── ProfileHeaderview.png ├── StorageEngine-Read-Performance.png └── StorageEngine-Write-Performance.png ├── img ├── added-icon.d6f7e47d.svg ├── deprecated-icon.015b4f17.svg └── modified-icon.f496e73d.svg ├── index.html ├── js ├── chunk-2d0d3105.cd72cc8e.js ├── chunk-vendors.00bf82af.js ├── documentation-topic.f2001a09.js ├── documentation-topic~topic~tutorials-overview.246bafa0.js ├── highlight-js-bash.1b52852f.js ├── highlight-js-c.d1db3f17.js ├── highlight-js-cpp.eaddddbe.js ├── highlight-js-css.75eab1fe.js ├── highlight-js-custom-markdown.7cffc4b3.js ├── highlight-js-custom-swift.52388c22.js ├── highlight-js-diff.62d66733.js ├── highlight-js-http.163e45b6.js ├── highlight-js-java.8326d9d8.js ├── highlight-js-javascript.acb8a8eb.js ├── highlight-js-json.471128d2.js ├── highlight-js-llvm.6100b125.js ├── highlight-js-markdown.90077643.js ├── highlight-js-objectivec.bcdf5156.js ├── highlight-js-perl.757d7b6f.js ├── highlight-js-php.cc8d6c27.js ├── highlight-js-python.c214ed92.js ├── highlight-js-ruby.f889d392.js ├── highlight-js-scss.62ee18da.js ├── highlight-js-shell.dd7f411f.js ├── highlight-js-swift.84f3e88c.js ├── highlight-js-xml.9c3688c7.js ├── index.a5dccb71.js ├── topic.db9b660d.js └── tutorials-overview.1f626fce.js ├── metadata.json └── theme-settings.json /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: [mergesort] 4 | patreon: # Replace with a single Patreon username 5 | open_collective: # Replace with a single Open Collective username 6 | ko_fi: # Replace with a single Ko-fi username 7 | tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel 8 | community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry 9 | liberapay: # Replace with a single Liberapay username 10 | issuehunt: # Replace with a single IssueHunt username 11 | otechie: # Replace with a single Otechie username 12 | lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry 13 | custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2'] 14 | -------------------------------------------------------------------------------- /.github/workflows/build-and-test.yml: -------------------------------------------------------------------------------- 1 | name: Build and Test 2 | 3 | on: 4 | push: 5 | branches: [ main ] 6 | pull_request: 7 | branches: [ main ] 8 | 9 | jobs: 10 | build-and-test: 11 | runs-on: macos-12 12 | 13 | steps: 14 | - uses: actions/checkout@v3 15 | - name: Build 16 | run: swift build -v 17 | - name: Run tests 18 | run: swift test -v 19 | -------------------------------------------------------------------------------- /.github/workflows/documentation.yml: -------------------------------------------------------------------------------- 1 | name: Documentation 2 | 3 | on: 4 | push: 5 | tags: 6 | - '*' 7 | workflow_dispatch: 8 | 9 | jobs: 10 | update_documentation: 11 | name: Update documentation 12 | runs-on: macos-12 13 | steps: 14 | - name: Checkout repository 15 | uses: actions/checkout@v3 16 | - name: Setup Swift version 17 | uses: swift-actions/setup-swift@v1 18 | with: 19 | swift-version: "5.6" 20 | - name: Generate documentation 21 | uses: fwcd/swift-docc-action@v1 22 | with: 23 | target: Bodega 24 | output: ./docs 25 | hosting-base-path: Bodega 26 | disable-indexing: 'true' 27 | transform-for-static-hosting: 'true' 28 | - name: Commit documentation 29 | run: | 30 | git config user.name github-actions 31 | git config user.email github-actions@github.com 32 | git add ./docs/** 33 | git commit -m "Generating documentation" 34 | git push 35 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore 4 | 5 | ## User settings 6 | xcuserdata/ 7 | 8 | ## compatibility with Xcode 8 and earlier (ignoring not required starting Xcode 9) 9 | *.xcscmblueprint 10 | *.xccheckout 11 | 12 | ## compatibility with Xcode 3 and earlier (ignoring not required starting Xcode 4) 13 | build/ 14 | DerivedData/ 15 | *.moved-aside 16 | *.pbxuser 17 | !default.pbxuser 18 | *.mode1v3 19 | !default.mode1v3 20 | *.mode2v3 21 | !default.mode2v3 22 | *.perspectivev3 23 | !default.perspectivev3 24 | 25 | ## Obj-C/Swift specific 26 | *.hmap 27 | 28 | ## App packaging 29 | *.ipa 30 | *.dSYM.zip 31 | *.dSYM 32 | 33 | ## Playgrounds 34 | timeline.xctimeline 35 | playground.xcworkspace 36 | 37 | # Swift Package Manager 38 | # 39 | # Add this line if you want to avoid checking in source code from Swift Package Manager dependencies. 40 | # Packages/ 41 | # Package.pins 42 | # Package.resolved 43 | # *.xcodeproj 44 | # 45 | # Xcode automatically generates this directory with a .xcworkspacedata file and xcuserdata 46 | # hence it is not needed unless you have added a package configuration file to your project 47 | # .swiftpm 48 | 49 | .build/ 50 | 51 | # CocoaPods 52 | # 53 | # We recommend against adding the Pods directory to your .gitignore. However 54 | # you should judge for yourself, the pros and cons are mentioned at: 55 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control 56 | # 57 | # Pods/ 58 | # 59 | # Add this line if you want to avoid checking in source code from the Xcode workspace 60 | # *.xcworkspace 61 | 62 | # Carthage 63 | # 64 | # Add this line if you want to avoid checking in source code from Carthage dependencies. 65 | # Carthage/Checkouts 66 | 67 | Carthage/Build/ 68 | 69 | # Accio dependency management 70 | Dependencies/ 71 | .accio/ 72 | 73 | # fastlane 74 | # 75 | # It is recommended to not store the screenshots in the git repo. 76 | # Instead, use fastlane to re-generate the screenshots whenever they are needed. 77 | # For more information about the recommended setup visit: 78 | # https://docs.fastlane.tools/best-practices/source-control/#source-control 79 | 80 | fastlane/report.xml 81 | fastlane/Preview.html 82 | fastlane/screenshots/**/*.png 83 | fastlane/test_output 84 | 85 | # Code Injection 86 | # 87 | # After new code Injection tools there's a generated folder /iOSInjectionProject 88 | # https://github.com/johnno1962/injectionforxcode 89 | 90 | iOSInjectionProject/ 91 | -------------------------------------------------------------------------------- /Images/logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/Images/logo.jpg -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Joe Fabisevich 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Package.resolved: -------------------------------------------------------------------------------- 1 | { 2 | "originHash" : "86883ab96265fe288b605bd24f286a2ee9ee68043c626263e602135a0bd1e29d", 3 | "pins" : [ 4 | { 5 | "identity" : "sqlite.swift", 6 | "kind" : "remoteSourceControl", 7 | "location" : "https://github.com/stephencelis/SQLite.swift.git", 8 | "state" : { 9 | "revision" : "4d543d811ee644fa4cc4bfa0be996b4dd6ba0f54", 10 | "version" : "0.13.3" 11 | } 12 | }, 13 | { 14 | "identity" : "swift-asn1", 15 | "kind" : "remoteSourceControl", 16 | "location" : "https://github.com/apple/swift-asn1.git", 17 | "state" : { 18 | "revision" : "7faebca1ea4f9aaf0cda1cef7c43aecd2311ddf6", 19 | "version" : "1.3.0" 20 | } 21 | }, 22 | { 23 | "identity" : "swift-crypto", 24 | "kind" : "remoteSourceControl", 25 | "location" : "https://github.com/apple/swift-crypto", 26 | "state" : { 27 | "revision" : "06dc63c6d8da54ee11ceb268cde1fa68161afc96", 28 | "version" : "3.9.1" 29 | } 30 | }, 31 | { 32 | "identity" : "swift-docc-plugin", 33 | "kind" : "remoteSourceControl", 34 | "location" : "https://github.com/apple/swift-docc-plugin", 35 | "state" : { 36 | "revision" : "3303b164430d9a7055ba484c8ead67a52f7b74f6", 37 | "version" : "1.0.0" 38 | } 39 | } 40 | ], 41 | "version" : 3 42 | } 43 | -------------------------------------------------------------------------------- /Package.swift: -------------------------------------------------------------------------------- 1 | // swift-tools-version:5.10 2 | // The swift-tools-version declares the minimum version of Swift required to build this package. 3 | 4 | import PackageDescription 5 | 6 | let package = Package( 7 | name: "Bodega", 8 | platforms: [ 9 | .iOS(.v13), 10 | .tvOS(.v13), 11 | .macOS(.v11), 12 | ], 13 | products: [ 14 | .library( 15 | name: "Bodega", 16 | targets: ["Bodega"] 17 | ), 18 | ], 19 | dependencies: [ 20 | .package(url: "https://github.com/apple/swift-crypto", from: Version(3, 9, 1)), 21 | .package(url: "https://github.com/stephencelis/SQLite.swift", from: Version(0, 13, 2)), 22 | .package(url: "https://github.com/apple/swift-docc-plugin", from: "1.0.0"), 23 | ], 24 | targets: [ 25 | .target( 26 | name: "Bodega", 27 | dependencies: [ 28 | .product(name: "Crypto", package: "swift-crypto"), 29 | .product(name: "SQLite", package: "SQLite.swift") 30 | ], 31 | swiftSettings: [ 32 | .define("ENABLE_TESTABILITY", .when(configuration: .debug)) 33 | ] 34 | ), 35 | .testTarget( 36 | name: "BodegaTests", 37 | dependencies: ["Bodega"] 38 | ), 39 | ] 40 | ) 41 | -------------------------------------------------------------------------------- /Package@swift-6.0.swift: -------------------------------------------------------------------------------- 1 | // swift-tools-version:6.0 2 | // The swift-tools-version declares the minimum version of Swift required to build this package. 3 | 4 | import PackageDescription 5 | 6 | let package = Package( 7 | name: "Bodega", 8 | platforms: [ 9 | .iOS(.v13), 10 | .tvOS(.v13), 11 | .macOS(.v11), 12 | ], 13 | products: [ 14 | .library( 15 | name: "Bodega", 16 | targets: ["Bodega"] 17 | ), 18 | ], 19 | dependencies: [ 20 | .package(url: "https://github.com/apple/swift-crypto", from: Version(3, 9, 1)), 21 | .package(url: "https://github.com/stephencelis/SQLite.swift.git", from: Version(0, 13, 2)), 22 | .package(url: "https://github.com/apple/swift-docc-plugin", from: "1.0.0"), 23 | ], 24 | targets: [ 25 | .target( 26 | name: "Bodega", 27 | dependencies: [ 28 | .product(name: "Crypto", package: "swift-crypto"), 29 | .product(name: "SQLite", package: "SQLite.swift") 30 | ], 31 | swiftSettings: [ 32 | .define("ENABLE_TESTABILITY", .when(configuration: .debug)) 33 | ] 34 | ), 35 | .testTarget( 36 | name: "BodegaTests", 37 | dependencies: ["Bodega"] 38 | ), 39 | ] 40 | ) 41 | -------------------------------------------------------------------------------- /Sources/Bodega/CacheKey.swift: -------------------------------------------------------------------------------- 1 | import Foundation 2 | 3 | /// ``CacheKey`` is a type meant to provide a stable storage key. 4 | /// If initialized from a URL the ``CacheKey`` value will generate 5 | /// a consistent UUID-formatted MD5 version of the URL string as the key 6 | /// to ensure it is file system safe. 7 | public struct CacheKey: Codable, Equatable, Hashable, Sendable { 8 | /// The `String` representation of your `CacheKey`. 9 | public let value: String 10 | 11 | /// The `String` that was passed in to any initializer, regardless of whether it was hashed afterwards or not. 12 | /// Currently this is used in ``StorageEngine``s that are not file system based 13 | /// and will be deprecated in the future, when ``CacheKey`` is [deprecated](https://github.com/mergesort/Bodega/issues/9). 14 | internal let rawValue: String 15 | 16 | /// Initializes a ``CacheKey`` from a `URL`. This initializer is useful if you plan on using 17 | /// `CacheKey`s for storing files on disk because file have many limitations about 18 | /// which characters that are allowed in file names, and the maximum length of a file name. 19 | /// - Parameter url: The URL to use as the foundation of your cache key. 20 | /// The URL will be sanitized to account for common user-generated differences 21 | /// before generating a cache key, so note that https://redpanda.club and https://www.redpanda.club 22 | /// will generate a ``CacheKey`` with the same underlying value. 23 | public init(url: URL) { 24 | self.rawValue = url.absoluteString 25 | 26 | let md5HashedURLString = Self.sanitizedURLString(url).md5 27 | self.value = md5HashedURLString.uuidFormatted ?? md5HashedURLString 28 | } 29 | 30 | /// Initializes a ``CacheKey`` from a `String`, creating a hashed version of the input `String`. 31 | /// This initializer is useful if you plan on using ``CacheKey``s for storing files on disk 32 | /// because file have many limitations about characters that are allowed in file names, 33 | /// and the maximum length of a file name. 34 | /// - Parameter value: The `String` which will serve as the underlying value for this ``CacheKey``. 35 | public init(_ value: String) { 36 | self.rawValue = value 37 | self.value = value.md5.uuidFormatted ?? value.md5 38 | } 39 | 40 | /// Initializes a ``CacheKey`` from a `String`, using the exact `String` as the value of the ``CacheKey``. 41 | /// - Parameter value: The `String` which will serve as the underlying value for this ``CacheKey``. 42 | public init(verbatim value: String) { 43 | self.rawValue = value 44 | self.value = value 45 | } 46 | } 47 | 48 | private extension CacheKey { 49 | /// A function to remove common discrepancies that do not represent differences 50 | /// a user truly intended such as URLs with trailing slashes, www, etc. 51 | /// - Parameter url: The URL to normalize 52 | /// - Returns: A normalized string 53 | static func sanitizedURLString(_ url: URL) -> String { 54 | var urlComponents = URLComponents(string: url.absoluteString) 55 | 56 | // Remove the scheme because we don't want a user saving https://www.xyz.com to clash with www.xyz.com 57 | urlComponents?.scheme = nil 58 | 59 | guard let url = urlComponents?.url else { return url.absoluteString } 60 | 61 | var normalizedURLString = url.absoluteString 62 | 63 | if normalizedURLString.hasPrefix("//") { 64 | normalizedURLString = String(normalizedURLString.dropFirst("//".count)) 65 | } 66 | 67 | if normalizedURLString.hasSuffix("/") { 68 | normalizedURLString = String(normalizedURLString.dropLast("/".count)) 69 | } 70 | 71 | normalizedURLString = normalizedURLString 72 | .replacingOccurrences(of: "www.", with: "") // Remove www so a version with/without it don't collide 73 | 74 | return normalizedURLString 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /Sources/Bodega/Documentation.docc/Articles/Fundamentals/Bodega.md: -------------------------------------------------------------------------------- 1 | # ``Bodega`` 2 | 3 | A simple store all your basic needs, and also so much more. 🐱 4 | 5 | ## Overview 6 | 7 | Bodega is an actor-based library that started as a simple cache based on reading and writing files to/from disk with an incredibly simple API. The ``DiskStorageEngine`` still provides that functionality, but Bodega has also blossomed into much more, offering a form of infrastructure that any app's data can use. 8 | 9 | Bodega's ``StorageEngine`` is at the heart of what's possible. Conforming any database, persistence layer, or even an API server, to the ``StorageEngine`` protocol automatically provides an incredibly simple data layer for your app thanks to Bodega's ``ObjectStorage``. Rather than thinking about `Data` and databases developers interact with regular ol' Swift types. You can store whatever data you want with a unified API for persistence, and concurrency handled out of the box. 10 | 11 | Bodega provides two kinds of storage primitives for you, ``StorageEngine`` and ``ObjectStorage``. ``StorageEngine`` lets you write `Data` to your data storage, whether it's files on disk, SQLite, or your own database. ``ObjectStorage`` offers a unified layer over ``StorageEngine``s, providing a single API for saving `Codable` objects to the ``StorageEngine`` of your choice. ``Bodega`` has a ``DiskStorageEngine`` and ``SQLiteStorageEngine`` built in, or you can even build a ``StorageEngine`` based on your app's persistencey layer, database, or API server if you want a simple way to interface with your API. Composing storage engines allows you to create complex data pipelines, for example imagine querying the keychain for an API token, hitting your API, and saving the resulting items into a database, all with one API call. The possibilities are endless. 12 | 13 | ## Getting Started 14 | 15 | There are numerous ways to get started with Bodega depending on how you prefer to learn. 16 | 17 | You can explore using the built-in ``SQLiteStorageEngine`` to see how to build an image cache in only a few lines of code. 18 | 19 | - 20 | 21 | The built-in ``DiskStorageEngine`` and ``SQLiteStorageEngine`` should be more than enough to handle most of the tasks iOS and macOS developers perform. It's still good to know the tradeoffs, or even when you should consider building your own ``StorageEngine``. If you want to build a ``StorageEngine`` for Core Data, the keychain, or your own custom API server, it'll be wortwhile to explore how the ``StorageEngine`` works. 22 | 23 | - 24 | 25 | Most of the time though you'll find yourself working with Swift models rather than `Data` directly, a task ``ObjectStorage`` is perfect for. Learn how to set up ``ObjectStorage``, and you'll be storing Swift types in no time. 26 | 27 | - 28 | 29 | Bodega is fully usable and useful on its own, but it's also the foundation of [Boutique](https://github.com/mergesort/Boutique). If you're looking to build a complete SwiftUI, UIKit, or AppKit app around these concepts then Boutique is a perfect fit for that problem. The library allows you to build an offline-ready realtime updating app in only a few lines of code. 30 | 31 | - [Boutique Documentation](https://build.ms/boutique/docs) 32 | 33 | ## Topics 34 | 35 | ### Fundamentals 36 | 37 | - 38 | - 39 | 40 | ### Walkthroughs 41 | 42 | - 43 | -------------------------------------------------------------------------------- /Sources/Bodega/Documentation.docc/Articles/Fundamentals/Using ObjectStorage.md: -------------------------------------------------------------------------------- 1 | # Using ObjectStorage 2 | 3 | ``ObjectStorage`` serves as unified layer over ``StorageEngine``, allowing you to work with type-safe Swift models rather than `Data`. 4 | 5 | ## Overview 6 | 7 | You can learn about the ``StorageEngine`` protocol in , but at it's most basic a ``StorageEngine`` defines functions such as `read(key: CacheKey)`, `write(data: Data, key: CacheKey)`, `remove(key: CacheKey)`, to let you read, store, and delete `Data` from your data storage mechanism. 8 | 9 | As Swift developers we're used to interacting with higher-level types rather than `Data`. Our apps include types such as `String`, `URL`, or custom models such as `Note` or `Article`. ``ObjectStorage`` allows you to read, store, and delete Swift objects, that way you don't have to think about the underlying data. 10 | 11 | ## Setting Up ObjectStorage 12 | 13 | The relationship between ``ObjectStorage`` and ``StorageEngine`` is that an ``ObjectStorage`` is initialized with a ``StorageEngine``, but the API you'll be interacting does not change no matter which ``StorageEngine`` you choose. This is very powerful because it gives us one API to work with no matter if we're saving files to disk, reading objects from a database, or even downloading models from CloudKit. To achieve this we have only one requirement for our model, it must conform to `Codable`. ``ObjectStorage`` requires `Codable` conformance so we can serialize items to their data storage, or even send them over the network. 14 | 15 | ```swift 16 | // This could be any StorageEngine, so let's use the default SQLiteStorageEngine 17 | let articlesStorageEngine = SQLiteStorageEngine.default(appendingPath: "Articles") 18 | let articlesStorage = ObjectStorage(storage: articlesStorageEngine) 19 | 20 | // Or on one line 21 | let articlesStorage = ObjectStorage
( 22 | storage: SQLiteStorageEngine.default(appendingPath: "Articles") 23 | ) 24 | ``` 25 | 26 | Now that ``ObjectStorage`` is set up, using it couldn't be simpler. The API is very similar to the ``StorageEngine`` API, but with slight function name differences to make the API feel more natural when working with Swift types rather than raw `Data`. 27 | 28 | 29 | ```swift 30 | let article = Article(title: "How To Learn Swift", text: "... and then you practice for years") 31 | 32 | // Write an article to your ObjectStorage 33 | try await articlesStorage.store(article, forKey: CacheKey("how-to-learn-swift")) 34 | 35 | // Read the article from your ObjectStorage 36 | try await storage.object(forKey: CacheKey("how-to-learn-swift")) 37 | ``` 38 | 39 | And that's it! You now have a data storage layer that can work with your app's Swift types in only a few lines of code. 40 | -------------------------------------------------------------------------------- /Sources/Bodega/Documentation.docc/Assets/ProfileHeaderview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/Sources/Bodega/Documentation.docc/Assets/ProfileHeaderview.png -------------------------------------------------------------------------------- /Sources/Bodega/Documentation.docc/Assets/StorageEngine-Read-Performance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/Sources/Bodega/Documentation.docc/Assets/StorageEngine-Read-Performance.png -------------------------------------------------------------------------------- /Sources/Bodega/Documentation.docc/Assets/StorageEngine-Write-Performance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/Sources/Bodega/Documentation.docc/Assets/StorageEngine-Write-Performance.png -------------------------------------------------------------------------------- /Sources/Bodega/Internal/String+Formatting.swift: -------------------------------------------------------------------------------- 1 | import Crypto 2 | import Foundation 3 | 4 | extension String { 5 | var md5: String { 6 | Data(self.utf8).md5.hexString 7 | } 8 | 9 | // Format characters as 8-4-4-4-12 10 | var uuidFormatted: String? { 11 | guard self.count == 32 else { return nil } 12 | 13 | var string = self.uppercased() 14 | var index = string.index(string.startIndex, offsetBy: 8) 15 | for _ in 0..<4 { 16 | string.insert("-", at: index) 17 | index = string.index(index, offsetBy: 5) 18 | } 19 | 20 | return string 21 | } 22 | } 23 | 24 | extension Data { 25 | var md5: Data { 26 | Data(Insecure.MD5.hash(data: self)) 27 | } 28 | 29 | var hexString: String { 30 | map { String(format: "%02x", $0) }.joined() 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Sources/Bodega/SQLiteStorageEngine+Default.swift: -------------------------------------------------------------------------------- 1 | public extension SQLiteStorageEngine { 2 | /// An ``SQLiteStorageEngine`` located in the platform-specific default storage directory. 3 | /// 4 | /// Equivalent to: 5 | /// `SQLiteStorageEngine(directory: .defaultStorageDirectory(appendingPath: "Data"))` 6 | static var `default`: SQLiteStorageEngine { 7 | self.default(appendingPath: "Data") 8 | } 9 | 10 | /// An ``SQLiteStorageEngine`` located in the platform-specific default storage directory. 11 | /// 12 | /// Equivalent to: 13 | /// `SQLiteStorageEngine(directory: .defaultStorageDirectory(appendingPath: "Your Path"))` 14 | /// - Parameter pathComponent: The path to append to the platform-specific defatult storage directory. 15 | static func `default`(appendingPath pathComponent: String) -> SQLiteStorageEngine { 16 | SQLiteStorageEngine(directory: .defaultStorageDirectory(appendingPath: pathComponent))! 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Tests/BodegaTests/CacheKeyTests.swift: -------------------------------------------------------------------------------- 1 | import XCTest 2 | @testable import Bodega 3 | 4 | final class CacheKeyTests: XCTestCase { 5 | func testCacheKeyValues() { 6 | let cacheKey = CacheKey(verbatim: "cache-key") 7 | let hashedCacheKey = CacheKey("cache-key") 8 | let hashedCacheKeyValue = "2536A137-81F3-3E55-574F-AFF9ACB9F995" 9 | 10 | XCTAssertEqual(hashedCacheKey.value, hashedCacheKeyValue) 11 | XCTAssertEqual(cacheKey.value, "cache-key") 12 | } 13 | 14 | func testCacheKeyURLHashing() { 15 | let redPandaClubHash = "37E97C2D-25C0-19AE-755D-FC39211AEE32" 16 | let url = URL(string: "https://www.redpanda.club")! 17 | let cacheKey = CacheKey(url: url) 18 | 19 | XCTAssertEqual(cacheKey.value, redPandaClubHash) 20 | 21 | let dummyHash = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" 22 | XCTAssertNotEqual(cacheKey.value, dummyHash) 23 | } 24 | 25 | func testCacheKeyRawValue() { 26 | let urlString = "https://www.redpanda.club" 27 | let url = URL(string: urlString)! 28 | 29 | let urlInitializedCacheKey = CacheKey(url: url) 30 | let stringInitializedCacheKey = CacheKey(urlString) 31 | let verbatimInitializedCacheKey = CacheKey(verbatim: urlString) 32 | 33 | XCTAssertEqual(urlInitializedCacheKey.rawValue, urlString) 34 | XCTAssertEqual(stringInitializedCacheKey.rawValue, urlString) 35 | XCTAssertEqual(verbatimInitializedCacheKey.rawValue, urlString) 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /Tests/BodegaTests/String+FormattingTests.swift: -------------------------------------------------------------------------------- 1 | import XCTest 2 | @testable import Bodega 3 | 4 | final class StringFormattingTests: XCTestCase { 5 | func testCacheKeyURLHashing() { 6 | let redPandaClubHash = "37E97C2D-25C0-19AE-755D-FC39211AEE32" 7 | let url = URL(string: "https://www.redpanda.club")! 8 | let cacheKey = CacheKey(url: url) 9 | 10 | XCTAssertEqual(cacheKey.value, redPandaClubHash) 11 | 12 | let dummyHash = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" 13 | XCTAssertNotEqual(cacheKey.value, dummyHash) 14 | } 15 | 16 | func testMD5Hash() { 17 | let md5123 = "123".md5 18 | let md5ABC = "abc".md5 19 | 20 | XCTAssertEqual(md5ABC, "900150983cd24fb0d6963f7d28e17f72") 21 | XCTAssertEqual(md5123, "202cb962ac59075b964b07152d234b70") 22 | } 23 | 24 | func testUUIDFormatting() { 25 | let preformattedUUIDString = "37E97C2D25C019AE755DFC39211AEE32".uuidFormatted 26 | 27 | XCTAssertEqual(preformattedUUIDString, "37E97C2D-25C0-19AE-755D-FC39211AEE32") 28 | XCTAssertNotEqual(preformattedUUIDString, "37E97C2D25C019AE755DFC39211AEE32") 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /docs/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/docs/.gitkeep -------------------------------------------------------------------------------- /docs/data/documentation/bodega/cachekey/!=(_:_:).json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"static"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"!="},{"kind":"text","text":" "},{"kind":"text","text":"("},{"kind":"internalParam","text":"lhs"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":", "},{"kind":"internalParam","text":"rhs"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":") -> "},{"kind":"typeIdentifier","text":"Bool","preciseIdentifier":"s:Sb"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/cachekey\/!=(_:_:)"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/!=(_:_:)","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Inherited from "},{"type":"codeVoice","code":"Equatable.!=(_:_:)"},{"type":"text","text":"."}],"kind":"symbol","metadata":{"role":"symbol","title":"!=(_:_:)","roleHeading":"Operator","fragments":[{"kind":"keyword","text":"static"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"!="},{"kind":"text","text":" "},{"kind":"text","text":"("},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":", "},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":") -> "},{"kind":"typeIdentifier","text":"Bool","preciseIdentifier":"s:Sb"}],"symbolKind":"op","externalID":"s:SQsE2neoiySbx_xtFZ::SYNTHESIZED::s:6Bodega8CacheKeyV","extendedModule":"Swift","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/Equatable-Implementations"]]},"references":{"doc://Bodega/documentation/Bodega/CacheKey/Equatable-Implementations":{"role":"collectionGroup","title":"Equatable Implementations","abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/Equatable-Implementations","kind":"article","type":"topic","url":"\/documentation\/bodega\/cachekey\/equatable-implementations"},"doc://Bodega/documentation/Bodega/CacheKey/!=(_:_:)":{"role":"symbol","title":"!=(_:_:)","fragments":[{"kind":"keyword","text":"static"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"!="},{"kind":"text","text":" "},{"kind":"text","text":"("},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":", "},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":") -> "},{"kind":"typeIdentifier","text":"Bool","preciseIdentifier":"s:Sb"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/!=(_:_:)","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/cachekey\/!=(_:_:)"},"doc://Bodega/documentation/Bodega/CacheKey":{"role":"symbol","title":"CacheKey","fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"CacheKey"}],"abstract":[{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" is a type meant to provide a stable storage key."},{"type":"text","text":" "},{"type":"text","text":"If initialized from a URL the "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" value will generate"},{"type":"text","text":" "},{"type":"text","text":"a consistent UUID-formatted MD5 version of the URL string as the key"},{"type":"text","text":" "},{"type":"text","text":"to ensure it is file system safe."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"CacheKey"}],"url":"\/documentation\/bodega\/cachekey"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/cachekey/equatable-implementations.json: -------------------------------------------------------------------------------- 1 | {"variants":[{"paths":["\/documentation\/bodega\/cachekey\/equatable-implementations"],"traits":[{"interfaceLanguage":"swift"}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/Equatable-Implementations","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"No overview available."}],"kind":"article","metadata":{"modules":[{"name":"Bodega"}],"role":"collectionGroup","title":"Equatable Implementations"},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"]]},"topicSections":[{"title":"Operators","identifiers":["doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/!=(_:_:)"],"generated":true}],"references":{"doc://Bodega/documentation/Bodega/CacheKey/!=(_:_:)":{"role":"symbol","title":"!=(_:_:)","fragments":[{"kind":"keyword","text":"static"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"!="},{"kind":"text","text":" "},{"kind":"text","text":"("},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":", "},{"kind":"typeIdentifier","text":"Self"},{"kind":"text","text":") -> "},{"kind":"typeIdentifier","text":"Bool","preciseIdentifier":"s:Sb"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/!=(_:_:)","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/cachekey\/!=(_:_:)"},"doc://Bodega/documentation/Bodega/CacheKey":{"role":"symbol","title":"CacheKey","fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"CacheKey"}],"abstract":[{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" is a type meant to provide a stable storage key."},{"type":"text","text":" "},{"type":"text","text":"If initialized from a URL the "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" value will generate"},{"type":"text","text":" "},{"type":"text","text":"a consistent UUID-formatted MD5 version of the URL string as the key"},{"type":"text","text":" "},{"type":"text","text":"to ensure it is file system safe."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"CacheKey"}],"url":"\/documentation\/bodega\/cachekey"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/cachekey/init(from:).json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"init"},{"kind":"text","text":"("},{"kind":"externalParam","text":"from"},{"kind":"text","text":" "},{"kind":"internalParam","text":"decoder"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Decoder","preciseIdentifier":"s:s7DecoderP"},{"kind":"text","text":") "},{"kind":"keyword","text":"throws"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/cachekey\/init(from:)"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/init(from:)","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Inherited from "},{"type":"codeVoice","code":"Decodable.init(from:)"},{"type":"text","text":"."}],"kind":"symbol","metadata":{"fragments":[{"kind":"identifier","text":"init"},{"kind":"text","text":"("},{"kind":"externalParam","text":"from"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Decoder","preciseIdentifier":"s:s7DecoderP"},{"kind":"text","text":") "},{"kind":"keyword","text":"throws"}],"title":"init(from:)","roleHeading":"Initializer","role":"symbol","symbolKind":"init","externalID":"s:6Bodega8CacheKeyV4fromACs7Decoder_p_tKcfc","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"]]},"references":{"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/CacheKey/init(from:)":{"role":"symbol","title":"init(from:)","fragments":[{"kind":"identifier","text":"init"},{"kind":"text","text":"("},{"kind":"externalParam","text":"from"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Decoder","preciseIdentifier":"s:s7DecoderP"},{"kind":"text","text":") "},{"kind":"keyword","text":"throws"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/init(from:)","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/cachekey\/init(from:)"},"doc://Bodega/documentation/Bodega/CacheKey":{"role":"symbol","title":"CacheKey","fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"CacheKey"}],"abstract":[{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" is a type meant to provide a stable storage key."},{"type":"text","text":" "},{"type":"text","text":"If initialized from a URL the "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" value will generate"},{"type":"text","text":" "},{"type":"text","text":"a consistent UUID-formatted MD5 version of the URL string as the key"},{"type":"text","text":" "},{"type":"text","text":"to ensure it is file system safe."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"CacheKey"}],"url":"\/documentation\/bodega\/cachekey"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/cachekey/value.json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"let"},{"kind":"text","text":" "},{"kind":"identifier","text":"value"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"String","preciseIdentifier":"s:SS"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/cachekey\/value"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/value","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"The "},{"type":"codeVoice","code":"String"},{"type":"text","text":" representation of your "},{"type":"codeVoice","code":"CacheKey"},{"type":"text","text":"."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"let"},{"kind":"text","text":" "},{"kind":"identifier","text":"value"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"String","preciseIdentifier":"s:SS"}],"title":"value","roleHeading":"Instance Property","role":"symbol","symbolKind":"property","externalID":"s:6Bodega8CacheKeyV5valueSSvp","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"]]},"references":{"doc://Bodega/documentation/Bodega/CacheKey/value":{"role":"symbol","title":"value","fragments":[{"kind":"keyword","text":"let"},{"kind":"text","text":" "},{"kind":"identifier","text":"value"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"String","preciseIdentifier":"s:SS"}],"abstract":[{"type":"text","text":"The "},{"type":"codeVoice","code":"String"},{"type":"text","text":" representation of your "},{"type":"codeVoice","code":"CacheKey"},{"type":"text","text":"."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey\/value","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/cachekey\/value"},"doc://Bodega/documentation/Bodega/CacheKey":{"role":"symbol","title":"CacheKey","fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"CacheKey"}],"abstract":[{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" is a type meant to provide a stable storage key."},{"type":"text","text":" "},{"type":"text","text":"If initialized from a URL the "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" value will generate"},{"type":"text","text":" "},{"type":"text","text":"a consistent UUID-formatted MD5 version of the URL string as the key"},{"type":"text","text":" "},{"type":"text","text":"to ensure it is file system safe."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"CacheKey"}],"url":"\/documentation\/bodega\/cachekey"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/diskstorageengine/keycount().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"anchor":"return-value","level":2,"type":"heading","text":"Return Value"},{"type":"paragraph","inlineContent":[{"type":"text","text":"The file\/key count."}]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/diskstorageengine\/keycount()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine\/keyCount()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Iterates through a directory to find the total number of "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"title":"keyCount()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega17DiskStorageEngineC8keyCountSiyF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/DiskStorageEngine/keyCount()":{"role":"symbol","title":"keyCount()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"abstract":[{"type":"text","text":"Iterates through a directory to find the total number of "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine\/keyCount()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/diskstorageengine\/keycount()"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/DiskStorageEngine":{"role":"symbol","title":"DiskStorageEngine","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"DiskStorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" based on saving items to the file system."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"DiskStorageEngine"}],"url":"\/documentation\/bodega\/diskstorageengine"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/diskstorageengine/readalldata().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"anchor":"return-value","level":2,"type":"heading","text":"Return Value"},{"type":"paragraph","inlineContent":[{"type":"text","text":"An array of the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" contained on disk."}]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/diskstorageengine\/readalldata()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine\/readAllData()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Reads all the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" located in the "},{"type":"codeVoice","code":"directory"},{"type":"text","text":"."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"title":"readAllData()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega17DiskStorageEngineC11readAllDataSay10Foundation0G0VGyYaF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/DiskStorageEngine":{"role":"symbol","title":"DiskStorageEngine","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"DiskStorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" based on saving items to the file system."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"DiskStorageEngine"}],"url":"\/documentation\/bodega\/diskstorageengine"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega/DiskStorageEngine/readAllData()":{"role":"symbol","title":"readAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"abstract":[{"type":"text","text":"Reads all the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" located in the "},{"type":"codeVoice","code":"directory"},{"type":"text","text":"."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine\/readAllData()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/diskstorageengine\/readalldata()"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/diskstorageengine/removealldata().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/diskstorageengine\/removealldata()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine\/removeAllData()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Removes all the "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items located in the "},{"type":"codeVoice","code":"directory"},{"type":"text","text":"."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"}],"title":"removeAllData()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega17DiskStorageEngineC13removeAllDatayyKF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/DiskStorageEngine":{"role":"symbol","title":"DiskStorageEngine","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"DiskStorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" based on saving items to the file system."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"DiskStorageEngine"}],"url":"\/documentation\/bodega\/diskstorageengine"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega/DiskStorageEngine/removeAllData()":{"role":"symbol","title":"removeAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"}],"abstract":[{"type":"text","text":"Removes all the "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items located in the "},{"type":"codeVoice","code":"directory"},{"type":"text","text":"."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/DiskStorageEngine\/removeAllData()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/diskstorageengine\/removealldata()"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/objectstorage/allobjects().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"allObjects"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Object"},{"kind":"text","text":"]"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"anchor":"return-value","level":2,"type":"heading","text":"Return Value"},{"type":"paragraph","inlineContent":[{"type":"text","text":"An array of "},{"type":"codeVoice","code":"[Object]"},{"type":"text","text":"s contained in a directory."}]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/objectstorage\/allobjects()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage\/allObjects()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Reads all "},{"type":"codeVoice","code":"[Object]"},{"type":"text","text":" objects."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"allObjects"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Object"},{"kind":"text","text":"]"}],"title":"allObjects()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega13ObjectStorageC10allObjectsSayxGyYaF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage"]]},"references":{"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega/ObjectStorage/allObjects()":{"role":"symbol","title":"allObjects()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"allObjects"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Object"},{"kind":"text","text":"]"}],"abstract":[{"type":"text","text":"Reads all "},{"type":"codeVoice","code":"[Object]"},{"type":"text","text":" objects."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage\/allObjects()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/objectstorage\/allobjects()"},"doc://Bodega/documentation/Bodega/ObjectStorage":{"role":"symbol","title":"ObjectStorage","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"ObjectStorage"}],"abstract":[{"type":"text","text":"A unified layer over a "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" primitives, allowing you to read, write, and save Swift objects."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"ObjectStorage"}],"url":"\/documentation\/bodega\/objectstorage"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/objectstorage/keycount().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"anchor":"return-value","level":2,"type":"heading","text":"Return Value"},{"type":"paragraph","inlineContent":[{"type":"text","text":"The object\/key count."}]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/objectstorage\/keycount()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage\/keyCount()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Iterates through a directory to find the total number of objects."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"title":"keyCount()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega13ObjectStorageC8keyCountSiyYaF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage"]]},"references":{"doc://Bodega/documentation/Bodega/ObjectStorage":{"role":"symbol","title":"ObjectStorage","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"ObjectStorage"}],"abstract":[{"type":"text","text":"A unified layer over a "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" primitives, allowing you to read, write, and save Swift objects."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"ObjectStorage"}],"url":"\/documentation\/bodega\/objectstorage"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/ObjectStorage/keyCount()":{"role":"symbol","title":"keyCount()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"abstract":[{"type":"text","text":"Iterates through a directory to find the total number of objects."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage\/keyCount()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/objectstorage\/keycount()"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/objectstorage/removeallobjects().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllObjects"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/objectstorage\/removeallobjects()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage\/removeAllObjects()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Removes all of the "},{"type":"codeVoice","code":"Object"},{"type":"text","text":"s."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllObjects"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"}],"title":"removeAllObjects()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega13ObjectStorageC16removeAllObjectsyyYaKF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage"]]},"references":{"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/ObjectStorage":{"role":"symbol","title":"ObjectStorage","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"ObjectStorage"}],"abstract":[{"type":"text","text":"A unified layer over a "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" primitives, allowing you to read, write, and save Swift objects."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"ObjectStorage"}],"url":"\/documentation\/bodega\/objectstorage"},"doc://Bodega/documentation/Bodega/ObjectStorage/removeAllObjects()":{"role":"symbol","title":"removeAllObjects()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllObjects"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"}],"abstract":[{"type":"text","text":"Removes all of the "},{"type":"codeVoice","code":"Object"},{"type":"text","text":"s."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/ObjectStorage\/removeAllObjects()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/objectstorage\/removeallobjects()"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/sqlitestorageengine/keycount().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"anchor":"return-value","level":2,"type":"heading","text":"Return Value"},{"type":"paragraph","inlineContent":[{"type":"text","text":"The file\/key count."}]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/sqlitestorageengine\/keycount()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine\/keyCount()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Iterates through the database to find the total number of "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"title":"keyCount()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega19SQLiteStorageEngineC8keyCountSiyF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/SQLiteStorageEngine/keyCount()":{"role":"symbol","title":"keyCount()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"abstract":[{"type":"text","text":"Iterates through the database to find the total number of "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine\/keyCount()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/sqlitestorageengine\/keycount()"},"doc://Bodega/documentation/Bodega/SQLiteStorageEngine":{"role":"symbol","title":"SQLiteStorageEngine","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"SQLiteStorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" based on an SQLite database."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"SQLiteStorageEngine"}],"url":"\/documentation\/bodega\/sqlitestorageengine"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/sqlitestorageengine/readalldata().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"anchor":"return-value","level":2,"type":"heading","text":"Return Value"},{"type":"paragraph","inlineContent":[{"type":"text","text":"An array of the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" contained in the database."}]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/sqlitestorageengine\/readalldata()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine\/readAllData()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Reads all the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" located in the database."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"title":"readAllData()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega19SQLiteStorageEngineC11readAllDataSay10Foundation0G0VGyF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/SQLiteStorageEngine/readAllData()":{"role":"symbol","title":"readAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"abstract":[{"type":"text","text":"Reads all the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" located in the database."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine\/readAllData()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/sqlitestorageengine\/readalldata()"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega/SQLiteStorageEngine":{"role":"symbol","title":"SQLiteStorageEngine","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"SQLiteStorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" based on an SQLite database."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"SQLiteStorageEngine"}],"url":"\/documentation\/bodega\/sqlitestorageengine"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/sqlitestorageengine/removealldata().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/sqlitestorageengine\/removealldata()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine\/removeAllData()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Removes all the "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items from the database."}],"kind":"symbol","metadata":{"fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"}],"title":"removeAllData()","roleHeading":"Instance Method","role":"symbol","symbolKind":"method","externalID":"s:6Bodega19SQLiteStorageEngineC13removeAllDatayyKF","modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/SQLiteStorageEngine/removeAllData()":{"role":"symbol","title":"removeAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"}],"abstract":[{"type":"text","text":"Removes all the "},{"type":"codeVoice","code":"Data"},{"type":"text","text":" items from the database."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine\/removeAllData()","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/sqlitestorageengine\/removealldata()"},"doc://Bodega/documentation/Bodega/SQLiteStorageEngine":{"role":"symbol","title":"SQLiteStorageEngine","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"SQLiteStorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" based on an SQLite database."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/SQLiteStorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"SQLiteStorageEngine"}],"url":"\/documentation\/bodega\/sqlitestorageengine"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/storageengine/allkeys().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"allKeys"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","preciseIdentifier":"s:6Bodega8CacheKeyV","text":"CacheKey"},{"kind":"text","text":"]"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/storageengine\/allkeys()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/allKeys()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"No overview available."}],"kind":"symbol","metadata":{"role":"symbol","title":"allKeys()","roleHeading":"Instance Method","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"allKeys"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"CacheKey","preciseIdentifier":"s:6Bodega8CacheKeyV"},{"kind":"text","text":"]"}],"symbolKind":"method","externalID":"s:6Bodega13StorageEngineP7allKeysSayAA8CacheKeyVGyYaF","required":true,"modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega/StorageEngine/allKeys()":{"role":"symbol","title":"allKeys()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"allKeys"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"CacheKey","preciseIdentifier":"s:6Bodega8CacheKeyV"},{"kind":"text","text":"]"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/allKeys()","kind":"symbol","required":true,"type":"topic","url":"\/documentation\/bodega\/storageengine\/allkeys()"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/CacheKey":{"role":"symbol","title":"CacheKey","fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"CacheKey"}],"abstract":[{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" is a type meant to provide a stable storage key."},{"type":"text","text":" "},{"type":"text","text":"If initialized from a URL the "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey"},{"type":"text","text":" value will generate"},{"type":"text","text":" "},{"type":"text","text":"a consistent UUID-formatted MD5 version of the URL string as the key"},{"type":"text","text":" "},{"type":"text","text":"to ensure it is file system safe."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/CacheKey","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"CacheKey"}],"url":"\/documentation\/bodega\/cachekey"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/storageengine/keycount().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/storageengine\/keycount()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/keyCount()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"No overview available."}],"kind":"symbol","metadata":{"role":"symbol","title":"keyCount()","roleHeading":"Instance Method","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"symbolKind":"method","externalID":"s:6Bodega13StorageEngineP8keyCountSiyYaF","required":true,"modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"},"doc://Bodega/documentation/Bodega/StorageEngine/keyCount()":{"role":"symbol","title":"keyCount()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"keyCount"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Int","preciseIdentifier":"s:Si"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/keyCount()","kind":"symbol","required":true,"type":"topic","url":"\/documentation\/bodega\/storageengine\/keycount()"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/storageengine/readalldata()-1gzc6.json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/storageengine\/readalldata()-1gzc6"],"traits":[{"interfaceLanguage":"swift"}]}],"defaultImplementationsSections":[{"title":"StorageEngine Implementations","identifiers":["doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/readAllData()-56p4o"]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/readAllData()-1gzc6","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"No overview available."}],"kind":"symbol","metadata":{"role":"symbol","title":"readAllData()","roleHeading":"Instance Method","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"symbolKind":"method","externalID":"s:6Bodega13StorageEngineP11readAllDataSay10Foundation0F0VGyYaF","required":true,"modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/StorageEngine/readAllData()-56p4o":{"role":"symbol","title":"readAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"abstract":[{"type":"text","text":"Reads all the "},{"type":"codeVoice","code":"[Data]"},{"type":"text","text":" located in the "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":"."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/readAllData()-56p4o","kind":"symbol","type":"topic","url":"\/documentation\/bodega\/storageengine\/readalldata()-56p4o"},"doc://Bodega/documentation/Bodega/StorageEngine/readAllData()-1gzc6":{"defaultImplementations":1,"role":"symbol","title":"readAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"readAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" -> ["},{"kind":"typeIdentifier","text":"Data","preciseIdentifier":"s:10Foundation4DataV"},{"kind":"text","text":"]"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/readAllData()-1gzc6","kind":"symbol","required":true,"type":"topic","url":"\/documentation\/bodega\/storageengine\/readalldata()-1gzc6"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"}}} -------------------------------------------------------------------------------- /docs/data/documentation/bodega/storageengine/removealldata().json: -------------------------------------------------------------------------------- 1 | {"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"}],"languages":["swift"],"platforms":["macOS"]}]}],"schemaVersion":{"major":0,"minor":2,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/bodega\/storageengine\/removealldata()"],"traits":[{"interfaceLanguage":"swift"}]}],"identifier":{"url":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/removeAllData()","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"No overview available."}],"kind":"symbol","metadata":{"role":"symbol","title":"removeAllData()","roleHeading":"Instance Method","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"}],"symbolKind":"method","externalID":"s:6Bodega13StorageEngineP13removeAllDatayyYaKF","required":true,"modules":[{"name":"Bodega"}]},"hierarchy":{"paths":[["doc:\/\/Bodega\/documentation\/Bodega","doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"]]},"references":{"doc://Bodega/documentation/Bodega/StorageEngine/removeAllData()":{"role":"symbol","title":"removeAllData()","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"removeAllData"},{"kind":"text","text":"() "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"}],"abstract":[],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine\/removeAllData()","kind":"symbol","required":true,"type":"topic","url":"\/documentation\/bodega\/storageengine\/removealldata()"},"doc://Bodega/documentation/Bodega":{"role":"collection","title":"Bodega","abstract":[{"type":"text","text":"A simple store all your basic needs, and also so much more. 🐱"}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega","kind":"symbol","type":"topic","url":"\/documentation\/bodega"},"doc://Bodega/documentation/Bodega/StorageEngine":{"role":"symbol","title":"StorageEngine","fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"StorageEngine"}],"abstract":[{"type":"text","text":"A "},{"type":"reference","isActive":true,"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine"},{"type":"text","text":" represents a data storage mechanism for saving and persisting data."}],"identifier":"doc:\/\/Bodega\/documentation\/Bodega\/StorageEngine","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"StorageEngine"}],"url":"\/documentation\/bodega\/storageengine"}}} -------------------------------------------------------------------------------- /docs/documentation/bodega/building-an-image-cache/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/!=(_:_:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/init(_:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/init(from:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/init(url:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/init(verbatim:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/cachekey/value/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/diskstorageengine/allkeys()/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/diskstorageengine/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/diskstorageengine/write(_:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/objectstorage/allkeys()/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/objectstorage/allobjects()/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/objectstorage/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/objectstorage/keycount()/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/objectstorage/store(_:)/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/sqlitestorageengine/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/storageengine/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/using-objectstorage/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/documentation/bodega/using-storageengines/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/docs/favicon.ico -------------------------------------------------------------------------------- /docs/favicon.svg: -------------------------------------------------------------------------------- 1 | 10 | 11 | -------------------------------------------------------------------------------- /docs/images/ProfileHeaderview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/docs/images/ProfileHeaderview.png -------------------------------------------------------------------------------- /docs/images/StorageEngine-Read-Performance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/docs/images/StorageEngine-Read-Performance.png -------------------------------------------------------------------------------- /docs/images/StorageEngine-Write-Performance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mergesort/Bodega/4d337e8b0a189bba7e832aa21e012538680ba89e/docs/images/StorageEngine-Write-Performance.png -------------------------------------------------------------------------------- /docs/img/added-icon.d6f7e47d.svg: -------------------------------------------------------------------------------- 1 | 10 | 11 | -------------------------------------------------------------------------------- /docs/img/deprecated-icon.015b4f17.svg: -------------------------------------------------------------------------------- 1 | 10 | 11 | -------------------------------------------------------------------------------- /docs/img/modified-icon.f496e73d.svg: -------------------------------------------------------------------------------- 1 | 10 | 11 | -------------------------------------------------------------------------------- /docs/index.html: -------------------------------------------------------------------------------- 1 | 10 | 11 | Documentation
-------------------------------------------------------------------------------- /docs/js/highlight-js-bash.1b52852f.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-bash"],{f0f8:function(e,s){function t(e){const s=e.regex,t={},n={begin:/\$\{/,end:/\}/,contains:["self",{begin:/:-/,contains:[t]}]};Object.assign(t,{className:"variable",variants:[{begin:s.concat(/\$[\w\d#@][\w\d_]*/,"(?![\\w\\d])(?![$])")},n]});const a={className:"subst",begin:/\$\(/,end:/\)/,contains:[e.BACKSLASH_ESCAPE]},i={begin:/<<-?\s*(?=\w+)/,starts:{contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,className:"string"})]}},c={className:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,t,a]};a.contains.push(c);const o={className:"",begin:/\\"/},r={className:"string",begin:/'/,end:/'/},l={begin:/\$\(\(/,end:/\)\)/,contains:[{begin:/\d+#[0-9a-f]+/,className:"number"},e.NUMBER_MODE,t]},p=["fish","bash","zsh","sh","csh","ksh","tcsh","dash","scsh"],d=e.SHEBANG({binary:`(${p.join("|")})`,relevance:10}),h={className:"function",begin:/\w[\w\d_]*\s*\(\s*\)\s*\{/,returnBegin:!0,contains:[e.inherit(e.TITLE_MODE,{begin:/\w[\w\d_]*/})],relevance:0},m=["if","then","else","elif","fi","for","while","in","do","done","case","esac","function"],u=["true","false"],b={match:/(\/[a-z._-]+)+/},g=["break","cd","continue","eval","exec","exit","export","getopts","hash","pwd","readonly","return","shift","test","times","trap","umask","unset"],f=["alias","bind","builtin","caller","command","declare","echo","enable","help","let","local","logout","mapfile","printf","read","readarray","source","type","typeset","ulimit","unalias"],w=["autoload","bg","bindkey","bye","cap","chdir","clone","comparguments","compcall","compctl","compdescribe","compfiles","compgroups","compquote","comptags","comptry","compvalues","dirs","disable","disown","echotc","echoti","emulate","fc","fg","float","functions","getcap","getln","history","integer","jobs","kill","limit","log","noglob","popd","print","pushd","pushln","rehash","sched","setcap","setopt","stat","suspend","ttyctl","unfunction","unhash","unlimit","unsetopt","vared","wait","whence","where","which","zcompile","zformat","zftp","zle","zmodload","zparseopts","zprof","zpty","zregexparse","zsocket","zstyle","ztcp"],k=["chcon","chgrp","chown","chmod","cp","dd","df","dir","dircolors","ln","ls","mkdir","mkfifo","mknod","mktemp","mv","realpath","rm","rmdir","shred","sync","touch","truncate","vdir","b2sum","base32","base64","cat","cksum","comm","csplit","cut","expand","fmt","fold","head","join","md5sum","nl","numfmt","od","paste","ptx","pr","sha1sum","sha224sum","sha256sum","sha384sum","sha512sum","shuf","sort","split","sum","tac","tail","tr","tsort","unexpand","uniq","wc","arch","basename","chroot","date","dirname","du","echo","env","expr","factor","groups","hostid","id","link","logname","nice","nohup","nproc","pathchk","pinky","printenv","printf","pwd","readlink","runcon","seq","sleep","stat","stdbuf","stty","tee","test","timeout","tty","uname","unlink","uptime","users","who","whoami","yes"];return{name:"Bash",aliases:["sh"],keywords:{$pattern:/\b[a-z._-]+\b/,keyword:m,literal:u,built_in:[...g,...f,"set","shopt",...w,...k]},contains:[d,e.SHEBANG(),h,l,e.HASH_COMMENT_MODE,i,b,c,o,r,t]}}e.exports=t}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-c.d1db3f17.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-c"],{"1fe5":function(e,n){function s(e){const n=e.regex,s=e.COMMENT("//","$",{contains:[{begin:/\\\n/}]}),t="decltype\\(auto\\)",a="[a-zA-Z_]\\w*::",i="<[^<>]+>",r="("+t+"|"+n.optional(a)+"[a-zA-Z_]\\w*"+n.optional(i)+")",l={className:"type",variants:[{begin:"\\b[a-z\\d_]*_t\\b"},{match:/\batomic_[a-z]{3,6}\b/}]},o="\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4,8}|[0-7]{3}|\\S)",c={className:"string",variants:[{begin:'(u8?|U|L)?"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},{begin:"(u8?|U|L)?'("+o+"|.)",end:"'",illegal:"."},e.END_SAME_AS_BEGIN({begin:/(?:u8?|U|L)?R"([^()\\ ]{0,16})\(/,end:/\)([^()\\ ]{0,16})"/})]},d={className:"number",variants:[{begin:"\\b(0b[01']+)"},{begin:"(-?)\\b([\\d']+(\\.[\\d']*)?|\\.[\\d']+)((ll|LL|l|L)(u|U)?|(u|U)(ll|LL|l|L)?|f|F|b|B)"},{begin:"(-?)(\\b0[xX][a-fA-F0-9']+|(\\b[\\d']+(\\.[\\d']*)?|\\.[\\d']+)([eE][-+]?[\\d']+)?)"}],relevance:0},u={className:"meta",begin:/#\s*[a-z]+\b/,end:/$/,keywords:{keyword:"if else elif endif define undef warning error line pragma _Pragma ifdef ifndef include"},contains:[{begin:/\\\n/,relevance:0},e.inherit(c,{className:"string"}),{className:"string",begin:/<.*?>/},s,e.C_BLOCK_COMMENT_MODE]},g={className:"title",begin:n.optional(a)+e.IDENT_RE,relevance:0},p=n.optional(a)+e.IDENT_RE+"\\s*\\(",m=["asm","auto","break","case","continue","default","do","else","enum","extern","for","fortran","goto","if","inline","register","restrict","return","sizeof","struct","switch","typedef","union","volatile","while","_Alignas","_Alignof","_Atomic","_Generic","_Noreturn","_Static_assert","_Thread_local","alignas","alignof","noreturn","static_assert","thread_local","_Pragma"],_=["float","double","signed","unsigned","int","short","long","char","void","_Bool","_Complex","_Imaginary","_Decimal32","_Decimal64","_Decimal128","const","static","complex","bool","imaginary"],f={keyword:m,type:_,literal:"true false NULL",built_in:"std string wstring cin cout cerr clog stdin stdout stderr stringstream istringstream ostringstream auto_ptr deque list queue stack vector map set pair bitset multiset multimap unordered_set unordered_map unordered_multiset unordered_multimap priority_queue make_pair array shared_ptr abort terminate abs acos asin atan2 atan calloc ceil cosh cos exit exp fabs floor fmod fprintf fputs free frexp fscanf future isalnum isalpha iscntrl isdigit isgraph islower isprint ispunct isspace isupper isxdigit tolower toupper labs ldexp log10 log malloc realloc memchr memcmp memcpy memset modf pow printf putchar puts scanf sinh sin snprintf sprintf sqrt sscanf strcat strchr strcmp strcpy strcspn strlen strncat strncmp strncpy strpbrk strrchr strspn strstr tanh tan vfprintf vprintf vsprintf endl initializer_list unique_ptr"},b=[u,l,s,e.C_BLOCK_COMMENT_MODE,d,c],w={variants:[{begin:/=/,end:/;/},{begin:/\(/,end:/\)/},{beginKeywords:"new throw return else",end:/;/}],keywords:f,contains:b.concat([{begin:/\(/,end:/\)/,keywords:f,contains:b.concat(["self"]),relevance:0}]),relevance:0},h={begin:"("+r+"[\\*&\\s]+)+"+p,returnBegin:!0,end:/[{;=]/,excludeEnd:!0,keywords:f,illegal:/[^\w\s\*&:<>.]/,contains:[{begin:t,keywords:f,relevance:0},{begin:p,returnBegin:!0,contains:[e.inherit(g,{className:"title.function"})],relevance:0},{relevance:0,match:/,/},{className:"params",begin:/\(/,end:/\)/,keywords:f,relevance:0,contains:[s,e.C_BLOCK_COMMENT_MODE,c,d,l,{begin:/\(/,end:/\)/,keywords:f,relevance:0,contains:["self",s,e.C_BLOCK_COMMENT_MODE,c,d,l]}]},l,s,e.C_BLOCK_COMMENT_MODE,u]};return{name:"C",aliases:["h"],keywords:f,disableAutodetect:!0,illegal:"=]/,contains:[{beginKeywords:"final class struct"},e.TITLE_MODE]}]),exports:{preprocessor:u,strings:c,keywords:f}}}e.exports=s}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-custom-markdown.7cffc4b3.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-custom-markdown","highlight-js-markdown"],{"04b0":function(n,e){function a(n){const e=n.regex,a={begin:/<\/?[A-Za-z_]/,end:">",subLanguage:"xml",relevance:0},i={begin:"^[-\\*]{3,}",end:"$"},s={className:"code",variants:[{begin:"(`{3,})[^`](.|\\n)*?\\1`*[ ]*"},{begin:"(~{3,})[^~](.|\\n)*?\\1~*[ ]*"},{begin:"```",end:"```+[ ]*$"},{begin:"~~~",end:"~~~+[ ]*$"},{begin:"`.+?`"},{begin:"(?=^( {4}|\\t))",contains:[{begin:"^( {4}|\\t)",end:"(\\n)$"}],relevance:0}]},t={className:"bullet",begin:"^[ \t]*([*+-]|(\\d+\\.))(?=\\s+)",end:"\\s+",excludeEnd:!0},c={begin:/^\[[^\n]+\]:/,returnBegin:!0,contains:[{className:"symbol",begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0},{className:"link",begin:/:\s*/,end:/$/,excludeBegin:!0}]},d=/[A-Za-z][A-Za-z0-9+.-]*/,l={variants:[{begin:/\[.+?\]\[.*?\]/,relevance:0},{begin:/\[.+?\]\(((data|javascript|mailto):|(?:http|ftp)s?:\/\/).*?\)/,relevance:2},{begin:e.concat(/\[.+?\]\(/,d,/:\/\/.*?\)/),relevance:2},{begin:/\[.+?\]\([./?&#].*?\)/,relevance:1},{begin:/\[.*?\]\(.*?\)/,relevance:0}],returnBegin:!0,contains:[{match:/\[(?=\])/},{className:"string",relevance:0,begin:"\\[",end:"\\]",excludeBegin:!0,returnEnd:!0},{className:"link",relevance:0,begin:"\\]\\(",end:"\\)",excludeBegin:!0,excludeEnd:!0},{className:"symbol",relevance:0,begin:"\\]\\[",end:"\\]",excludeBegin:!0,excludeEnd:!0}]},g={className:"strong",contains:[],variants:[{begin:/_{2}/,end:/_{2}/},{begin:/\*{2}/,end:/\*{2}/}]},o={className:"emphasis",contains:[],variants:[{begin:/\*(?!\*)/,end:/\*/},{begin:/_(?!_)/,end:/_/,relevance:0}]};g.contains.push(o),o.contains.push(g);let r=[a,l];g.contains=g.contains.concat(r),o.contains=o.contains.concat(r),r=r.concat(g,o);const b={className:"section",variants:[{begin:"^#{1,6}",end:"$",contains:r},{begin:"(?=^.+?\\n[=-]{2,}$)",contains:[{begin:"^[=-]*$"},{begin:"^",end:"\\n",contains:r}]}]},u={className:"quote",begin:"^>\\s+",contains:r,end:"$"};return{name:"Markdown",aliases:["md","mkdown","mkd"],contains:[b,a,t,g,o,u,s,i,l,c]}}n.exports=a},"84cb":function(n,e,a){"use strict";a.r(e);var i=a("04b0"),s=a.n(i);const t={begin:"",returnBegin:!0,contains:[{className:"link",begin:"doc:",end:">",excludeEnd:!0}]},c={className:"link",begin:/`{2}(?!`)/,end:/`{2}(?!`)/,excludeBegin:!0,excludeEnd:!0},d={begin:"^>\\s+[Note:|Tip:|Important:|Experiment:|Warning:]",end:"$",returnBegin:!0,contains:[{className:"quote",begin:"^>",end:"\\s+"},{className:"type",begin:"Note|Tip|Important|Experiment|Warning",end:":"},{className:"quote",begin:".*",end:"$",endsParent:!0}]},l={begin:"@",end:"[{\\)\\s]",returnBegin:!0,contains:[{className:"title",begin:"@",end:"[\\s+(]",excludeEnd:!0},{begin:":",end:"[,\\)\n\t]",excludeBegin:!0,keywords:{literal:"true false null undefined"},contains:[{className:"number",begin:"\\b([\\d_]+(\\.[\\deE_]+)?|0x[a-fA-F0-9_]+(\\.[a-fA-F0-9p_]+)?|0b[01_]+|0o[0-7_]+)\\b",endsWithParent:!0,excludeEnd:!0},{className:"string",variants:[{begin:/"""/,end:/"""/},{begin:/"/,end:/"/}],endsParent:!0},{className:"link",begin:"http|https",endsWithParent:!0,excludeEnd:!0}]}]};e["default"]=function(n){const e=s()(n),a=e.contains.find(({className:n})=>"code"===n);a.variants=a.variants.filter(({begin:n})=>!n.includes("( {4}|\\t)"));const i=[...e.contains.filter(({className:n})=>"code"!==n),a];return{...e,contains:[c,t,d,l,...i]}}}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-diff.62d66733.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-diff"],{"48b8":function(e,n){function a(e){const n=e.regex;return{name:"Diff",aliases:["patch"],contains:[{className:"meta",relevance:10,match:n.either(/^@@ +-\d+,\d+ +\+\d+,\d+ +@@/,/^\*\*\* +\d+,\d+ +\*\*\*\*$/,/^--- +\d+,\d+ +----$/)},{className:"comment",variants:[{begin:n.either(/Index: /,/^index/,/={3,}/,/^-{3}/,/^\*{3} /,/^\+{3}/,/^diff --git/),end:/$/},{match:/^\*{15}$/}]},{className:"addition",begin:/^\+/,end:/$/},{className:"deletion",begin:/^-/,end:/$/},{className:"addition",begin:/^!/,end:/$/}]}}e.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-http.163e45b6.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-http"],{c01d:function(e,n){function a(e){const n=e.regex,a="HTTP/(2|1\\.[01])",s=/[A-Za-z][A-Za-z0-9-]*/,t={className:"attribute",begin:n.concat("^",s,"(?=\\:\\s)"),starts:{contains:[{className:"punctuation",begin:/: /,relevance:0,starts:{end:"$",relevance:0}}]}},i=[t,{begin:"\\n\\n",starts:{subLanguage:[],endsWithParent:!0}}];return{name:"HTTP",aliases:["https"],illegal:/\S/,contains:[{begin:"^(?="+a+" \\d{3})",end:/$/,contains:[{className:"meta",begin:a},{className:"number",begin:"\\b\\d{3}\\b"}],starts:{end:/\b\B/,illegal:/\S/,contains:i}},{begin:"(?=^[A-Z]+ (.*?) "+a+"$)",end:/$/,contains:[{className:"string",begin:" ",end:" ",excludeBegin:!0,excludeEnd:!0},{className:"meta",begin:a},{className:"keyword",begin:"[A-Z]+"}],starts:{end:/\b\B/,illegal:/\S/,contains:i}},e.inherit(t,{relevance:0})]}}e.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-java.8326d9d8.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-java"],{"332f":function(e,a){var n="[0-9](_*[0-9])*",s=`\\.(${n})`,i="[0-9a-fA-F](_*[0-9a-fA-F])*",t={className:"number",variants:[{begin:`(\\b(${n})((${s})|\\.)?|(${s}))[eE][+-]?(${n})[fFdD]?\\b`},{begin:`\\b(${n})((${s})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${s})[fFdD]?\\b`},{begin:`\\b(${n})[fFdD]\\b`},{begin:`\\b0[xX]((${i})\\.?|(${i})?\\.(${i}))[pP][+-]?(${n})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${i})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function r(e,a,n){return-1===n?"":e.replace(a,s=>r(e,a,n-1))}function c(e){e.regex;const a="[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*",n=a+r("(?:<"+a+"~~~(?:\\s*,\\s*"+a+"~~~)*>)?",/~~~/g,2),s=["synchronized","abstract","private","var","static","if","const ","for","while","strictfp","finally","protected","import","native","final","void","enum","else","break","transient","catch","instanceof","volatile","case","assert","package","default","public","try","switch","continue","throws","protected","public","private","module","requires","exports","do"],i=["super","this"],c=["false","true","null"],l=["char","boolean","long","float","int","byte","short","double"],o={keyword:s,literal:c,type:l,built_in:i},b={className:"meta",begin:"@"+a,contains:[{begin:/\(/,end:/\)/,contains:["self"]}]},_={className:"params",begin:/\(/,end:/\)/,keywords:o,relevance:0,contains:[e.C_BLOCK_COMMENT_MODE],endsParent:!0};return{name:"Java",aliases:["jsp"],keywords:o,illegal:/<\/|#/,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{begin:/\w+@/,relevance:0},{className:"doctag",begin:"@[A-Za-z]+"}]}),{begin:/import java\.[a-z]+\./,keywords:"import",relevance:2},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{begin:/"""/,end:/"""/,className:"string",contains:[e.BACKSLASH_ESCAPE]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,{match:[/\b(?:class|interface|enum|extends|implements|new)/,/\s+/,a],className:{1:"keyword",3:"title.class"}},{begin:[a,/\s+/,a,/\s+/,/=/],className:{1:"type",3:"variable",5:"operator"}},{begin:[/record/,/\s+/,a],className:{1:"keyword",3:"title.class"},contains:[_,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"new throw return else",relevance:0},{begin:["(?:"+n+"\\s+)",e.UNDERSCORE_IDENT_RE,/\s*(?=\()/],className:{2:"title.function"},keywords:o,contains:[{className:"params",begin:/\(/,end:/\)/,keywords:o,relevance:0,contains:[b,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,t,e.C_BLOCK_COMMENT_MODE]},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},t,b]}}e.exports=c}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-json.471128d2.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-json"],{"5ad2":function(n,e){function a(n){const e={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},a={match:/[{}[\],:]/,className:"punctuation",relevance:0},s={beginKeywords:["true","false","null"].join(" ")};return{name:"JSON",contains:[e,a,n.QUOTE_STRING_MODE,s,n.C_NUMBER_MODE,n.C_LINE_COMMENT_MODE,n.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}n.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-llvm.6100b125.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-llvm"],{"7c30":function(e,n){function a(e){const n=e.regex,a=/([-a-zA-Z$._][\w$.-]*)/,t={className:"type",begin:/\bi\d+(?=\s|\b)/},i={className:"operator",relevance:0,begin:/=/},c={className:"punctuation",relevance:0,begin:/,/},l={className:"number",variants:[{begin:/0[xX][a-fA-F0-9]+/},{begin:/-?\d+(?:[.]\d+)?(?:[eE][-+]?\d+(?:[.]\d+)?)?/}],relevance:0},r={className:"symbol",variants:[{begin:/^\s*[a-z]+:/}],relevance:0},s={className:"variable",variants:[{begin:n.concat(/%/,a)},{begin:/%\d+/},{begin:/#\d+/}]},o={className:"title",variants:[{begin:n.concat(/@/,a)},{begin:/@\d+/},{begin:n.concat(/!/,a)},{begin:n.concat(/!\d+/,a)},{begin:/!\d+/}]};return{name:"LLVM IR",keywords:"begin end true false declare define global constant private linker_private internal available_externally linkonce linkonce_odr weak weak_odr appending dllimport dllexport common default hidden protected extern_weak external thread_local zeroinitializer undef null to tail target triple datalayout volatile nuw nsw nnan ninf nsz arcp fast exact inbounds align addrspace section alias module asm sideeffect gc dbg linker_private_weak attributes blockaddress initialexec localdynamic localexec prefix unnamed_addr ccc fastcc coldcc x86_stdcallcc x86_fastcallcc arm_apcscc arm_aapcscc arm_aapcs_vfpcc ptx_device ptx_kernel intel_ocl_bicc msp430_intrcc spir_func spir_kernel x86_64_sysvcc x86_64_win64cc x86_thiscallcc cc c signext zeroext inreg sret nounwind noreturn noalias nocapture byval nest readnone readonly inlinehint noinline alwaysinline optsize ssp sspreq noredzone noimplicitfloat naked builtin cold nobuiltin noduplicate nonlazybind optnone returns_twice sanitize_address sanitize_memory sanitize_thread sspstrong uwtable returned type opaque eq ne slt sgt sle sge ult ugt ule uge oeq one olt ogt ole oge ord uno ueq une x acq_rel acquire alignstack atomic catch cleanup filter inteldialect max min monotonic nand personality release seq_cst singlethread umax umin unordered xchg add fadd sub fsub mul fmul udiv sdiv fdiv urem srem frem shl lshr ashr and or xor icmp fcmp phi call trunc zext sext fptrunc fpext uitofp sitofp fptoui fptosi inttoptr ptrtoint bitcast addrspacecast select va_arg ret br switch invoke unwind unreachable indirectbr landingpad resume malloc alloca free load store getelementptr extractelement insertelement shufflevector getresult extractvalue insertvalue atomicrmw cmpxchg fence argmemonly double",contains:[t,e.COMMENT(/;\s*$/,null,{relevance:0}),e.COMMENT(/;/,/$/),e.QUOTE_STRING_MODE,{className:"string",variants:[{begin:/"/,end:/[^\\]"/}]},o,c,i,s,r,l]}}e.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-markdown.90077643.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-markdown"],{"04b0":function(n,e){function a(n){const e=n.regex,a={begin:/<\/?[A-Za-z_]/,end:">",subLanguage:"xml",relevance:0},i={begin:"^[-\\*]{3,}",end:"$"},s={className:"code",variants:[{begin:"(`{3,})[^`](.|\\n)*?\\1`*[ ]*"},{begin:"(~{3,})[^~](.|\\n)*?\\1~*[ ]*"},{begin:"```",end:"```+[ ]*$"},{begin:"~~~",end:"~~~+[ ]*$"},{begin:"`.+?`"},{begin:"(?=^( {4}|\\t))",contains:[{begin:"^( {4}|\\t)",end:"(\\n)$"}],relevance:0}]},c={className:"bullet",begin:"^[ \t]*([*+-]|(\\d+\\.))(?=\\s+)",end:"\\s+",excludeEnd:!0},t={begin:/^\[[^\n]+\]:/,returnBegin:!0,contains:[{className:"symbol",begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0},{className:"link",begin:/:\s*/,end:/$/,excludeBegin:!0}]},g=/[A-Za-z][A-Za-z0-9+.-]*/,d={variants:[{begin:/\[.+?\]\[.*?\]/,relevance:0},{begin:/\[.+?\]\(((data|javascript|mailto):|(?:http|ftp)s?:\/\/).*?\)/,relevance:2},{begin:e.concat(/\[.+?\]\(/,g,/:\/\/.*?\)/),relevance:2},{begin:/\[.+?\]\([./?&#].*?\)/,relevance:1},{begin:/\[.*?\]\(.*?\)/,relevance:0}],returnBegin:!0,contains:[{match:/\[(?=\])/},{className:"string",relevance:0,begin:"\\[",end:"\\]",excludeBegin:!0,returnEnd:!0},{className:"link",relevance:0,begin:"\\]\\(",end:"\\)",excludeBegin:!0,excludeEnd:!0},{className:"symbol",relevance:0,begin:"\\]\\[",end:"\\]",excludeBegin:!0,excludeEnd:!0}]},l={className:"strong",contains:[],variants:[{begin:/_{2}/,end:/_{2}/},{begin:/\*{2}/,end:/\*{2}/}]},o={className:"emphasis",contains:[],variants:[{begin:/\*(?!\*)/,end:/\*/},{begin:/_(?!_)/,end:/_/,relevance:0}]};l.contains.push(o),o.contains.push(l);let b=[a,d];l.contains=l.contains.concat(b),o.contains=o.contains.concat(b),b=b.concat(l,o);const r={className:"section",variants:[{begin:"^#{1,6}",end:"$",contains:b},{begin:"(?=^.+?\\n[=-]{2,}$)",contains:[{begin:"^[=-]*$"},{begin:"^",end:"\\n",contains:b}]}]},m={className:"quote",begin:"^>\\s+",contains:b,end:"$"};return{name:"Markdown",aliases:["md","mkdown","mkd"],contains:[r,a,c,l,o,m,s,i,d,t]}}n.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-objectivec.bcdf5156.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-objectivec"],{"9bf2":function(e,n){function _(e){const n={className:"built_in",begin:"\\b(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)\\w+"},_=/[a-zA-Z@][a-zA-Z0-9_]*/,i=["int","float","while","char","export","sizeof","typedef","const","struct","for","union","unsigned","long","volatile","static","bool","mutable","if","do","return","goto","void","enum","else","break","extern","asm","case","short","default","double","register","explicit","signed","typename","this","switch","continue","wchar_t","inline","readonly","assign","readwrite","self","@synchronized","id","typeof","nonatomic","super","unichar","IBOutlet","IBAction","strong","weak","copy","in","out","inout","bycopy","byref","oneway","__strong","__weak","__block","__autoreleasing","@private","@protected","@public","@try","@property","@end","@throw","@catch","@finally","@autoreleasepool","@synthesize","@dynamic","@selector","@optional","@required","@encode","@package","@import","@defs","@compatibility_alias","__bridge","__bridge_transfer","__bridge_retained","__bridge_retain","__covariant","__contravariant","__kindof","_Nonnull","_Nullable","_Null_unspecified","__FUNCTION__","__PRETTY_FUNCTION__","__attribute__","getter","setter","retain","unsafe_unretained","nonnull","nullable","null_unspecified","null_resettable","class","instancetype","NS_DESIGNATED_INITIALIZER","NS_UNAVAILABLE","NS_REQUIRES_SUPER","NS_RETURNS_INNER_POINTER","NS_INLINE","NS_AVAILABLE","NS_DEPRECATED","NS_ENUM","NS_OPTIONS","NS_SWIFT_UNAVAILABLE","NS_ASSUME_NONNULL_BEGIN","NS_ASSUME_NONNULL_END","NS_REFINED_FOR_SWIFT","NS_SWIFT_NAME","NS_SWIFT_NOTHROW","NS_DURING","NS_HANDLER","NS_ENDHANDLER","NS_VALUERETURN","NS_VOIDRETURN"],t=["false","true","FALSE","TRUE","nil","YES","NO","NULL"],a=["BOOL","dispatch_once_t","dispatch_queue_t","dispatch_sync","dispatch_async","dispatch_once"],o={$pattern:_,keyword:i,literal:t,built_in:a},s={$pattern:_,keyword:["@interface","@class","@protocol","@implementation"]};return{name:"Objective-C",aliases:["mm","objc","obj-c","obj-c++","objective-c++"],keywords:o,illegal:"/,end:/$/,illegal:"\\n"},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{className:"class",begin:"("+s.keyword.join("|")+")\\b",end:/(\{|$)/,excludeEnd:!0,keywords:s,contains:[e.UNDERSCORE_TITLE_MODE]},{begin:"\\."+e.UNDERSCORE_IDENT_RE,relevance:0}]}}e.exports=_}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-python.c214ed92.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-python"],{9510:function(e,n){function a(e){const n=e.regex,a=/[\p{XID_Start}_]\p{XID_Continue}*/u,i=["and","as","assert","async","await","break","class","continue","def","del","elif","else","except","finally","for","from","global","if","import","in","is","lambda","nonlocal|10","not","or","pass","raise","return","try","while","with","yield"],s=["__import__","abs","all","any","ascii","bin","bool","breakpoint","bytearray","bytes","callable","chr","classmethod","compile","complex","delattr","dict","dir","divmod","enumerate","eval","exec","filter","float","format","frozenset","getattr","globals","hasattr","hash","help","hex","id","input","int","isinstance","issubclass","iter","len","list","locals","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","range","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","vars","zip"],t=["__debug__","Ellipsis","False","None","NotImplemented","True"],r=["Any","Callable","Coroutine","Dict","List","Literal","Generic","Optional","Sequence","Set","Tuple","Type","Union"],l={$pattern:/[A-Za-z]\w+|__\w+__/,keyword:i,built_in:s,literal:t,type:r},o={className:"meta",begin:/^(>>>|\.\.\.) /},b={className:"subst",begin:/\{/,end:/\}/,keywords:l,illegal:/#/},c={begin:/\{\{/,relevance:0},d={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,o],relevance:10},{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,o],relevance:10},{begin:/([fF][rR]|[rR][fF]|[fF])'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,o,c,b]},{begin:/([fF][rR]|[rR][fF]|[fF])"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,o,c,b]},{begin:/([uU]|[rR])'/,end:/'/,relevance:10},{begin:/([uU]|[rR])"/,end:/"/,relevance:10},{begin:/([bB]|[bB][rR]|[rR][bB])'/,end:/'/},{begin:/([bB]|[bB][rR]|[rR][bB])"/,end:/"/},{begin:/([fF][rR]|[rR][fF]|[fF])'/,end:/'/,contains:[e.BACKSLASH_ESCAPE,c,b]},{begin:/([fF][rR]|[rR][fF]|[fF])"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,c,b]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},p="[0-9](_?[0-9])*",g=`(\\b(${p}))?\\.(${p})|\\b(${p})\\.`,m={className:"number",relevance:0,variants:[{begin:`(\\b(${p})|(${g}))[eE][+-]?(${p})[jJ]?\\b`},{begin:`(${g})[jJ]?`},{begin:"\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?\\b"},{begin:"\\b0[bB](_?[01])+[lL]?\\b"},{begin:"\\b0[oO](_?[0-7])+[lL]?\\b"},{begin:"\\b0[xX](_?[0-9a-fA-F])+[lL]?\\b"},{begin:`\\b(${p})[jJ]\\b`}]},_={className:"comment",begin:n.lookahead(/# type:/),end:/$/,keywords:l,contains:[{begin:/# type:/},{begin:/#/,end:/\b\B/,endsWithParent:!0}]},u={className:"params",variants:[{className:"",begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:["self",o,m,d,e.HASH_COMMENT_MODE]}]};return b.contains=[d,m,o],{name:"Python",aliases:["py","gyp","ipython"],unicodeRegex:!0,keywords:l,illegal:/(<\/|->|\?)|=>/,contains:[o,m,{begin:/\bself\b/},{beginKeywords:"if",relevance:0},d,_,e.HASH_COMMENT_MODE,{match:[/def/,/\s+/,a],scope:{1:"keyword",3:"title.function"},contains:[u]},{variants:[{match:[/class/,/\s+/,a,/\s*/,/\(\s*/,a,/\s*\)/]},{match:[/class/,/\s+/,a]}],scope:{1:"keyword",3:"title.class",6:"title.class.inherited"}},{className:"meta",begin:/^[\t ]*@/,end:/(?=#)|$/,contains:[m,u,d]}]}}e.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-ruby.f889d392.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-ruby"],{"82cb":function(e,n){function a(e){const n=e.regex,a="([a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?)",i={keyword:"and then defined module in return redo if BEGIN retry end for self when next until do begin unless END rescue else break undef not super class case require yield alias while ensure elsif or include attr_reader attr_writer attr_accessor __FILE__",built_in:"proc lambda",literal:"true false nil"},s={className:"doctag",begin:"@[A-Za-z]+"},b={begin:"#<",end:">"},c=[e.COMMENT("#","$",{contains:[s]}),e.COMMENT("^=begin","^=end",{contains:[s],relevance:10}),e.COMMENT("^__END__","\\n$")],r={className:"subst",begin:/#\{/,end:/\}/,keywords:i},d={className:"string",contains:[e.BACKSLASH_ESCAPE,r],variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/`/,end:/`/},{begin:/%[qQwWx]?\(/,end:/\)/},{begin:/%[qQwWx]?\[/,end:/\]/},{begin:/%[qQwWx]?\{/,end:/\}/},{begin:/%[qQwWx]?/},{begin:/%[qQwWx]?\//,end:/\//},{begin:/%[qQwWx]?%/,end:/%/},{begin:/%[qQwWx]?-/,end:/-/},{begin:/%[qQwWx]?\|/,end:/\|/},{begin:/\B\?(\\\d{1,3})/},{begin:/\B\?(\\x[A-Fa-f0-9]{1,2})/},{begin:/\B\?(\\u\{?[A-Fa-f0-9]{1,6}\}?)/},{begin:/\B\?(\\M-\\C-|\\M-\\c|\\c\\M-|\\M-|\\C-\\M-)[\x20-\x7e]/},{begin:/\B\?\\(c|C-)[\x20-\x7e]/},{begin:/\B\?\\?\S/},{begin:n.concat(/<<[-~]?'?/,n.lookahead(/(\w+)(?=\W)[^\n]*\n(?:[^\n]*\n)*?\s*\1\b/)),contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,contains:[e.BACKSLASH_ESCAPE,r]})]}]},t="[1-9](_?[0-9])*|0",o="[0-9](_?[0-9])*",g={className:"number",relevance:0,variants:[{begin:`\\b(${t})(\\.(${o}))?([eE][+-]?(${o})|r)?i?\\b`},{begin:"\\b0[dD][0-9](_?[0-9])*r?i?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*r?i?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*r?i?\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*r?i?\\b"},{begin:"\\b0(_?[0-7])+r?i?\\b"}]},l={className:"params",begin:"\\(",end:"\\)",endsParent:!0,keywords:i},_=[d,{className:"class",beginKeywords:"class module",end:"$|;",illegal:/=/,contains:[e.inherit(e.TITLE_MODE,{begin:"[A-Za-z_]\\w*(::\\w+)*(\\?|!)?"}),{begin:"<\\s*",contains:[{begin:"("+e.IDENT_RE+"::)?"+e.IDENT_RE,relevance:0}]}].concat(c)},{className:"function",begin:n.concat(/def\s+/,n.lookahead(a+"\\s*(\\(|;|$)")),relevance:0,keywords:"def",end:"$|;",contains:[e.inherit(e.TITLE_MODE,{begin:a}),l].concat(c)},{begin:e.IDENT_RE+"::"},{className:"symbol",begin:e.UNDERSCORE_IDENT_RE+"(!|\\?)?:",relevance:0},{className:"symbol",begin:":(?!\\s)",contains:[d,{begin:a}],relevance:0},g,{className:"variable",begin:"(\\$\\W)|((\\$|@@?)(\\w+))(?=[^@$?])(?![A-Za-z])(?![@$?'])"},{className:"params",begin:/\|/,end:/\|/,relevance:0,keywords:i},{begin:"("+e.RE_STARTERS_RE+"|unless)\\s*",keywords:"unless",contains:[{className:"regexp",contains:[e.BACKSLASH_ESCAPE,r],illegal:/\n/,variants:[{begin:"/",end:"/[a-z]*"},{begin:/%r\{/,end:/\}[a-z]*/},{begin:"%r\\(",end:"\\)[a-z]*"},{begin:"%r!",end:"![a-z]*"},{begin:"%r\\[",end:"\\][a-z]*"}]}].concat(b,c),relevance:0}].concat(b,c);r.contains=_,l.contains=_;const w="[>?]>",E="[\\w#]+\\(\\w+\\):\\d+:\\d+>",u="(\\w+-)?\\d+\\.\\d+\\.\\d+(p\\d+)?[^\\d][^>]+>",N=[{begin:/^\s*=>/,starts:{end:"$",contains:_}},{className:"meta",begin:"^("+w+"|"+E+"|"+u+")(?=[ ])",starts:{end:"$",contains:_}}];return c.unshift(b),{name:"Ruby",aliases:["rb","gemspec","podspec","thor","irb"],keywords:i,illegal:/\/\*/,contains:[e.SHEBANG({binary:"ruby"})].concat(N).concat(c).concat(_)}}e.exports=a}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-shell.dd7f411f.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-shell"],{b65b:function(s,n){function e(s){return{name:"Shell Session",aliases:["console","shellsession"],contains:[{className:"meta",begin:/^\s{0,3}[/~\w\d[\]()@-]*[>%$#][ ]?/,starts:{end:/[^\\](?=\s*$)/,subLanguage:"bash"}}]}}s.exports=e}}]); -------------------------------------------------------------------------------- /docs/js/highlight-js-xml.9c3688c7.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * This source file is part of the Swift.org open source project 3 | * 4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors 5 | * Licensed under Apache License v2.0 with Runtime Library Exception 6 | * 7 | * See https://swift.org/LICENSE.txt for license information 8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors 9 | */ 10 | (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["highlight-js-xml"],{"8dcb":function(e,n){function a(e){const n=e.regex,a=n.concat(/[A-Z_]/,n.optional(/[A-Z0-9_.-]*:/),/[A-Z0-9_.-]*/),s=/[A-Za-z0-9._:-]+/,t={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},i={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},c=e.inherit(i,{begin:/\(/,end:/\)/}),l=e.inherit(e.APOS_STRING_MODE,{className:"string"}),r=e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),g={endsWithParent:!0,illegal:/`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,contains:[{className:"meta",begin://,relevance:10,contains:[i,r,l,c,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin://,contains:[i,c,r,l]}]}]},e.COMMENT(//,{relevance:10}),{begin://,relevance:10},t,{className:"meta",begin:/<\?xml/,end:/\?>/,relevance:10},{className:"tag",begin:/)/,end:/>/,keywords:{name:"style"},contains:[g],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/)/,end:/>/,keywords:{name:"script"},contains:[g],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:n.concat(//,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:a,relevance:0,starts:g}]},{className:"tag",begin:n.concat(/<\//,n.lookahead(n.concat(a,/>/))),contains:[{className:"name",begin:a,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}e.exports=a}}]); -------------------------------------------------------------------------------- /docs/metadata.json: -------------------------------------------------------------------------------- 1 | {"bundleDisplayName":"Bodega","bundleIdentifier":"Bodega","schemaVersion":{"major":0,"minor":1,"patch":0}} -------------------------------------------------------------------------------- /docs/theme-settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "meta": {}, 3 | "theme": { 4 | "colors": { 5 | "text": "", 6 | "text-background": "", 7 | "grid": "", 8 | "article-background": "", 9 | "generic-modal-background": "", 10 | "secondary-label": "", 11 | "header-text": "", 12 | "not-found": { 13 | "input-border": "" 14 | }, 15 | "runtime-preview": { 16 | "text": "" 17 | }, 18 | "tabnav-item": { 19 | "border-color": "" 20 | }, 21 | "svg-icon": { 22 | "fill-light": "", 23 | "fill-dark": "" 24 | }, 25 | "loading-placeholder": { 26 | "background": "" 27 | }, 28 | "button": { 29 | "text": "", 30 | "light": { 31 | "background": "", 32 | "backgroundHover": "", 33 | "backgroundActive": "" 34 | }, 35 | "dark": { 36 | "background": "", 37 | "backgroundHover": "", 38 | "backgroundActive": "" 39 | } 40 | }, 41 | "link": null 42 | }, 43 | "style": { 44 | "button": { 45 | "borderRadius": null 46 | } 47 | }, 48 | "typography": { 49 | "html-font": "" 50 | } 51 | }, 52 | "features": { 53 | "docs": { 54 | "summary": { 55 | "hide": false 56 | } 57 | } 58 | } 59 | } 60 | --------------------------------------------------------------------------------