implicit object stringInstance extends Monoid[String] with Show[String] with Equal[String] with Order[String] with IsEmpty[[α]String]
- Source
- String.scala
- Alphabetic
- By Inheritance
- stringInstance
- IsEmpty
- PlusEmpty
- Plus
- Order
- Equal
- Show
- Monoid
- Semigroup
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
- trait EqualLaw extends AnyRef
- Definition Classes
- Equal
- trait IsEmptyLaw extends EmptyLaw
- Definition Classes
- IsEmpty
- trait MonoidLaw extends SemigroupLaw
Monoid instances must satisfy scalaz.Semigroup.SemigroupLaw and 2 additional laws:
Monoid instances must satisfy scalaz.Semigroup.SemigroupLaw and 2 additional laws:
- left identity:
forall a. append(zero, a) == a
- right identity :
forall a. append(a, zero) == a
- Definition Classes
- Monoid
- left identity:
- trait OrderLaw extends EqualLaw
- Definition Classes
- Order
- trait PlusLaw extends AnyRef
- Definition Classes
- Plus
- trait EmptyLaw extends PlusLaw
- Definition Classes
- PlusEmpty
- trait SemigroupApply extends Apply[[α]F]
- Attributes
- protected[this]
- Definition Classes
- Semigroup
- trait SemigroupCompose extends Compose[[α, β]F]
- Attributes
- protected[this]
- Definition Classes
- Semigroup
- trait SemigroupLaw extends AnyRef
A semigroup in type F must satisfy two laws:
A semigroup in type F must satisfy two laws:
- closure:
∀ a, b in F, append(a, b)
is also inF
. This is enforced by the type system. - associativity:
∀ a, b, c
inF
, the equationappend(append(a, b), c) = append(a, append(b , c))
holds.
- Definition Classes
- Semigroup
- closure:
- type SA[α] = String
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##(): Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def append(f1: String, f2: => String): String
The binary operation to combine
f1
andf2
.The binary operation to combine
f1
andf2
.Implementations should not evaluate the by-name parameter
f2
if result can be determined byf1
.- Definition Classes
- stringInstance → Semigroup
- final def applicative: Applicative[[α]String]
A monoidal applicative functor, that implements
point
andap
with the operationszero
andappend
respectively.A monoidal applicative functor, that implements
point
andap
with the operationszero
andappend
respectively. Note that the type parameterα
inApplicative[λ[α => F]]
is discarded; it is a phantom type. As such, the functor cannot support scalaz.Bind.- Definition Classes
- Monoid
- def apply(x: String, y: String): Ordering
- Definition Classes
- Order
- final def apply: Apply[[α]String]
An scalaz.Apply, that implements
ap
withappend
.An scalaz.Apply, that implements
ap
withappend
. Note that the type parameterα
inApply[λ[α => F]]
is discarded; it is a phantom type. As such, the functor cannot support scalaz.Bind.- Definition Classes
- Semigroup
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- final def category: Category[[α, β]String]
Every
Monoid
gives rise to a scalaz.Category, for which the type parameters are phantoms.Every
Monoid
gives rise to a scalaz.Category, for which the type parameters are phantoms.- Definition Classes
- Monoid
- Note
category.monoid
=this
- def clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def compose[G[_]]: PlusEmpty[[α]String]
The composition of PlusEmpty
F
andG
,[x]F[G[x]]
, is a PlusEmpty - final def compose: Compose[[α, β]String]
Every
Semigroup
gives rise to a scalaz.Compose, for which the type parameters are phantoms.Every
Semigroup
gives rise to a scalaz.Compose, for which the type parameters are phantoms.- Definition Classes
- Semigroup
- Note
compose.semigroup
=this
- def contramap[B](f: (B) => String): Order[B]
- def empty[A]: String
- Definition Classes
- stringInstance → PlusEmpty
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equal(x: String, y: String): Boolean
- Definition Classes
- stringInstance → Order → Equal
- def equalIsNatural: Boolean
- returns
true, if
equal(f1, f2)
is known to be equivalent tof1 == f2
- Definition Classes
- stringInstance → Equal
- def equalLaw: EqualLaw
- Definition Classes
- Equal
- val equalSyntax: EqualSyntax[String]
- Definition Classes
- Equal
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def greaterThan(x: String, y: String): Boolean
- Definition Classes
- Order
- def greaterThanOrEqual(x: String, y: String): Boolean
- Definition Classes
- Order
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def ifEmpty[B](a: String)(t: => B)(f: => B)(implicit eq: Equal[String]): B
- Definition Classes
- Monoid
- def isEmpty[A](s: SA[A]): Boolean
- Definition Classes
- stringInstance → IsEmpty
- def isEmptyLaw: IsEmptyLaw
- Definition Classes
- IsEmpty
- val isEmptySyntax: IsEmptySyntax[[α]String]
- Definition Classes
- IsEmpty
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isMZero(a: String)(implicit eq: Equal[String]): Boolean
Whether
a
==zero
.Whether
a
==zero
.- Definition Classes
- Monoid
- def lessThan(x: String, y: String): Boolean
- Definition Classes
- Order
- def lessThanOrEqual(x: String, y: String): Boolean
- Definition Classes
- Order
- def max(x: String, y: String): String
- Definition Classes
- Order
- def min(x: String, y: String): String
- Definition Classes
- Order
- def monoid[A]: Monoid[String]
- Definition Classes
- PlusEmpty
- def monoidLaw: MonoidLaw
- Definition Classes
- Monoid
- val monoidSyntax: MonoidSyntax[String]
- Definition Classes
- Monoid
- def multiply(value: String, n: Int): String
For
n = 0
,zero
Forn = 1
,append(zero, value)
Forn = 2
,append(append(zero, value), value)
For
n = 0
,zero
Forn = 1
,append(zero, value)
Forn = 2
,append(append(zero, value), value)
- Definition Classes
- Monoid
- def multiply1(value: String, n: Int): String
For
n = 0
,value
Forn = 1
,append(value, value)
Forn = 2
,append(append(value, value), value)
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def onEmpty[A, B](a: String)(v: => B)(implicit eq: Equal[String], mb: Monoid[B]): B
- Definition Classes
- Monoid
- final def onNotEmpty[B](a: String)(v: => B)(implicit eq: Equal[String], mb: Monoid[B]): B
- Definition Classes
- Monoid
- def order(x: String, y: String): Ordering
- Definition Classes
- stringInstance → Order
- def orderLaw: OrderLaw
- Definition Classes
- Order
- val orderSyntax: OrderSyntax[String]
- Definition Classes
- Order
- def plus[A](f1: SA[A], f2: => SA[A]): String
- Definition Classes
- stringInstance → Plus
- def plusEmptyLaw: EmptyLaw
- Definition Classes
- PlusEmpty
- val plusEmptySyntax: PlusEmptySyntax[[α]String]
- Definition Classes
- PlusEmpty
- def plusLaw: PlusLaw
- Definition Classes
- Plus
- val plusSyntax: PlusSyntax[[α]String]
- Definition Classes
- Plus
- def product[G[_]](implicit G0: PlusEmpty[G]): PlusEmpty[[α](String, G[α])]
The product of PlusEmpty
F
andG
,[x](F[x], G[x]])
, is a PlusEmptyThe product of PlusEmpty
F
andG
,[x](F[x], G[x]])
, is a PlusEmpty- Definition Classes
- PlusEmpty
- def product[G[_]](implicit G0: Plus[G]): Plus[[α](String, G[α])]
The product of Plus
F
andG
,[x](F[x], G[x]])
, is a PlusThe product of Plus
F
andG
,[x](F[x], G[x]])
, is a Plus- Definition Classes
- Plus
- def reverseOrder: Order[String]
- Definition Classes
- Order
- def semigroup[A]: Semigroup[String]
- Definition Classes
- Plus
- def semigroupLaw: SemigroupLaw
- Definition Classes
- Semigroup
- val semigroupSyntax: SemigroupSyntax[String]
- Definition Classes
- Semigroup
- def show(f: String): Cord
- Definition Classes
- stringInstance → Show
- val showSyntax: ShowSyntax[String]
- Definition Classes
- Show
- def shows(f: String): String
- Definition Classes
- stringInstance → Show
- def sort(x: String, y: String): (String, String)
- Definition Classes
- Order
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toScalaOrdering: scala.math.Ordering[String]
- Definition Classes
- Order
- Note
Order.fromScalaOrdering(toScalaOrdering).order(x, y)
this.order(x, y)
- def toString(): String
- Definition Classes
- AnyRef → Any
- def unfoldlPsum[S, A](seed: S)(f: (S) => Maybe[(S, String)]): String
- Definition Classes
- PlusEmpty
- def unfoldlPsumOpt[S, A](seed: S)(f: (S) => Maybe[(S, String)]): Maybe[String]
Unfold
seed
to the left and sum using #plus. - def unfoldlSum[S](seed: S)(f: (S) => Maybe[(S, String)]): String
- Definition Classes
- Monoid
- def unfoldlSumOpt[S](seed: S)(f: (S) => Maybe[(S, String)]): Maybe[String]
Unfold
seed
to the left and sum using #append. - def unfoldrPsum[S, A](seed: S)(f: (S) => Maybe[(String, S)]): String
- Definition Classes
- PlusEmpty
- def unfoldrPsumOpt[S, A](seed: S)(f: (S) => Maybe[(String, S)]): Maybe[String]
Unfold
seed
to the right and sum using #plus. - def unfoldrSum[S](seed: S)(f: (S) => Maybe[(String, S)]): String
- Definition Classes
- Monoid
- def unfoldrSumOpt[S](seed: S)(f: (S) => Maybe[(String, S)]): Maybe[String]
Unfold
seed
to the right and sum using #append. - final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- def zero: String
The identity element for
append
.The identity element for
append
.- Definition Classes
- stringInstance → Monoid