perfolation-unit


License

License

MIT
GroupId

GroupId

com.outr
ArtifactId

ArtifactId

perfolation-unit_sjs0.6_2.12
Last Version

Last Version

1.1.5
Release Date

Release Date

Type

Type

jar
Description

Description

perfolation-unit
perfolation-unit
Project URL

Project URL

https://github.com/outr/perfolation
Project Organization

Project Organization

com.outr
Source Code Management

Source Code Management

https://github.com/outr/perfolation

Download perfolation-unit_sjs0.6_2.12

How to add to project

<!-- https://jarcasting.com/artifacts/com.outr/perfolation-unit_sjs0.6_2.12/ -->
<dependency>
    <groupId>com.outr</groupId>
    <artifactId>perfolation-unit_sjs0.6_2.12</artifactId>
    <version>1.1.5</version>
</dependency>
// https://jarcasting.com/artifacts/com.outr/perfolation-unit_sjs0.6_2.12/
implementation 'com.outr:perfolation-unit_sjs0.6_2.12:1.1.5'
// https://jarcasting.com/artifacts/com.outr/perfolation-unit_sjs0.6_2.12/
implementation ("com.outr:perfolation-unit_sjs0.6_2.12:1.1.5")
'com.outr:perfolation-unit_sjs0.6_2.12:jar:1.1.5'
<dependency org="com.outr" name="perfolation-unit_sjs0.6_2.12" rev="1.1.5">
  <artifact name="perfolation-unit_sjs0.6_2.12" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.outr', module='perfolation-unit_sjs0.6_2.12', version='1.1.5')
)
libraryDependencies += "com.outr" % "perfolation-unit_sjs0.6_2.12" % "1.1.5"
[com.outr/perfolation-unit_sjs0.6_2.12 "1.1.5"]

Dependencies

compile (3)

Group / Artifact Type Version
org.scala-lang : scala-library jar 2.12.8
com.outr : perfolation_sjs0.6_2.12 jar 1.1.5
org.scala-js : scalajs-library_2.12 jar 0.6.28

test (2)

Group / Artifact Type Version
org.scala-js : scalajs-test-interface_2.12 jar 0.6.28
org.scalatest : scalatest_sjs0.6_2.12 jar 3.1.0-SNAP13

Project Modules

There are no modules declared in this project.

perfolation

Build Status Gitter Maven Central Latest version

Performance focused interpolation

Based on the original work of Dmitry Komanov (https://medium.com/@dkomanov/scala-string-interpolation-performance-21dc85e83afd).

Note: the current version of the interpolation Macro is a complete rip-off of fast-string-interpolator as their performance is superior, but they don't currently support Scala.js or Scala Native.

What is it?

As shown in the article by Dmitry Komanov, Scala's s"" and f"" interpolation are incredibly slow. This is an effort make String interpolation as fast as it should be with the additional features of type-safe formatting with code-completion.

Main Features

String interpolation

Original:

s"Interpolation of $string"

Better:

p"Interpolation of $string"

Type-safe alternatives to String format

Original:

f"Time: $timeInMillis%tT, Date: $timeInMillis%tD"

Better:

p"Time: ${timeInMillis.t.T}, Date: ${timeInMillis.t.D}"

Getting Started

Support for Scala (2.11, 2.12), Scala.js (2.11, 2.12), and ScalaNative (2.11)

SBT Dependencies:

libraryDependencies += "com.outr" %%% "perfolation" % "1.0.4"

Usage:

Simply import perfolation._ and start using:

import perfolation._

val greeting = "Hello, World!"
val time = System.currentTimeMillis()

println(p"$greeting @ ${time.t.T}")
com.outr

OUTR Technologies

Versions

Version
1.1.5