@Test public final void testLineLocationExceedingOffsets() { Location decLocRef; InputStream properties = null; try { properties = new FileInputStream(DECODER_PROPERTIES); } catch (IOException e) { fail("Error creating properties stream.", e); } try { OpenLRDecoder decoder = new OpenLRDecoder(); OpenLRDecoderParameter parameter = new OpenLRDecoderParameter.Builder() .with(mockedMapDB) .with(OpenLRPropertiesReader.loadPropertiesFromStream( properties, true)).buildParameter(); decLocRef = decoder.decodeRaw(parameter, td.getLineLocationExceedingOffsets()); assertTrue(decLocRef.isValid()); assertNotNull(decLocRef.toString()); } catch (OpenLRProcessingException e) { fail("Decoding location failed with exception: " + e.getErrorCode(), e); } }
@Override public List<Location> decodeRaw(final OpenLRDecoderParameter parameter, final List<RawLocationReference> locRefs) throws OpenLRProcessingException { List<Location> locations = new ArrayList<Location>(); OpenLRDecoderProperties properties = new OpenLRDecoderProperties(parameter.getConfiguration()); for (RawLocationReference locRef : locRefs) { locations.add(decodeRaw(parameter, properties, locRef)); } return locations; }
OpenLRDecoder implements openlr.OpenLRDecoder { @Override public List<Location> decodeRaw(final OpenLRDecoderParameter parameter, final List<RawLocationReference> locRefs) throws OpenLRProcessingException { List<Location> locations = new ArrayList<Location>(); OpenLRDecoderProperties properties = new OpenLRDecoderProperties(parameter.getConfiguration()); for (RawLocationReference locRef : locRefs) { locations.add(decodeRaw(parameter, properties, locRef)); } return locations; } }
OpenLRDecoder implements openlr.OpenLRDecoder { @Override public List<Location> decodeRaw(final OpenLRDecoderParameter parameter, final List<RawLocationReference> locRefs) throws OpenLRProcessingException { List<Location> locations = new ArrayList<Location>(); OpenLRDecoderProperties properties = new OpenLRDecoderProperties(parameter.getConfiguration()); for (RawLocationReference locRef : locRefs) { locations.add(decodeRaw(parameter, properties, locRef)); } return locations; }  }
OpenLRDecoder implements openlr.OpenLRDecoder { @Override public List<Location> decodeRaw(final OpenLRDecoderParameter parameter, final List<RawLocationReference> locRefs) throws OpenLRProcessingException { List<Location> locations = new ArrayList<Location>(); OpenLRDecoderProperties properties = new OpenLRDecoderProperties(parameter.getConfiguration()); for (RawLocationReference locRef : locRefs) { locations.add(decodeRaw(parameter, properties, locRef)); } return locations; }  static List<PhysicalDecoder> resolvePhysicalDecoder(); @Override Location decode(final OpenLRDecoderParameter parameter,
                           final LocationReference locRef); @Override List<Location> decode(final OpenLRDecoderParameter parameter,
                                 final List<LocationReference> locRefs); @Override List<Location> decodeRaw(final OpenLRDecoderParameter parameter,
                                    final List<RawLocationReference> locRefs); @Override Location decodeRaw(final OpenLRDecoderParameter parameter,
                              final RawLocationReference rawLocRef); @Override String getMajorVersion(); @Override String getMinorVersion(); @Override String getPatchVersion(); @Override String getVersion(); }
OpenLRDecoder implements openlr.OpenLRDecoder { @Override public List<Location> decodeRaw(final OpenLRDecoderParameter parameter, final List<RawLocationReference> locRefs) throws OpenLRProcessingException { List<Location> locations = new ArrayList<Location>(); OpenLRDecoderProperties properties = new OpenLRDecoderProperties(parameter.getConfiguration()); for (RawLocationReference locRef : locRefs) { locations.add(decodeRaw(parameter, properties, locRef)); } return locations; }  static List<PhysicalDecoder> resolvePhysicalDecoder(); @Override Location decode(final OpenLRDecoderParameter parameter,
                           final LocationReference locRef); @Override List<Location> decode(final OpenLRDecoderParameter parameter,
                                 final List<LocationReference> locRefs); @Override List<Location> decodeRaw(final OpenLRDecoderParameter parameter,
                                    final List<RawLocationReference> locRefs); @Override Location decodeRaw(final OpenLRDecoderParameter parameter,
                              final RawLocationReference rawLocRef); @Override String getMajorVersion(); @Override String getMinorVersion(); @Override String getPatchVersion(); @Override String getVersion();  }