Options
All
  • Public
  • Public/Protected
  • All
Menu

Module "repeat"

Index

Functions

Functions

Const repeat

  • Takes a matcher and min / max repeats. Returns new matcher which only returns Match.FULL if match succeeded at least min times or once max repetitions have been found.

    Type parameters

    • T

    • C

    • R

    Parameters

    • match: Matcher<T, C, R>

      matcher

    • min: number

      -min repetitions

    • max: number

      max repetitions

    • Optional success: SeqCallback<T, C, R>

      success callback

    • Optional fail: SeqCallback<T, C, R>

      failure callback

    Returns Matcher<T, C, R>

Generated using TypeDoc