Class StringPrototypeBuiltins.JSStringMatchNode

All Implemented Interfaces:
com.oracle.truffle.api.instrumentation.InstrumentableNode, com.oracle.truffle.api.nodes.NodeInterface, Cloneable
Enclosing class:
StringPrototypeBuiltins

public abstract static class StringPrototypeBuiltins.JSStringMatchNode extends StringPrototypeBuiltins.JSStringOperationWithRegExpArgument
Implementation of the String.prototype.match() method as specified by ECMAScript 6 in 21.1.3.11 and the String.prototype.matchAll() method as specified by the String.prototype.matchAll draft proposal.
  • Constructor Details

    • JSStringMatchNode

      protected JSStringMatchNode(JSContext context, JSBuiltin builtin, boolean matchAll)
  • Method Details

    • match

      protected Object match(Object thisObj, Object regex, com.oracle.truffle.api.profiles.InlinedBranchProfile errorBranch, com.oracle.truffle.api.profiles.InlinedConditionProfile isSpecialProfile, com.oracle.truffle.api.profiles.InlinedConditionProfile callSpecialProfile)
    • within

      protected static int within(int value, int min, int max)
    • withinNumber

      protected static int withinNumber(Number value, int min, int max)
    • requireObjectCoercible

      protected final void requireObjectCoercible(Object target)
    • toString

      protected com.oracle.truffle.api.strings.TruffleString toString(Object target)
    • toIntegerAsInt

      protected int toIntegerAsInt(Object target)