Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/atomaka/base52
Encode and Decode Base 52 Values in Ruby
https://github.com/atomaka/base52
Last synced: 15 days ago
JSON representation
Encode and Decode Base 52 Values in Ruby
- Host: GitHub
- URL: https://github.com/atomaka/base52
- Owner: atomaka
- Created: 2012-09-24T06:24:20.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2012-10-15T04:34:06.000Z (about 12 years ago)
- Last Synced: 2023-03-12T07:24:48.861Z (over 1 year ago)
- Language: Ruby
- Homepage:
- Size: 97.7 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
#Base52
Encode and Decode Base 52 Values
##Description
Implement functionality to the base Integer class to convert an integer into an equivalent base 52 string using the character set 0-9, A-Z, a-z excluding
vowels. Additionally, implement functionality to the base String class to
convert a base 52 string back to an integer.##Install
```
$ gem install base52
```## Usage
```
require 'base52'1000000000.to_52
=> "2clyTD""2clyTD".from_52
=> 1000000000
```##License
The MIT License
Copyright (c) 2012 Andrew Tomaka
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.