scalus.utils

package scalus.utils

Members list

Type members

Classlikes

case object BuildInfo

This object was generated by sbt-buildinfo.

This object was generated by sbt-buildinfo.

Attributes

Supertypes
trait Singleton
trait Product
trait Mirror
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
Self type
BuildInfo.type
object Hex

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
Hex.type

Low-priority Pretty instances for automatic ADT derivation. These are lower priority than manually defined instances.

Low-priority Pretty instances for automatic ADT derivation. These are lower priority than manually defined instances.

Attributes

Supertypes
class Object
trait Matchable
class Any
Known subtypes
object Pretty
object Macros

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
Macros.type
case class PlutusTextEnvelope(`type`: String, description: String, cborHex: String)

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
trait Pretty[A]

Typeclass for pretty printing values to org.typelevel.paiges.Doc.

Typeclass for pretty printing values to org.typelevel.paiges.Doc.

Pretty instances should be defined in companion objects of the types they print. This typeclass supports two rendering modes:

  • pretty: concise, single-line friendly output
  • prettyDetailed: expanded, multi-line output with full details

Example usage:

import scalus.utils.Pretty.given

val value: Value = ...
println(value.show)           // concise output
println(value.showDetailed)   // detailed output
println(value.showHighlighted) // with XTerm colors

Attributes

Companion
object
Supertypes
class Object
trait Matchable
class Any
Known subtypes

Attributes

Companion
trait
Supertypes
class Object
trait Matchable
class Any
Self type
Pretty.type
enum Style

Pretty printing style: Normal (plain text) or XTerm (with color highlighting)

Pretty printing style: Normal (plain text) or XTerm (with color highlighting)

Attributes

Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
object Utils

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
Utils.type

Extensions

Extensions

extension [A](a: A)(using p: Pretty[A])
def pretty: Doc

Get pretty Doc (concise)

Get pretty Doc (concise)

Attributes

def prettyDetailed: Doc

Get pretty Doc (detailed)

Get pretty Doc (detailed)

Attributes

Get pretty Doc with XTerm colors (detailed)

Get pretty Doc with XTerm colors (detailed)

Attributes

def prettyXTerm: Doc

Get pretty Doc with XTerm colors (concise)

Get pretty Doc with XTerm colors (concise)

Attributes

def show: String

Render to string (concise, 80 columns)

Render to string (concise, 80 columns)

Attributes

def showDetailed: String

Render to string (detailed, 80 columns)

Render to string (detailed, 80 columns)

Attributes

Render to string with XTerm colors (detailed, 80 columns)

Render to string with XTerm colors (detailed, 80 columns)

Attributes

def showHighlighted: String

Render to string with XTerm colors (concise, 80 columns)

Render to string with XTerm colors (concise, 80 columns)

Attributes

extension [T](future: Future[T])
def await(timeout: Duration = ...): T

Extension method to block and await the result of a Future.

Extension method to block and await the result of a Future.

Value parameters

timeout

maximum duration to wait (default: infinite)

Attributes

Returns

the result of the Future

Throws
Exception

if the Future fails

java.util.concurrent.TimeoutException

if the timeout is exceeded