This repository has been archived by the owner on May 2, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jaesung Lee
committed
Jun 4, 2023
1 parent
a3aa994
commit 66bfb1c
Showing
3 changed files
with
71 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// | ||
// Satellite.GPS.swift | ||
// | ||
// | ||
// Created by Jaesung Lee on 2023/06/04. | ||
// | ||
|
||
import Foundation | ||
|
||
extension Satellite { | ||
/// Start Global Printing System | ||
public func _startGPS() { | ||
self._isGPSEnabled = true | ||
} | ||
|
||
/// Start Global Printing System | ||
public func _endGPT() { | ||
self._isGPSEnabled = false | ||
} | ||
|
||
public func showGPT(_ stringValue: String, function: StaticString = #function, file: StaticString = #fileID, line: UInt = #line) { | ||
guard _isGPSEnabled else { return } | ||
let log = ("\n🛰️ Satellite: \(host)\t\(Date())\n📄file: \(file)\tline: \(line)\tfunction: \(function)\n📡 \(stringValue)\n") | ||
print(log) | ||
_gpsLogs.append(log) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters