Socket
Book a DemoInstallSign in
Socket

uuid_helper

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

uuid_helper

0.1.2
bundlerRubygems
Version published
Maintainers
1
Created
Source

UuidHelper

The idea is to provide some helper methods like:

  ''.to_uuid
  nil.to_uuid

Installation

Add this line to your application's Gemfile:

gem 'uuid_helper'

And then execute:

$ bundle

Or install it yourself as:

$ gem install uuid_helper

Usage

Strings

"".to_uuid             
=> #<UUID:0xXXXXXXX UUID:00000000-0000-0000-0000-000000000000>

"\x9ANV\xD2\x990\x11\xE1\xA7h\x00\x13r\x84\xC8\xDF".to_uuid
=> #<UUID:0xXXXXXXX UUID:9a4e56d2-9930-11e1-a768-00137284c8df>
    
"3F3B4A403BF011E181F000137284C8DF".to_uuid
=> #<UUID:0xXXXXXXX UUID:3f3b4a40-3bf0-11e1-81f0-00137284c8df>
 
"3f3b4a40-3bf0-11e1-81f0-00137284c8df".to_uuid
=> #<UUID:0xXXXXXXX UUID:3f3b4a40-3bf0-11e1-81f0-00137284c8df>  

NilClass

nil.to_uuid
=> #<UUID:0xXXXXXXX UUID:3f3b4a40-3bf0-11e1-81f0-00137284c8df>  

Contributing

  • Fork it
  • Create your feature branch (git checkout -b my-new-feature)
  • Commit your changes (git commit -am 'Added some feature')
  • Push to the branch (git push origin my-new-feature)
  • Create new Pull Request

FAQs

Package last updated on 07 Sep 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.