JsonSerializer<?> ser = _findExplicitUntypedSerializer(cls); return (ser != null); } catch (JsonMappingException e) {
/** * Method that can be called to see if this serializer provider * can find a serializer for an instance of given class. *<p> * Note that no Exceptions are thrown, including unchecked ones: * implementations are to swallow exceptions if necessary. */ public boolean hasSerializerFor(Class<?> cls) { return _findExplicitUntypedSerializer(cls) != null; }
/** * Method that can be called to see if this serializer provider * can find a serializer for an instance of given class. *<p> * Note that no Exceptions are thrown, including unchecked ones: * implementations are to swallow exceptions if necessary. */ public boolean hasSerializerFor(Class<?> cls) { return _findExplicitUntypedSerializer(cls, null) != null; }
/** * Method that can be called to see if this serializer provider * can find a serializer for an instance of given class. *<p> * Note that no Exceptions are thrown, including unchecked ones: * implementations are to swallow exceptions if necessary. */ public boolean hasSerializerFor(Class<?> cls, AtomicReference<Throwable> cause) { try { JsonSerializer<?> ser = _findExplicitUntypedSerializer(cls); return (ser != null); } catch (JsonMappingException e) { if (cause != null) { cause.set(e); } } catch (RuntimeException e) { if (cause == null) { // earlier behavior throw e; } cause.set(e); } return false; }
/** * Method that can be called to see if this serializer provider * can find a serializer for an instance of given class. *<p> * Note that no Exceptions are thrown, including unchecked ones: * implementations are to swallow exceptions if necessary. */ public boolean hasSerializerFor(Class<?> cls, AtomicReference<Throwable> cause) { try { JsonSerializer<?> ser = _findExplicitUntypedSerializer(cls); return (ser != null); } catch (JsonMappingException e) { if (cause != null) { cause.set(e); } } catch (RuntimeException e) { if (cause == null) { // earlier behavior throw e; } cause.set(e); } return false; }
JsonSerializer<?> ser = _findExplicitUntypedSerializer(cls); return (ser != null); } catch (JsonMappingException e) {
JsonSerializer<?> ser = _findExplicitUntypedSerializer(cls); return (ser != null); } catch (JsonMappingException e) {