class MultiPayloadStringInputParameter extends StringPayloadDataInputParameter implements DataInputParameter<String> {

  @Override
  public String extract(InterlokMessage m) throws InterlokException
  {
    if (m instanceof MultiPayloadAdaptrisMessage)
    {
      return extract(m.resolve(getPayloadId()), (MultiPayloadAdaptrisMessage)m);
    }
    throw new InterlokException("Cannot extract payload from message type " + m.getClass().getName() + " as it does not support multiple payloads.");
  }

}