Packages

  • package root
    Definition Classes
    root
  • package io
    Definition Classes
    root
  • package jvm
    Definition Classes
    io
  • package uuid

    This package holds the optimized Scala wrapper for java.util.UUID.

    This package holds the optimized Scala wrapper for java.util.UUID.

    To use the wrapper, either extend the Imports trait or import this package object to bring the implicit into scope that way:

    scala> import io.jvm.uuid._
    import io.jvm.uuid._
    
    scala> val foo = classOf[UUID]
    foo: Class[io.jvm.uuid.UUID] = class java.util.UUID
    
    scala> val bar = UUID(1, 2)
    bar: io.jvm.uuid.UUID = 00000000-0000-0001-0000-000000000002
    
    scala> val UUID(baz) = "00112233-4455-6677-8899-aAbBcCdDeEfF"
    baz: io.jvm.uuid.UUID = 00112233-4455-6677-8899-aabbccddeeff
    Definition Classes
    jvm
  • Imports
  • RichUUID
  • StaticUUID
t

io.jvm.uuid

Imports

trait Imports extends AnyRef

This trait holds all the components required for completing the pimp-my-library pattern:

  • an UUID type alias
  • an UUID singleton object with static forwarders and new UUID factories
  • an implicit def to provide extensions on the legacy java.util.UUID class

Use case is to use it by extending it with your package object:

package com
package object example extends io.jvm.uuid.Imports

Now any class in the com.example package will be able to access rich UUID functionality:

package com.example
class User(val id: UUID = UUID.random)
Source
Imports.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Imports
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. final type UUID = java.util.UUID

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final val UUID: StaticUUID
  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  9. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  10. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  11. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  12. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  13. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  14. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  15. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  16. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  17. implicit final def toRichUUID(uuid: UUID): RichUUID
  18. def toString(): String
    Definition Classes
    AnyRef → Any
  19. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  20. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  21. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from AnyRef

Inherited from Any

Ungrouped