-
Notifications
You must be signed in to change notification settings - Fork 2
files core monitor alertmodels swift a16622e2
ventaphobia edited this page Apr 23, 2026
·
1 revision
- Area: Legacy alert system.
- This page records the file's current repository role, source metadata, and recent commit history.
- Review nearby tests and commit pages before changing this file.
| Field | Value |
|---|---|
| Source path | Core-Monitor/AlertModels.swift |
| Wiki area | Legacy alert system |
| Exists in current checkout | True |
| Size | 21098 bytes |
| Binary | False |
| Line count | 409 |
| Extension | .swift |
Foundation
| Kind | Name | Line |
|---|---|---|
| enum | AlertCategory |
2 |
| enum | AlertSeverity |
22 |
| enum | AlertRuleKind |
44 |
| struct | AlertThreshold |
166 |
| struct | AlertRuleConfig |
174 |
| enum | AlertPreset |
185 |
| enum | AlertNotificationPolicy |
212 |
| struct | AlertEvent |
228 |
| struct | AlertRuleRuntime |
239 |
| struct | AlertActiveState |
265 |
| struct | AlertStore |
278 |
| extension | AlertPreset |
303 |
| func | configurations |
305 |
| Commit | Date | Subject |
|---|---|---|
ce9e812 |
2026-04-16 | Fix Xcode 16.2 CI compatibility |
5b96f6f |
2026-04-16 | Fix Xcode 16.2 CI compatibility |
1ff7bdb |
2026-04-16 | Refine helper health states and service alerts |
7185d36 |
2026-04-15 | Improve fan control and alert surfaces |
- Prefer focused changes that respect the ownership described above.
- If this file touches helper trust, SMC writes, startup, or permissions, update the relevant support docs and tests.
- If this file is generated or an asset manifest, verify the producing workflow instead of hand-editing generated payloads.
import Foundation
enum AlertCategory: String, Codable, CaseIterable, Identifiable {
case thermal
case performance
case fanSafety
case battery
case services
var id: String { rawValue }
var title: String {
switch self {
case .thermal: return "Thermal"
case .performance: return "Performance"
case .fanSafety: return "Fan Safety"
case .battery: return "Battery"
case .services: return "Services"
}
}
}
enum AlertSeverity: Int, Codable, CaseIterable, Comparable, Identifiable {
case none = 0
case info = 1
case warning = 2
case critical = 3
var id: Int { rawValue }
static func < (lhs: AlertSeverity, rhs: AlertSeverity) -> Bool {
lhs.rawValue < rhs.rawValue
}
var title: String {
switch self {
case .none: return "Stable"
case .info: return "Info"
case .warning: return "Warning"
case .critical: return "Critical"
- Home
- Start Here
- Product Overview
- Runtime Architecture
- Monitoring Pipeline
- Fan Control
- Privileged Helper
- Touch Bar
- Release Automation
- Security Model
- File Index (279)
- Every Commit (401)
- Chronological Change Log
- Removed Parts
- All Deleted Paths
- Branches And Tags
- Wiki Manifest
- Start Here
- Product Overview
- Source Map
- Runtime Architecture
- App Startup And Lifecycle
- Dashboard Architecture
- Menu Bar Architecture
- Monitoring Pipeline
- Snapshot Trends And Freshness
- CPU GPU Memory Disk Network
- Battery Power And Thermals
- SMC And Apple Silicon
- Fan Control
- Custom Fan Curves
- Privileged Helper
- XPC Trust Boundary
- Helper Diagnostics
- Touch Bar Architecture
- Touch Bar Customization
- Weather And Location
- Privacy And Permissions
- Onboarding And Help
- Legacy Alerts
- Kernel Panic Weird Mode