-
Notifications
You must be signed in to change notification settings - Fork 5
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
1 parent
1a7e0db
commit 60b8304
Showing
2 changed files
with
43 additions
and
0 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
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,39 @@ | ||
// | ||
// FirebaseUseCase.swift | ||
// Project_Timer | ||
// | ||
// Created by Kang Minsang on 2024/06/29. | ||
// Copyright © 2024 FDEE. All rights reserved. | ||
// | ||
|
||
import Foundation | ||
import Combine | ||
|
||
final class FirebaseUseCase { | ||
private let repository: FirebaseRepository // TODO: 프로토콜로 수정 | ||
|
||
init(repository: FirebaseRepository) { | ||
self.repository = repository | ||
} | ||
|
||
func getAppVersion() -> AnyPublisher<AppLatestVersionInfo, NetworkError> { | ||
return self.repository.getAppVersion() | ||
} | ||
|
||
func getServerURL() -> AnyPublisher<String, NetworkError> { | ||
return self.repository.getServerURL() | ||
} | ||
|
||
func getTiTiFunctions() -> AnyPublisher<[FunctionInfo], NetworkError> { | ||
return self.repository.getTiTiFunctions() | ||
} | ||
|
||
func getUpdateHistorys() -> AnyPublisher<[UpdateHistoryInfo], NetworkError> { | ||
return self.repository.getUpdateHistorys() | ||
} | ||
|
||
func getYoutubeLink() -> AnyPublisher<String, NetworkError> { | ||
return self.repository.getYoutubeLink() | ||
} | ||
} | ||
|