-
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.
Merge pull request #280 from boostcampwm-2024/task/singletone_review
task singletone관련 review를 반영
- Loading branch information
Showing
10 changed files
with
69 additions
and
16 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
7 changes: 7 additions & 0 deletions
7
Projects/Features/MainFeature/Demo/Sources/MockBroadcastState.swift
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,7 @@ | ||
import Combine | ||
|
||
import MainFeatureInterface | ||
|
||
final class MockBroadcastState: BroadcastStateProtocol { | ||
var isBroadcasting: PassthroughSubject<Bool, Never> = .init() | ||
} |
5 changes: 5 additions & 0 deletions
5
Projects/Features/MainFeature/Interface/BroadcastStateProtocol.swift
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,5 @@ | ||
import Combine | ||
|
||
public protocol BroadcastStateProtocol { | ||
var isBroadcasting: PassthroughSubject<Bool, Never> { get } | ||
} |
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
10 changes: 7 additions & 3 deletions
10
Projects/Features/MainFeature/Sources/Utilities/BroadcastState.swift
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 |
---|---|---|
@@ -1,7 +1,11 @@ | ||
import Combine | ||
|
||
final class BroadcastState { | ||
static let shared = BroadcastState() | ||
import MainFeatureInterface | ||
|
||
public final class BroadcastState: BroadcastStateProtocol { | ||
public static let shared = BroadcastState() | ||
|
||
public let isBroadcasting: PassthroughSubject<Bool, Never> = .init() | ||
|
||
let isBroadcasting: PassthroughSubject<Bool, Never> = .init() | ||
private init() {} | ||
} |
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
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