/** * Logs a warning about a failure to compute the Bursa-Wolf parameters. */ private static void log(final String logger, final String method, final Exception e) { Logging.recoverableException(Logging.getLogger(logger), GeocentricAffine.class, method, e); } }
/** * Logs a warning for a non-critical error. The callers should have a fallback. */ private static void warning(final String method, final Exception e) { Logging.recoverableException(Logging.getLogger(Modules.REFERENCING), IdentifiedObjects.class, method, e); }
/** * Invoked for reporting exceptions that may be normal behavior. This method logs * the exception at {@link java.util.logging.Level#FINE} without stack trace. */ private static void recoverableException(final Exception warning) { Logging.recoverableException(Logging.getLogger(Modules.STORAGE), ChannelFactory.class, "prepare", warning); } }
/** * Logs a warning for a non-critical error. The callers should have a fallback. */ private static void warning(final String method, final Exception e) { Logging.recoverableException(Logging.getLogger(Modules.REFERENCING), IdentifiedObjects.class, method, e); }
/** * Invoked when a recoverable exception occurred. Those exceptions must be minor enough * that they can be silently ignored in most cases. */ static void recoverableException(final Class<? extends Static> caller, final TransformException exception) { Logging.recoverableException(Logging.getLogger(Loggers.GEOMETRY), caller, "transform", exception); }
/** * Logs a recoverable exception that happened (directly or indirectly) in the {@link #configuration()} method. */ private static void recoverableException(final String logger, final Exception e) { Logging.recoverableException(Logging.getLogger(logger), About.class, "configuration", e); } }
/** * Invoked for reporting exceptions that may be normal behavior. This method logs * the exception at {@link java.util.logging.Level#FINE} without stack trace. */ private static void recoverableException(final Exception warning) { Logging.recoverableException(Logging.getLogger(Modules.STORAGE), ChannelFactory.class, "prepare", warning); } }
/** * Reports the given exception as an ignorable one. We consider {@link FactoryException} or * {@link TransformException} as ignorable exceptions only if they occurred while computing * whether a point is inside the domain of validity. Failure to answer that question is * considered as an indication that the point is outside the domain of validity. */ private static void warning(final Exception e) { Logging.recoverableException(Logging.getLogger("org.apache.sis.console"), TransformCommand.class, "run", e); } }
/** * Invoked when a recoverable exception occurred. Those exceptions must be minor enough * that they can be silently ignored in most cases. * * @param exception the exception that occurred. */ static void recoverableException(final Exception exception) { Logging.recoverableException(Logging.getLogger(Modules.RASTER), GridGeometry.class, "<init>", exception); }
/** * Logs a recoverable exception that happened (directly or indirectly) in the {@link #configuration()} method. */ private static void recoverableException(final String logger, final Exception e) { Logging.recoverableException(Logging.getLogger(logger), About.class, "configuration", e); } }
/** * Logs a warning about a failure to compute the Bursa-Wolf parameters. */ private static void log(final String logger, final String method, final Exception e) { Logging.recoverableException(Logging.getLogger(logger), GeocentricAffine.class, method, e); } }
public GMLOrDefaultFactory() { TemporalFactory delegate; try { delegate = (TemporalFactory) Class.forName("org.geotoolkit.gml.GMLTemporalFactory").newInstance(); } catch (Exception e) { Logging.recoverableException(null, GMLOrDefaultFactory.class, "<init>", e); delegate = new DefaultTemporalFactory(); } this.delegate = delegate; }
/** * Logs a warning about an exception that can be safely ignored. */ final void warning(final String method, final RuntimeException e) { Logging.recoverableException(Logging.getLogger(Loggers.MATH), Vector.class, method, e); }
/** * Invoked when a recoverable exception occurred. Those exceptions must be minor enough * that they can be silently ignored in most cases. */ static void recoverableException(final Class<? extends Static> caller, final TransformException exception) { Logging.recoverableException(Logging.getLogger(Loggers.GEOMETRY), caller, "transform", exception); }
/** * Logs a warning about an exception that can be safely ignored. */ final void warning(final String method, final RuntimeException e) { Logging.recoverableException(Logging.getLogger(Loggers.MATH), Vector.class, method, e); }
/** * Implementation of {@link #before(String, boolean)} and {@link #after(String, boolean)}. * The {@code before} boolean argument tells which method is invoking this one. */ private void setOrdering(final String type, final boolean subclasses, final boolean before) { final Class<?> c; try { c = Class.forName(type); } catch (ClassNotFoundException e) { Logging.recoverableException(null, Organizer.class, before ? "before" : "after", e); return; } setOrdering(c, subclasses, before); }
/** * Rewrites the given code in a canonical format. * If the code can not be reformatted, then this method returns {@code null}. */ static String reformat(final String code) { try { return format(Integer.parseInt(code.substring(skipNamespace(code) & ~LEGACY_MASK))); } catch (NoSuchAuthorityCodeException | NumberFormatException e) { Logging.recoverableException(Logging.getLogger(Loggers.CRS_FACTORY), CommonAuthorityFactory.class, "reformat", e); return null; } }
/** * Rewrites the given code in a canonical format. * If the code can not be reformatted, then this method returns {@code null}. */ static String reformat(final String code) { try { return format(Integer.parseInt(code.substring(skipNamespace(code) & ~LEGACY_MASK))); } catch (NoSuchAuthorityCodeException | NumberFormatException e) { Logging.recoverableException(Logging.getLogger(Loggers.CRS_FACTORY), CommonAuthorityFactory.class, "reformat", e); return null; } }
/** * Returns the description for the given locale, or fallback on a default description * if no resources exist for that locale. */ @Override public final String toString(final Locale locale) { try { return super.toString(locale); } catch (MissingResourceException e) { Logging.recoverableException(Logging.getLogger(Loggers.LOCALIZATION), ResourceInternationalString.class, "toString", e); return fallback(); } }
/** * Returns the description for the given locale, or fallback on a default description * if no resources exist for that locale. */ @Override public final String toString(final Locale locale) { try { return super.toString(locale); } catch (MissingResourceException e) { Logging.recoverableException(Logging.getLogger(Loggers.LOCALIZATION), ResourceInternationalString.class, "toString", e); return fallback(); } }