@SuppressWarnings("UnusedDeclaration") public ViaMichelinRoute asViaMichelinFormat() { if (getFormat() instanceof ViaMichelinFormat) return (ViaMichelinRoute) this; List<Wgs84Position> wgs84Positions = new ArrayList<>(); for (P position : getPositions()) { wgs84Positions.add(position.asWgs84Position()); } return new ViaMichelinRoute(getName(), wgs84Positions); }
@SuppressWarnings("UnusedDeclaration") public MagicMapsIktRoute asMagicMapsIktFormat() { if (getFormat() instanceof MagicMapsIktFormat) return (MagicMapsIktRoute) this; List<Wgs84Position> wgs84Positions = new ArrayList<>(); for (P position : getPositions()) { wgs84Positions.add(position.asWgs84Position()); } return new MagicMapsIktRoute(getName(), getDescription(), wgs84Positions); }
@SuppressWarnings("UnusedDeclaration") public NokiaLandmarkExchangeRoute asNokiaLandmarkExchangeFormat() { if (getFormat() instanceof NokiaLandmarkExchangeFormat) return (NokiaLandmarkExchangeRoute) this; List<Wgs84Position> wgs84Positions = new ArrayList<>(); for (P position : getPositions()) { wgs84Positions.add(position.asWgs84Position()); } return new NokiaLandmarkExchangeRoute(getName(), getDescription(), wgs84Positions); }