PathSegmentImpl

Using the pre-defined path segments in PathSegment can be cumbersome if you have to constantly specify the error type A, for example in the PathSegment.segment or PathSegment.root methods. Therefore, you can invoke an implementation of this class and import its members instead. We don't redefine PathSegment.intSegment and PathSegment.stringSegment since they can be easily and conveniently invoked using the segment method below.

Type parameters:
A

type of error.

Example:
        val pathSegmentImpl = PathSegmentImpl[DummyError]
        import pathSegmentImpl._
        root / "hello"  // this is of type PathSegment[Unit, DummyError] thanks to the import above.
         (note that in this case there is already a PathSegmentImpl for [[urldsl.errors.DummyError]] in the
         [[PathSegment]] companion object)
Companion:
object
class Object
trait Matchable
class Any
class AllImpl[P, Q, F]

Value members

Concrete methods

def oneOf[T](t: T, ts: T*)(implicit fromString: FromString[T, A], printer: Printer[T]): PathSegment[Unit, A]
def segment[T](implicit fromString: FromString[T, A], printer: Printer[T]): PathSegment[T, A]

Concrete fields

lazy val endOfSegments: PathSegment[Unit, A]
lazy val noMatch: PathSegment[Unit, A]
val remainingSegments: PathSegment[List[String], A]
val root: PathSegment[Unit, A]

Implicits

Implicits

implicit def unaryPathSegment[T](t: T)(implicit fromString: FromString[T, A], printer: Printer[T]): PathSegment[Unit, A]