StoredProperty
public struct StoredProperty : Fragment
StoredProperty represents the code that defines a property of a Swift data structure
-
Creates a Stored Property instance.
Declaration
Swift
public init(access: Access, isMutable: Bool, name: String, type: String, value: String? = nil)
Parameters
access
Access level of the property
isMutable
Bool flag that determines if the property is a
let
orvar
name
The name of the property
type
The type of the property
value
The default value of the property
-
Access level of the property
Declaration
Swift
public let access: Access
-
Bool flag that determines if the property is a
let
orvar
Declaration
Swift
public let isMutable: Bool
-
The property’s name
Declaration
Swift
public let name: String
-
The property’s type
Declaration
Swift
public let type: String
-
The property’s default value
Declaration
Swift
public let value: String?
-
The SingleLineFragment as a String. It is the content appended with a newline.
Declaration
Swift
@inlinable public func renderContent() -> String
-
Transforms this StoredProperty instance into an Argument instance
Declaration
Swift
public var asArgument: Argument { get }