Class DocStringType

java.lang.Object
io.cucumber.docstring.DocStringType

@API(status=STABLE) public final class DocStringType extends Object
A data table type describes how a doc string should be represented as an object.
  • Field Details

  • Constructor Details

    • DocStringType

      public DocStringType(Type type, String contentType, DocStringType.Transformer<T> transformer)
      Creates a doc string type that can convert a doc string to an object.
      Type Parameters:
      T - see type
      Parameters:
      type - the type of the object
      contentType - the media type or GFM info string
      transformer - a function that creates an instance of type from the doc string
  • Method Details

    • getContentType

      String getContentType()
    • getType

      Type getType()
    • transform

      @Nullable Object transform(String content)