[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-7135":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":18,"stars30d":19,"stars90d":16,"forks30d":16,"starsTrendScore":20,"compositeScore":21,"rankGlobal":10,"rankLanguage":10,"license":22,"archived":23,"fork":23,"defaultBranch":24,"hasWiki":25,"hasPages":25,"topics":26,"createdAt":10,"pushedAt":10,"updatedAt":35,"readmeContent":36,"aiSummary":37,"trendingCount":16,"starSnapshotCount":16,"syncStatus":38,"lastSyncTime":39,"discoverSource":40},7135,"CareKit","carekit-apple\u002FCareKit","carekit-apple","CareKit is an open source software framework for creating apps that help people better understand and manage their health.","https:\u002F\u002Fwww.researchandcare.org",null,"Swift",2517,465,131,81,0,3,6,8,9,30.01,"Other",false,"main",true,[27,28,29,30,31,32,33,34],"carekit","combine","core-data","darkmode-ios13","health","swift-package-manager","swift5","uiframework","2026-06-12 02:01:35","![CareKit](https:\u002F\u002Fuser-images.githubusercontent.com\u002F29666989\u002F60061659-cf6acb00-96aa-11e9-90a0-459b08fc020d.png)\n\n# CareKit\n\n[![License](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Flicense-BSD-green.svg?style=flat)](https:\u002F\u002Fgithub.com\u002Fcarekit-apple\u002FCareKit#license) [![Swift Versions](https:\u002F\u002Fimg.shields.io\u002Fendpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fcarekit-apple%2FCareKit%2Fbadge%3Ftype%3Dswift-versions)](https:\u002F\u002Fswiftpackageindex.com\u002Fcarekit-apple\u002FCareKit) [![OS's](https:\u002F\u002Fimg.shields.io\u002Fendpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fcarekit-apple%2FCareKit%2Fbadge%3Ftype%3Dplatforms)](https:\u002F\u002Fswiftpackageindex.com\u002Fcarekit-apple\u002FCareKit) ![Xcode 16.3+](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FXcode-16.3%2B-blue.svg) [![SPM](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FSwift%20Package%20Manager-compatible-brightgreen.svg)](https:\u002F\u002Fgithub.com\u002Fapple\u002Fswift-package-manager)\n\nCareKit™ is an open source software framework for creating apps that help people better understand and manage their health. The framework provides modules that you can use out of the box, or extended and customized for more targeted use cases. It's composed of three SPM packages which can each be imported separately.\n\n* **CareKit:** This is the best place to start building your app. CareKit provides view controllers that tie CareKitUI and CareKitStore together. The view controllers leverage Combine to provide synchronization between the store and the views.\n\n* **CareKitUI:** Provides the views used across the framework. The views are open and extensible subclasses of UIView. Properties within the views are public, allowing for full control over the content.\n\n* **CareKitStore:** Provides a Core Data solution for storing patient data. It also provides the ability to use a custom store, such as a third party database or API.\n\n# Table of Contents\n* [Requirements](#requirements)\n* [Getting Started](#getting-started)\n    * [OCKCatalog App](#ockcatalog-app)\n    * [OCKSample App](#ocksample-app)\n* [CareKit](#carekit)\n    * [List View Controllers](#list-view-controllers)\n    * [Synchronized View Controllers](#synchronized-view-controllers)\n    * [Custom Synchronized View Controllers](#custom-synchronized-view-controllers)\n* [CareKitUI](#carekitui)\n    * [Tasks](#tasks)\n    * [Charts](#charts)\n    * [Contacts](#contacts)\n    * [Styling](#styling)\n* [CareKitStore](#carekitstore)\n    * [Store](#store)\n    * [Schema](#schema)\n    * [Scheduling](#scheduling)\n    * [Custom Stores and Types](#custom-stores-and-types)\n* [Getting Help](#getting-help)\n* [License](#license)\n\n# Requirements \u003Ca name=\"requirements\">\u003C\u002Fa>\n\nThe primary CareKit framework codebase supports iOS and requires Xcode 12.0 or newer. The CareKit framework has a Base SDK version of 13.0.\n\n# Getting Started \u003Ca name=\"getting-started\">\u003C\u002Fa>\n\n* [Website](https:\u002F\u002Fwww.researchandcare.org)\n* [Documentation](https:\u002F\u002Fswiftpackageindex.com\u002Fcarekit-apple\u002FCareKit\u002Fmain\u002Fdocumentation\u002Fcarekit)\n* [WWDC: ResearchKit and CareKit Reimagined](https:\u002F\u002Fdeveloper.apple.com\u002Fvideos\u002Fplay\u002Fwwdc2019\u002F217\u002F)\n\n### Option One: Install using Swift Package Manager\n\nYou can install CareKit using Swift Package Manager. Create a new Xcode project and navigate to `File > Swift Packages > Add Package Dependency`. Enter the URL `https:\u002F\u002Fgithub.com\u002Fcarekit-apple\u002FCareKit` and tap `Next`. Choose the `main` branch, and on the next screen, check off the packages as needed.\n\nTo add localized strings to your project, add the strings file to your project: [English Strings](CareKitUI\u002FCareKitUI\u002FSupporting%20Files\u002FLocalization\u002Fen.lproj)\n\n### Option Two: Install as an embedded framework\n\nDownload the project source code and drag in CareKit.xcodeproj, CareKitUI.xcodeproj, and CareKitStore.xcodeproj as needed. Then, embed each framework in your app by adding them to the \"Embedded Binaries\" section for your target as shown in the figure below.\n\n\u003Cimg width=\"1000\" alt=\"embedded-framework\" src=\"https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107216-7fa7ea00-0a25-11ea-89ef-9b8724728e54.png\">\n\n### OCKCatalog App \u003Ca name=\"ockcatalog-app\">\u003C\u002Fa>\n\nThe included catalog app demonstrates the different modules that are available in CareKit: [OCKCatalog](https:\u002F\u002Fgithub.com\u002Fcarekit-apple\u002FCareKitCatalog)\n\n![ockcatalog](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69096972-66de0b00-0a0a-11ea-96f0-4605d04ab396.gif)\n\n\n### OCKSampleApp \u003Ca name=\"ocksample-app\">\u003C\u002Fa>\n\nThe included sample app demonstrates a fully constructed CareKit app: [OCKSample](https:\u002F\u002Fgithub.com\u002Fcarekit-apple\u002FCareKitSample)\n\n![ocksample](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107801-7586eb00-0a27-11ea-8aa2-eca687602c76.gif)\n\n# CareKit \u003Ca name=\"carekit\">\u003C\u002Fa>\n\nCareKit is the overarching package that provides view controllers to tie CareKitUI and CareKitStore together. When importing CareKit, CareKitUI and CareKitStore are imported under the hood.\n\n### List view controllers \u003Ca name=\"list-view-controllers\">\u003C\u002Fa>\n\nCareKit offers full screen view controllers for convenience. The view controllers query for and display data from a store, and stay synchronized with the data.\n\n* `OCKDailyTasksPageViewController`: Displays tasks for each day with a calendar to page through dates.\n\n* `OCKContactsListViewController`: Displays a list of contacts in the store.\n\n### Synchronized View Controllers \u003Ca name=\"synchronized-view-controllers\">\u003C\u002Fa>\n\nFor each card in CareKitUI, there's a corresponding view controller in CareKit. The view controllers are self contained modules that you can place anywhere by using standard view controller containment. The view controller for each card provides synchronization between the view and the store. The following code creates a synchronized view controller.\n\n```swift\n\u002F\u002F Create a store to hold your data.\nlet store = OCKStore(named: \"my-store\", type: .onDisk)\n\n\u002F\u002F Create a view controller that queries for and displays data. The view will update automatically whenever the data in the store changes.\nlet viewController = OCKSimpleTaskViewController(taskID: \"doxylamine\", eventQuery: OCKEventQuery(for: Date()), store: store)\n```\n\nAll synchronized view controllers have a view synchronizer. The view synchronizer defines how to instantiate the view to display, and how to update the view when the data in the store changes. You can customize view synchronizers and inject them into a view controller to perform custom behavior.\n\n```swift\n\u002F\u002F Define a custom view synchronizer.\nclass CustomSimpleTaskViewSynchronizer: OCKSimpleTaskViewSynchronizer {\n\n    override func makeView() -> OCKSimpleTaskView {\n        let view = super.makeView()\n        \u002F\u002F Customize the view when it's instantiated here.\n        return view\n    }\n\n    override func updateView(_ view: OCKSimpleTaskView, context: OCKSynchronizationContext\u003COCKTaskEvents>) {\n        super.updateView(view, context: context)\n        \u002F\u002F Update the view when the data changes in the store here.\n    }\n}\n\n\u002F\u002F Instantiate the view controller with the custom classes, then fetch and observe data in the store.\nvar query = OCKEventQuery(for: Date())\nquery.taskIDs = [\"Doxylamine\"]\n\nlet viewController = OCKSimpleTaskViewController(query: query, store: store, viewSynchronizer: CustomSimpleTaskViewSynchronizer())\n```\n\n### Custom Synchronized View Controllers \u003Ca name=\"custom-synchronized-view-controllers\">\u003C\u002Fa>\n\nCareKit supports creating a custom view that can pair with a synchronized view controller. This allows synchronization between the custom view and the data in the store. \n\n``` swift\n\u002F\u002F Define a view synchronizer for the custom view.\nclass TaskButtonViewSynchronizer: ViewSynchronizing {\n\n    \u002F\u002F Instantiate the custom view.\n    func makeView() -> UIButton {\n        return UIButton(frame: CGRect(x: 0, y: 0, width: 200, height: 60))\n    }\n\n    \u002F\u002F Update the custom view when the data in the store changes.\n    func updateView(\n        _ view: UIButton,\n        context: OCKSynchronizationContext\u003COCKAnyEvent?>\n    ) {\n        let event = context.viewModel\n        view.titleLabel?.text = event?.task.title\n        view.isSelected = event?.outcome != nil\n    }\n}\n\nvar query = OCKEventQuery(for: Date())\nquery.taskIDs = [\"Doxylamine\"]\n\nlet events = store\n    .anyEvents(matching: query)\n    .map { $0.first }\n\nlet viewController = SynchronizedViewController(\n    initialViewModel: nil,\n    viewModels: events,\n    viewSynchronizer: TaskButtonViewSynchronizer()\n)\n```\n\n# CareKitUI \u003Ca name=\"carekitui\">\u003C\u002Fa>\n\nCareKitUI provides cards to represent tasks, charts, and contacts. There are multiple provided styles for each category of card.\n\nYou build all cards in a similar pattern. This makes it easy to recognize and customize the properties of each card. Cards contain a `headerView` at the top that displays labels and icons. The contents of the card are inside a vertical `contentStackView`. This allows for easy placement of custom views into a card without breaking existing constraints.\n\nFor creating a card from scratch, see the `OCKCardable` protocol. Conforming to this protocol makes it possible for a custom card to match the styling used across the framework.\n\n### Tasks \u003Ca name=\"tasks\">\u003C\u002Fa>\n\nHere are the available task card styles:\n\n![Task](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107434-32784800-0a26-11ea-8075-0a8b8b57afd2.png)\n\nThis example instantiates and customizes the instructions task card:\n\n```swift\nlet taskView = OCKInstructionsTaskView()\n\ntaskView.headerView.titleLabel.text = \"Doxylamine\"\ntaskView.headerView.detailLabel.text = \"7:30 AM to 8:30 AM\"\n\ntaskView.instructionsLabel.text = \"Take the tablet with a full glass of water.\"\n\ntaskView.completionButton.isSelected = false\ntaskView.completionButton.label.text = \"Mark as Completed\"\n```\n\n### Charts \u003Ca name=\"charts\">\u003C\u002Fa>\n\nHere are the available chart card styles:\n\n![Chart](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107429-32784800-0a26-11ea-897d-0e3885c31e73.png)\n\nThis example instantiates and customizes the bar chart:\n\n```swift\nlet chartView = OCKCartesianChartView(type: .bar)\n\nchartView.headerView.titleLabel.text = \"Doxylamine\"\n\nchartView.graphView.dataSeries = [\n    OCKDataSeries(values: [0, 1, 1, 2, 3, 3, 2], title: \"Doxylamine\")\n]\n```\n\n### Contacts \u003Ca name=\"contacts\">\u003C\u002Fa>\n\nHere are the available contact card styles:\n\n![Contact](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107430-32784800-0a26-11ea-98d2-9dcd06c0ab27.png)\n\nThis example instantiates and customizes the simple contact card:\n\n```swift\nlet contactView = OCKSimpleContactView()\n\ncontactView.headerView.titleLabel.text = \"Lexi Torres\"\ncontactView.headerView.detailLabel.text = \"Family Practice\"\n```\n\n### Styling \u003Ca name=\"styling\">\u003C\u002Fa>\n\nTo provide custom styling or branding across the framework, see the `OCKStylable` protocol. All stylable views derive their appearance from a list of injected constants. You can customize this list of constants for quick and easy styling.\n\nHere's an example that customizes the separator color in a view, and all of it's descendents:\n\n```swift\n\u002F\u002F Define your custom separator color.\nstruct CustomColors: OCKColorStyler {\n    var separator: UIColor { .black }\n}\n\n\u002F\u002F Define a custom struct to hold your custom color.\nstruct CustomStyle: OCKStyler {\n    var color: OCKColorStyler { CustomColors() }\n}\n\n\u002F\u002F Apply the custom style to your view.\nlet view = OCKSimpleTaskView()\nview.customStyle = CustomStyle()\n````\n\nNote that each view in CareKitUI is styled with `OCKStyle` by default. Setting a custom style on a view propagates the custom style down to any subviews that don't already have a custom style set. You can visualize the style propagation rules in this diagram demonstrating three separate view hierarchies:\n\n![Styling](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107433-32784800-0a26-11ea-9622-74bb30ce4abd.png)\n\nFor information on styling SwiftUI views with `OCKStylable`, see [SwiftUI in CareKitUI](#carekitui-swiftui).\n\n# CareKitStore \u003Ca name=\"carekitstore\">\u003C\u002Fa>\n\nThe CareKitStore package defines the `OCKStoreProtocol` that CareKit uses to communicate to data stores, and a concrete implementation that leverages CoreData, called `OCKStore`.\nIt also contains definitions of most of the core structures and data types that CareKit relies on, such as `OCKAnyTask`, `OCKTaskQuery`, and `OCKSchedule`.\n\n### Store \u003Ca name=\"store\">\u003C\u002Fa>\n\nThe `OCKStore` class is an append-only, versioned store packaged with CareKit. It's implemented on top of CoreData and provides fast, secure, on-device storage. `OCKStore` is designed to integrate with CareKit's synchronized view controllers, but is usable in isolation as well.\n\n```swift\nimport CareKitStore\n\nlet store = OCKStore(named: \"my-store\", type: .onDisk)\nlet breakfastSchedule = OCKSchedule.dailyAtTime(hour: 8, minutes: 0, start: Date(), end: nil, text: \"Breakfast\")\nlet task = OCKTask(id: \"doxylamine\", title: \"Doxylamine\", carePlanID: nil, schedule: breakfastSchedule)\n\nlet storedTask = try await store.addTask(task)\n```\n\nThe most important feature of `OCKStore` is that it's a versioned store with a notion of time. When querying the store using a date range, the result returned is for the state of the store during the interval specified. If no date interval is provided, the query returns all versions of the entity.\n\n```swift\n\u002F\u002F On January 1st\nlet task = OCKTask(id: \"doxylamine\", title: \"Take 1 tablet of Doxylamine\", carePlanID: nil, schedule: breakfastSchedule)\nlet addedTask = try await store.addTask(task)\n\n\u002F\u002F On January 10th\nlet task = OCKTask(id: \"doxylamine\", title: \"Take 2 tablets of Doxylamine\", carePlanID: nil, schedule: breakfastSchedule)\nlet updatedTask = try await store.updateTask(task)\n\n\u002F\u002F On some future date.\nlet earlyQuery = OCKTaskQuery(dateInterval: \u002F* Jan 1st - 5th *\u002F)\nlet earlyTasks = try await store.fetchTasks(query: earlyQuery)\n\nlet laterQuery = OCKTaskQuery(dateInterval: \u002F* Jan 12th - 17th *\u002F)\nlet laterTasks = try await store.fetchTasks(query: laterQuery)\n\n\u002F\u002F Queries return the newest version of the task during the query interval.\nlet midQuery = OCKTaskQuery(dateInterval: \u002F* Jan 5th - 15th *\u002F)\nlet midTasks = try await store.fetchTasks(query: laterQuery)\n\n\u002F\u002F Queries with no date interval return all versions of the task.\nlet allQuery = OCKTaskQuery()\nlet allTasks = try await store.fetchTasks(query: allQuery)\n```\n\nThis graphic visualizes how to retrieve results when querying versioned objects in CareKit. Note how a query over a date range returns the version of the object that's valid in that date range.  \n![3d608700-5193-11ea-8ec0-452688468c72](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51723116\u002F74690609-8c5aec00-5194-11ea-919a-53196eeefb9f.png)\n\n### Schema \u003Ca name=\"schema\">\u003C\u002Fa>\n\nCareKitStore defines six high level entities in this diagram:\n\n![Schema](https:\u002F\u002Fuser-images.githubusercontent.com\u002F51756298\u002F69107431-32784800-0a26-11ea-83fc-8987d7ef2e15.png)\n\n* **Patient:** A patient represents the user of the app.\n\n* **Care Plan**: A patient has zero or more care plans. A care plan organizes the contacts and tasks associated with a specific treatment. For example, a patient may have one care plan for heart disease and a second for obesity.\n\n* **Contact:** A care plan has zero or more associated contacts. Contacts might include doctors, nurses, insurance providers, or family.\n\n* **Task:** A care plan has zero or more tasks. A task represents some activity that the patient performs. Examples include taking a medication, exercising, journaling, or checking in with their doctor.\n\n* **Schedule:** Each task must have a schedule. The schedule defines occurrences of a task, and may optionally specify target or goal values, such as how much of a medication to take.\n\n* **Outcome:** Each occurrence of a task may have an associated outcome. The absence of an outcome indicates no progress was made on that occurrence of the task.\n\n* **Outcome Value:** Each outcome has zero or more values associated with it. A value might represent how much medication was taken, or a plurality of outcome values could represent the answers to a survey.\n\nIt's important to note that tasks, contacts, and care plans can exist *without* a parent entity. Many CareKit apps target well defined use cases, and it can often be expedient to simply create tasks and contacts without defining a patient or care plan.\n\n### Scheduling \u003Ca name=\"scheduling\">\u003C\u002Fa>\n\nThe scheduling tools provided in CareKit allow very precise and customizable scheduling of tasks. You create an instance of `OCKSchedule` by composing one or more\n`OCKScheduleElements`. Each element defines a single repeating interval.\n\nStatic convenience methods exist to help with common use cases.\n\n```swift\nlet breakfastSchedule = OCKSchedule.dailyAtTime(hour: 8, minutes: 0, start: Date(), end: nil, text: \"Breakfast\")\nlet everySaturdayAtNoon = OCKSchedule.weeklyAtTime(weekday: 7, hours: 12, minutes: 0, start: Date(), end: nil)\n```\n\nYou can create highly precise, complicated schedules by combining schedule elements or other schedules.\n\n```swift\n\u002F\u002F Combine elements to create a complex schedule.\nlet elementA = OCKScheduleElement(start: today, end: nextWeek, interval: DateComponents(hour: 36))\nlet elementB = OCKScheduleElement(start: lastWeek, end: nil, interval: DateComponents(day: 2))\nlet complexSchedule = OCKSchedule(composing: [elementA, elementB])\n\n\u002F\u002F Combine two schedules into a composed schedule.\nlet dailySchedule = OCKSchedule.dailyAtTime(hour: 8, minutes: 0, start: tomorrow, end: nextYear, text: nil)\nlet crazySchedule = OCKSchedule(composing: [dailySchedule, complexSchedule])\n```\n\nSchedules have a number of other useful properties that you can set, including target values, durations, and textual descriptions.\n\n```swift\nlet element = OCKScheduleElement(\n    start: today,  \u002F\u002F The date and time this schedule begins.\n    end: nextYear, \u002F\u002F The date and time this schedule ends.\n    interval: DateComponents(day: 3), \u002F\u002F Occurs every 3 days.\n    text: \"Before bed\", \u002F\u002F Show \"Before bed\" instead of clock time.\n    targetValues: [OCKOutcomeValue(10, units: \"mL\")], \u002F\u002F Specifies what counts as \"complete\".\n    duration: Duration = .hours(2) \u002F\u002F The window of time to complete the task.\n)\n```\n\n* `text`: By default, CareKit view controllers prompt users to perform tasks using clock time, such as \"8:00PM\". If you provide a `text` property, then CarKit uses the text to prompt the user instead, such as \"Before bed\" in the code above.\n\n* `duration`: If you provide a duration, CareKit prompts the user to perform the scheduled task within a window, such as \"8:00 - 10:00 PM\". You can also set the duration to `.allDay` if you don't wish to specify any time in particular.\n\n* `targetValues`: CareKit uses target values to determine if a user completed a specific task. See `OCKAdherenceAggregator` for more information.\n\n\n### Custom Stores and Types \u003Ca name=\"custom-store-and-types\">\u003C\u002Fa>\n\nThe `OCKStore` class that CareKit provides is a fast, secure, on-device store that serves most use cases. It may not fully meet the needs of all developers, so CareKit also allows you to write your own store. For example, you could write a wrapper around a web server, or even a simple JSON file. You can use any class that conforms to the `OCKStoreProtocol` in place of the default store.\n\nWriting a CareKit store adapter requires defining the entities that live in your store, and implementing asynchronous **Create**, **Read**, **Update**, and **Delete** methods for each. Stores are free to define their own types, as long as those types conform to a certain protocol. For example, if you're writing a store that can hold tasks, you might do it like this.\n\n```swift\nimport CareKitStore\n\nstruct MyTask: OCKAnyTask & Equatable & Identifiable {\n\n    \u002F\u002F MARK: OCKAnyTask\n    let id: String\n    let title: String\n    let schedule: String\n    \u002F* ... *\u002F\n\n    \u002F\u002F MARK: Custom Properties\n    let difficulty: DifficultyRating\n    \u002F* ... *\u002F\n}\n\nstruct MyTaskQuery: OCKAnyTaskQuery {\n\n    \u002F\u002F MARK: OCKAnyTaskQuery\n    let ids: [String]\n    let carePlanIDs: [String]\n    \u002F* ... *\u002F\n\n    \u002F\u002F MARK: Custom Properties\n    let difficult: DifficultyRating?\n}\n\nclass MyStore: OCKStoreProtocol {\n\n    typealias Task = MyTask\n    typealias TaskQuery = MyTaskQuery\n    \u002F* ... *\u002F\n\n    \u002F\u002F MARK: Task CRUD Methods\n    func fetchTasks(query: TaskQuery, callbackQueue: DispatchQueue, completion: @escaping OCKResultClosure\u003C[Task]>) { \u002F* ... *\u002F }\n    func addTasks(_ tasks: [Task], callbackQueue: DispatchQueue, completion: OCKResultClosure\u003C[Task]>?) { \u002F* ... *\u002F }\n    func updateTasks(_ tasks: [Task], callbackQueue: DispatchQueue, completion: OCKResultClosure\u003C[Task]>?) { \u002F* ... *\u002F }\n    func deleteTasks(_ tasks: [Task], callbackQueue: DispatchQueue, completion: OCKResultClosure\u003C[Task]>?) { \u002F* ... *\u002F }\n\n    \u002F* ... *\u002F\n}\n```\n\nUsing the four basic CRUD methods you supply, CareKit is able to use protocol extensions to imbue your store with extra functionality. For example, a store that implements the four CRUD methods for tasks automatically receives the following methods.\n\n```swift\nfunc fetchTask(withID id: String, callbackQueue: DispatchQueue, completion: @escaping OCKResultClosure\u003CTask>)\nfunc addTask(_ task: Task, callbackQueue: DispatchQueue, completion: OCKResultClosure\u003CTask>?)\nfunc updateTask(_ task: Task, callbackQueue: DispatchQueue, completion: OCKResultClosure\u003CTask>?)\nfunc deleteTask(_ task: Task, callbackQueue: DispatchQueue, completion: OCKResultClosure\u003CTask>?)\n```\n\nThe provided methods employ naive implementations. You're free to provide your own implementations that leverage the capabilities of your underlying data store to achieve greater performance or efficiency.\n\nIf you're considering implementing your own store, read over the protocol notes and documentation carefully.\n\n# Getting Help \u003Ca name=\"getting-help\">\u003C\u002Fa>\n\nGitHub is our primary forum for CareKit. Feel free to open up issues about questions, problems, or ideas.\n\n# License \u003Ca name=\"license\">\u003C\u002Fa>\n\nThis project is made available under the terms of a BSD license. See the [LICENSE](LICENSE) file.\n","CareKit 是一个开源软件框架，旨在帮助开发者创建能够使用户更好地理解和管理自己健康的移动应用。其核心功能包括通过视图控制器将用户界面和数据存储连接起来，利用 Combine 框架实现界面与数据的同步更新，并提供基于 Core Data 的解决方案来存储患者信息，同时支持自定义存储方式以满足特定需求。该框架特别适合用于开发健康管理、远程医疗监控或个人健康跟踪等场景的应用程序。使用 Swift 语言编写，具备良好的扩展性和定制性，适用于 iOS 平台。",2,"2026-06-11 03:10:41","top_language"]