Variable
@objcMembers
public final class Variable : NSObject, SourceryModel, Typed, Annotated, Documented, Definition, Diffableextension Variable: NSCodingDefines variable
- 
                  
                  Variable name DeclarationSwift public let name: String
- 
                  
                  Variable type name DeclarationSwift public let typeName: TypeName
- 
                  
                  Variable type, if known, i.e. if the type is declared in the scanned sources. For explanation, see https://cdn.rawgit.com/krzysztofzablocki/Sourcery/master/docs/writing-templates.html#what-are-em-known-em-and-em-unknown-em-types DeclarationSwift public var type: Type?
- 
                  
                  Whether variable is computed and not stored DeclarationSwift public let isComputed: Bool
- 
                  
                  Whether variable is async DeclarationSwift public let isAsync: Bool
- 
                  
                  Whether variable throws DeclarationSwift public let `throws`: Bool
- 
                  
                  Type of thrown error if specified DeclarationSwift public let throwsTypeName: TypeName?
- 
                  
                  Whether variable is static DeclarationSwift public let isStatic: Bool
- 
                  
                  Variable read access level, i.e. internal,private,fileprivate,public,openDeclarationSwift public let readAccess: String
- 
                  
                  Variable write access, i.e. internal,private,fileprivate,public,open. For immutable variables this value is empty stringDeclarationSwift public let writeAccess: String
- 
                  
                  composed access level sourcery: skipJSExport DeclarationSwift public var accessLevel: (read: AccessLevel, write: AccessLevel) { get }
- 
                  
                  Whether variable is mutable or not DeclarationSwift public var isMutable: Bool { get }
- 
                  
                  Variable default value expression DeclarationSwift public var defaultValue: String?
- 
                  
                  Annotations, that were created with // sourcery: annotation1, other = “annotation value”, alterantive = 2 DeclarationSwift public var annotations: Annotations
- 
                  
                  DeclarationSwift public var documentation: Documentation
- 
                  
                  Variable attributes, i.e. @IBOutlet,@IBInspectableDeclarationSwift public var attributes: AttributeList
- 
                  
                  Modifiers, i.e. privateDeclarationSwift public var modifiers: [SourceryModifier]
- 
                  
                  Whether variable is final or not DeclarationSwift public var isFinal: Bool { get }
- 
                  
                  Whether variable is lazy or not DeclarationSwift public var isLazy: Bool { get }
- 
                  
                  Whether variable is dynamic or not DeclarationSwift public var isDynamic: Bool { get }
- 
                  
                  Reference to type name where the variable is defined, nil if defined outside of any enum,struct,classetcDeclarationSwift public internal(set) var definedInTypeName: TypeName? { get }
- 
                  
                  Reference to actual type name where the method is defined if declaration uses typealias, otherwise just a definedInTypeNameDeclarationSwift public var actualDefinedInTypeName: TypeName? { get }
- 
                  
                  Reference to actual type where the object is defined, nil if defined outside of any enum,struct,classetc or type is unknownDeclarationSwift public var definedInType: Type?
- 
                  
                  DeclarationSwift public func diffAgainst(_ object: Any?) -> DiffableResult
- 
                  
                  Whether type is optional. Shorthand for typeName.isOptionalDeclarationSwift public var isOptional: Bool { get }
- 
                  
                  Whether type is implicitly unwrapped optional. Shorthand for typeName.isImplicitlyUnwrappedOptionalDeclarationSwift public var isImplicitlyUnwrappedOptional: Bool { get }
- 
                  
                  Type name without attributes and optional type information. Shorthand for typeName.unwrappedTypeNameDeclarationSwift public var unwrappedTypeName: String { get }
- 
                  
                  Whether type is a tuple. Shorthand for typeName.isTupleDeclarationSwift public var isTuple: Bool { get }
- 
                  
                  Whether type is a closure. Shorthand for typeName.isClosureDeclarationSwift public var isClosure: Bool { get }
- 
                  
                  Whether type is an array. Shorthand for typeName.isArrayDeclarationSwift public var isArray: Bool { get }
- 
                  
                  Whether type is a set. Shorthand for typeName.isSetDeclarationSwift public var isSet: Bool { get }
- 
                  
                  Whether type is a dictionary. Shorthand for typeName.isDictionaryDeclarationSwift public var isDictionary: Bool { get }
 View on GitHub
View on GitHub Variable Class Reference
        Variable Class Reference