@Override public Object parse( ParsingEngine parsingEngine, ArgumentSource source, Type type, ArgumentMatches matches ) { SAMReaderBuilder builder = new SAMReaderBuilder(); ArgumentMatchValue readerFileName = getArgumentValue( createDefaultArgumentDefinition(source), matches ); if( readerFileName == null ) throw new UserException.CommandLineException("SAM file compression was supplied, but no associated writer was supplied with it."); builder.setSAMFile(readerFileName.asFile()); // WARNING: Skipping required side-effect because stub is impossible to generate. engine.addInput(source, builder); // MASSIVE KLUDGE! SamReader is tricky to implement and we don't yet have a stub. Return null, then // let the output tracker load it in. // TODO: Add a stub for SAMReader. return null; } }