Array
struct Array<Element> : _DestructorSafeContainer
-
Create a byte array filled with null bytes.
Declaration
Swift
public init(count: Int)
Parameters
count
The size of the byte array in bytes.
-
Return byte array as an hex encoded string.
Postcondition
bytes
=bytes.hexlify.unhexlify()
Examples
let hex = [0xDE, 0xAD, 0xBE, 0xEF].hexlify // hex == "deadbeef"
Declaration
Swift
public var hexlify: String { get }
-
Return byte array as a Base64 encoded string.
Postcondition
bytes
=bytes.b64encode().b64decode()
Declaration
Swift
public func b64encode() -> String
Return Value
A Base64 encoded string.