Skip to content

Commit a4e8f5a

Browse files
committed
Add more missing documentation
1 parent ed80df1 commit a4e8f5a

3 files changed

Lines changed: 17 additions & 9 deletions

File tree

Sources/Processed/Loadable/Loadable.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -346,4 +346,6 @@ extension Loadable {
346346
}
347347
}
348348

349+
/// An object providing an interface for automatic control over the loading process,
350+
/// through a set of easy to use methods.
349351
public typealias LoadableBinding<Value> = Loadable<Value>.Binding

Sources/Processed/Process/Process.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,4 +347,6 @@ extension Process {
347347
}
348348
}
349349

350+
/// An object providing an interface for automatic control over the loading process,
351+
/// through a set of easy to use methods.
350352
public typealias ProcessBinding<SingleProcess: Equatable> = Process<SingleProcess>.Binding

Sources/Processed/Process/ProcessState.swift

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,20 +22,24 @@
2222

2323
import Foundation
2424

25-
/// Represents the possible states of a process.
25+
/// An enumeration representing the possible states of a process.
2626
public enum ProcessState<ProcessID> {
27+
28+
/// Represents the state where the process is currently not running and has no result or error.
2729
case idle
30+
31+
/// Represents the state where the process is currently running.
32+
/// - Parameter ProcessID: The process that is running.
2833
case running(ProcessID)
34+
35+
/// Represents the state where the process has finished with an error.
36+
/// - Parameter process: The process that has thrown an error.
37+
/// - Parameter error: The thrown error.
2938
case failed(process: ProcessID, error: Swift.Error)
39+
40+
/// Represents the state where the process has finished successfully.
41+
/// - Parameter process: The process that has finished.
3042
case finished(ProcessID)
31-
32-
public init(initialState: ProcessState) {
33-
self = initialState
34-
}
35-
36-
public init(initialState: ProcessState) where ProcessID == SingleProcess {
37-
self = initialState
38-
}
3943
}
4044

4145
extension ProcessState: CustomDebugStringConvertible {

0 commit comments

Comments
 (0)