Delimiters
Type of delimiters to emit around any subfragments.
enum Delimiters
Type of delimiters to emit around any subfragments.
enum Delimiters
import PackageModel
struct SourceCodeFragment
Helper type to emit source code. Represents one node of source code, as an arbitrary string followed by an optional child list, optionally enclosed in a pair of delimiters.
case none
case brackets
case parentheses
init(_ literal: String, delimiters: Delimiters = .none, multiline: Bool = true, subnodes: [SourceCodeFragment]? = nil)
init(key: String? = nil, boolean: Bool)
Initializes a SourceCodeFragment for a boolean in a generated manifest.
init(key: String? = nil, enum: String, string: String)
Initializes a SourceCodeFragment for an enum in a generated manifest.
init(key: String? = nil, enum: String, strings: [String])
Initializes a SourceCodeFragment for an enum in a generated manifest.
init(key: String? = nil, enum: String, subnodes: [SourceCodeFragment]? = nil, multiline: Bool = false)
Initializes a SourceCodeFragment for an enum in a generated manifest.
init(key: String? = nil, integer: Int)
Initializes a SourceCodeFragment for an integer in a generated manifest.
init(key: String? = nil, string: String)
Initializes a SourceCodeFragment for a quoted string in a generated manifest.
init(key: String? = nil, strings: [String], multiline: Bool = false)
Initializes a SourceCodeFragment for a string list in a generated manifest.
init(key: String? = nil, subnode: SourceCodeFragment)
Initializes a SourceCodeFragment for a node in a generated manifest.
init(key: String? = nil, subnodes: [SourceCodeFragment], multiline: Bool = true)
Initializes a SourceCodeFragment for a list of nodes in a generated manifest.
protocol Equatable
A type that can be compared for value equality.
protocol Hashable : Equatable
A type that can be hashed into a Hasher
to produce an integer hash value.
static func != (lhs: Self, rhs: Self) -> Bool
Returns a Boolean value indicating whether two values are not equal.