Skip to content

vanshg/KrazyKotlin

Repository files navigation

KrazyKotlin is a collection of useful Kotlin Extension - inspired by SwifterSwift.

More extensions are on the way. If you have any requests, create an issue or submit a PR

Download

Download via Gradle:

compile 'com.vanshgandhi:krazykotlin:1.0.0'

or Maven:

<dependency>
  <groupId>com.vanshgandhi</groupId>
  <artifactId>krazykotlin</artifactId>
  <version>1.0.0</version>
  <type>pom</type>
</dependency>

Contributing

There is a list of outstanding work that needs to be done in TODO.md. All contributions are welcome

List of Extensions

  • String
    • base64Decoded
    • base64Encoded
    • camelCased
    • containsLetters
    • containsNumbers
    • isAlphanumeric
    • isAlphabetic
    • isNumeric
    • isEmail
    • isUrl
    • mostCommonCharacter
  • Date
    • calendar
    • isInFuture
    • isInPast
    • isToday
    • isTomorrow
    • isWeekend
    • isWeekday
    • iso8601
    • roundToMinute
    • roundToFiveMinutes
    • roundToTenMinutes
    • roundToFifteenMinutes
    • roundToHalfHour
    • roundToHour
    • millisecondsSince
    • secondsSince
    • minutesSince
    • hoursSince
    • daysSince
    • weeksSince
    • monthsSince
    • yearsSince
    • plus
    • minus
  • Int
    • random
  • Boolean
    • intValue

License

MIT License

Copyright (c) 2017 Vansh Gandhi

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.