padding(_:)
Returns space padding
static func padding(_ width: Int) -> String
<param>
<return>
Returns space padding
static func padding(_ width: Int) -> String
<param>
<return>
import SwiftSoup
class StringUtil
A minimal String utility class. Designed for internal SwiftSoup use only.
@frozen struct Int
A signed integer value type.
@frozen struct String
A Unicode string value that is a collection of characters.
static let backshashRBackslashNUTF8: [UInt8]
static let backslashFUTF8: [UInt8]
static let backslashNUTF8: [UInt8]
static let backslashRUTF8: [UInt8]
static let backslashTUTF8: [UInt8]
static let spaceUTF8: [UInt8]
static func appendNormalisedWhitespace(_ accum: StringBuilder, string: String, stripLeading: Bool)
After normalizing the whitespace within a string, appends it to a string builder.
static func appendNormalisedWhitespace(_ accum: StringBuilder, string: [UInt8], stripLeading: Bool)
After normalizing the whitespace within a string, appends it to a string builder.
static func isBlank(_ string: String) -> Bool
Tests if a string is blank: null, emtpy, or only whitespace (” “, \r\n, \t, etc)
static func isNumeric(_ string: String) -> Bool
Tests if a string is numeric, i.e. contains only digit characters
static func isWhitespace(_ c: Character) -> Bool
Tests if a code point is “whitespace” as defined in the HTML spec.
static func isWhitespace(_ bytes: [UInt8]) -> Bool
Tests if a code point is “whitespace” as defined in the HTML spec.
static func join(_ strings: OrderedSet<String>, sep: String) -> String
static func join(_ strings: [String], sep: String) -> String
Join a collection of strings by a seperator
static func join(_ strings: Set<String>, sep: String) -> String
static func normaliseWhitespace(_ string: String) -> String
Normalise the whitespace within this string; multiple spaces collapse to a single, and all whitespace characters (e.g. newline, tab) convert to a simple space
static func normaliseWhitespace(_ string: [UInt8]) -> String
Normalise the whitespace within this string; multiple spaces collapse to a single, and all whitespace characters (e.g. newline, tab) convert to a simple space
static func resolve(_ base: URL, relUrl: String) -> URL?
Create a new absolute URL, from a provided existing absolute URL and a relative URL component.
static func resolve(_ baseUrl: String, relUrl: String) -> String
Create a new absolute URL, from a provided existing absolute URL and a relative URL component.