/** * Obtains an instance of the parser, based on the specified selector and plugins. * <p> * The FpML parser has a number of plugin points that can be controlled: * <ul> * <li>the {@linkplain FpmlPartySelector party selector} * <li>the {@linkplain FpmlTradeInfoParserPlugin trade info parser} * <li>the {@linkplain FpmlParserPlugin trade parsers} * <li>the {@linkplain ReferenceData reference data} * </ul> * * @param ourPartySelector the selector used to find "our" party within the set of parties in the FpML document * @param tradeInfoParser the trade info parser * @param tradeParsers the map of trade parsers, keyed by the FpML element name * @param refData the reference data to use * @return the document parser */ public static FpmlDocumentParser of( FpmlPartySelector ourPartySelector, FpmlTradeInfoParserPlugin tradeInfoParser, Map<String, FpmlParserPlugin> tradeParsers, ReferenceData refData) { return new FpmlDocumentParser(ourPartySelector, tradeInfoParser, tradeParsers, refData); }