Latest 1.0.8
Homepage https://github.com/daisuke-t-jp/LLAExtensionPack
License MIT
Platforms ios 10.0, requires ARC
Authors

LLAExtensionPack

Platform
Language Swift%204.2
Carthage compatible
Cocoapods
Build Status

Swift Extension Pack 📦

Install

Carthage

github "daisuke-t-jp/LLAExtensionPack"

CocoaPods

use_frameworks!

target 'target' do
pod 'LLAExtensionPack'
end

Extensions

Foundation

CoreGraphics

CoreAnimation

UIKit

CoreLocation

Example

Swift code

import LLAExtensionPack

/**
 * Example "String"
 */
// Compare
"string".isEqual("String", caseInsensitive: true) // true

// Find
"string".hasPrefix("Str", caseInsensitive: true) // true
"string".hasSuffix("Ing", caseInsensitive: true) // true

// Substring
"string"[str.startIndex(0)!...str.startIndex(2)!] // "str"
"string".substring(NSMakeRange(1, 3)), "tri"

// Subscript
"string"[0...2] // "str"
"string"[1...3] // "tri"

// Inspect
"1".isNumeric // true
"ABC".isNumeric // false

// Replace
"string".replace("str", replacement: "STR") // "STRing"
"string".replace("STR", replacement: "", caseInsensitive: true) // "ing"

// Remove
"string".remove("str") // "ing"
"string".remove("STR", caseInsensitive: true) // "ing"

// Encode
"abcABC1234/?-._~".urlEncoding // "abcABC1234/?-._~"
":#[]@!$&'()*+,;=".urlEncoding // "%3A%23%5B%5D%40%21%24%26%27%28%29%2A%2B%2C%3B%3D"

// Hash
"string".md2 // "a06d078cf87b3349d4400afca892ed42"
"string".md4 // "70a2421dd08cce128b3af8ad1dfa74ac"
"string".md5 // "b45cffe084dd3d20d928bee85e7b0f21"
"string".sha1 // "ecb252044b5ea0f679ee78ec1a12904739e2904d"
"string".sha224 // "474b4afcaa4303cfc8f697162784293e812f12e2842551d726db8037"
"string".sha256 // "473287f8298dba7163a897908958f7c0eae733e25d2e027992ea2edc9bed2fa8"
"string".sha384 // "36396a7e4de3fa1c2156ad291350adf507d11a8f8be8b124a028c5db40785803ca35a7fc97a6748d85b253babab7953e"
"string".sha512 // "2757cb3cafc39af451abb2697be79b4ab61d63d74d85b0418629de8c26811b529f3f3780d0150063ff55a2beee74c4ec102a2a2731a1f1f7f10d473ad18a6a87"

Latest podspec

{
    "name": "LLAExtensionPack",
    "version": "1.0.8",
    "summary": "Swift Extension Packud83dudce6",
    "description": "Swift Extension Pack ud83dudce6",
    "homepage": "https://github.com/daisuke-t-jp/LLAExtensionPack",
    "screenshots": "https://raw.githubusercontent.com/daisuke-t-jp/LLAExtensionPack/master/doc/header.png",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "daisuke-t-jp": "[email protected]"
    },
    "platforms": {
        "ios": "10.0"
    },
    "source": {
        "git": "https://github.com/daisuke-t-jp/LLAExtensionPack.git",
        "tag": "1.0.8"
    },
    "source_files": [
        "LLAExtensionPack/*.{h,swift}",
        "LLAExtensionPack/CoreAnimation/*.swift",
        "LLAExtensionPack/CoreGraphics/*.swift",
        "LLAExtensionPack/CoreLocation/*.swift",
        "LLAExtensionPack/Foundation/*.swift",
        "LLAExtensionPack/UIKit/*.swift"
    ],
    "swift_version": "4.2",
    "requires_arc": true
}

Pin It on Pinterest

Share This