Step.java

  1. package org.jbehave.core.model;

  2. import org.apache.commons.lang3.builder.ToStringBuilder;
  3. import org.apache.commons.lang3.builder.ToStringStyle;
  4. import org.jbehave.core.steps.StepCreator.StepExecutionType;

  5. public class Step {

  6.     private final StepExecutionType executionType;
  7.     private final String stepAsString;

  8.     public Step(StepExecutionType executionType, String stepAsString) {
  9.         this.executionType = executionType;
  10.         this.stepAsString = stepAsString;
  11.     }

  12.     public StepExecutionType getExecutionType() {
  13.         return executionType;
  14.     }

  15.     public String getStepAsString() {
  16.         return stepAsString;
  17.     }

  18.     @Override
  19.     public String toString() {
  20.         return ToStringBuilder.reflectionToString(this, ToStringStyle.SHORT_PREFIX_STYLE);
  21.     }
  22. }