Files
SwiftLint/Source/SwiftLintFramework/Extensions/Configuration+IndentationStyle.swift
T
2018-11-19 09:51:12 -08:00

17 lines
449 B
Swift

public extension Configuration {
enum IndentationStyle: Equatable {
case tabs
case spaces(count: Int)
public static var `default` = spaces(count: 4)
internal init?(_ object: Any?) {
switch object {
case let value as Int: self = .spaces(count: value)
case let value as String where value == "tabs": self = .tabs
default: return nil
}
}
}
}