title: Access JBehave Examples table data in step
body: <p>I would like to know if there is a way I can access examples table row data within a step method without passing it in as an argument?</p>
  
  <p><strong>Story file:</strong></p>
  
  <pre><code>Given I am logged in
  When I create a trade
  Then a trade should be created
  
  Examples:
  |data1|data2|
  |11111|22222|
  |33333|44444|
  </code></pre>
  
  <p><strong>Step file:</strong></p>
  
  <pre><code>@When("I create a trade")
  public void createTrade(@Named("data1") String data1, @Named("data2") String data2){
      //code to create trade using data1 and data2
  }
  </code></pre>
  
  <p>Above works fine, but I would like a way to access the data row from the examples table within the method. (The reason I would like to do this is because all columns may not be present in the examples table in every story, and I have found that if I have say 3 * @Named as parameters in the step method, but one of these are missing from the actual examples table then it fails to run.)</p>
  
  <pre><code>@When("I create a trade")
  public void createTrade(){
      //check if there is a data1 column, if so get value and do something
      //check if there is a data2 column, if so get value and do something
  }
  </code></pre>
  
  <p>Thanks for your help</p>