Socket
Book a DemoInstallSign in
Socket

lexical_uuid

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lexical_uuid

0.2.1
bundlerRubygems
Version published
Maintainers
1
Created
Source

= lexical_uuid

UUIDs that are byte-ordered lamport clocks (timestamp, worker_id). Much simpler than type-1 UUID's crappy, weirdo layout.

= Disclaimer

This won't work on 32bit platforms. Fuck 32bit platforms.

= Install

sudo gem install lexical_uuid

= Usage

ree-1.8.7-2010.02 > LexicalUUID.new => #<LexicalUUID:0x1019400f0 @worker_id=2842420286492008582, @timestamp=1281991807929511> r ee-1.8.7-2010.02 > LexicalUUID.new.to_guid => "00048df6-faef-2bb5-2772-4e30d6b86086" r ee-1.8.7-2010.02 > LexicalUUID.new.to_bytes => "\000\004\215\366\373"\022\352'rN0\326\270206" r ee-1.8.7-2010.02 > LexicalUUID.new(LexicalUUID.new.to_guid) => #<LexicalUUID:0x101936118 @worker_id=2842420286492008582, @timestamp=1281991837642798> r ee-1.8.7-2010.02 > LexicalUUID.new(LexicalUUID.new.to_bytes) => #<LexicalUUID:0x101931690 @worker_id=2842420286492008582, @timestamp=1281991842330188> r ee-1.8.7-2010.02 > LexicalUUID.new(Time.now) => #<LexicalUUID:0x10192df18 @worker_id=2842420286492008582, @timestamp=1281991847641387>

== Credits

  • The idea was basically stolen from Coda Hale (@coda).
  • I borrowed some code from simple_uuid by @evan, @rk, etc.

== Copyright

Copyright (c) 2010 James Golick. See LICENSE for details.

FAQs

Package last updated on 12 Oct 2011

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.