This method surrounds the explicit conversion defined with a try-catch, to handle null pointers.
@return the body wrapped
15556
private String error(){
		Map<String, List<ConversionMethod>> conversions = xml.conversionsLoad();
		
		String methodName = "illegalCode";
		String paramater = "";
		String resource = xml.getXmlPath();
		
		if(!isNull(resource)){
			
			boolean isPath = isPath(resource);
			methodName = !isPath ? "illegalCodeContent":"illegalCode";
			if(!conversions.isEmpty() && !isNull(conversions.get(configClass.getName()))){
				
				// if is a content, the double quotes must be handled
				if(!isPath) resource = doubleQuotesHandling(resource);
				
				paramater = write(",\"",resource,"\"");
			}
		}
		return write("com.googlecode.jmapper.config.Error#",methodName,"(e,\"",methodToGenerate.getOriginalName(),"\",\"",configClass.getSimpleName(),"\"",paramater,");");
	}
206009
private void bodyConsumerChunk(ByteBuf buffer) throws HandlerException {
    try {
      bodyConsumer.chunk(buffer, responder);
    } catch (Throwable t) {
      try {
        bodyConsumerError(t);
      } catch (Throwable t2) {
        exceptionHandler.handle(t2, request, responder);
        // log original throwable since we'll lose it otherwise
        LOG.debug("Handled exception thrown from handleError. original exception from chunk call was:", t);
        return;
      }
      exceptionHandler.handle(t, request, responder);
    }
  }
1244938
@Override
	public RequestBody convert(T value) throws IOException {
		Buffer buffer = new Buffer();

		try {
			binderContext.serialize(value, buffer.outputStream());
			return RequestBody.create(MEDIA_TYPE, buffer.readByteString());
		} catch (Exception e) {
			e.printStackTrace();
			return null;
		} finally {
			buffer.close();
		}

	}
342262
private Object finalizeConversion(Object o)
  {
    // conversion can leave 'wrapped' list primitives
    if (ParquetGroupConverter.isWrappedListPrimitive(o)) {
      return converter.unwrapListPrimitive(o);
    } else if (o instanceof List) {
      List<Object> asList = ((List<Object>) o).stream().filter(Objects::nonNull).collect(Collectors.toList());
      if (asList.stream().allMatch(ParquetGroupConverter::isWrappedListPrimitive)) {
        return asList.stream().map(Group.class::cast).map(converter::unwrapListPrimitive).collect(Collectors.toList());
      }
    }
    return o;
  }
1006905
public static Class<?> wrappedType(Class<?> c) {
        int i;

        if (c.isPrimitive()) {
            for (i = 0; i < Type.PRIMITIVES.length; i++) {
                if (Type.PRIMITIVES[i].type == c) {
                    return Type.PRIMITIVES[i].wrapper;
                }
            }
            throw new RuntimeException();
        } else {
            return c;
        }
    }
1148611
@Nonnull
  public JSBlock body ()
  {
    if (m_aBody == null)
      m_aBody = new JSBlock ().newlineAtEnd (false);
    return m_aBody;
  }
457989
private Throwable wrapCancellationException(Throwable u) {
        Throwable wrappedException = null;
        if (u != null) {
            wrappedException = Exceptions.unwrap(u);
            if (wrappedException instanceof CancellationException) {
                wrappedException = new ReadCancellationException(wrappedException);
            }
        }
        return wrappedException;
    }
840997
public Body from(ThrowableWrapper throwableWrapper, String description) {
    Body.Builder builder = new Body.Builder();
    if (throwableWrapper == null) {
      return builder.bodyContent(message(description)).build();
    }
    if (throwableWrapper.getCause() == null) {
      return builder.bodyContent(trace(throwableWrapper, description)).build();
    }
    return builder.bodyContent(traceChain(throwableWrapper, description)).build();
  }
526816
public static Throwable unwrap(@Nullable Throwable t) {
		if (t instanceof UncheckedException || t instanceof java.util.concurrent.ExecutionException
				|| t instanceof java.lang.reflect.InvocationTargetException
				|| t instanceof UndeclaredThrowableException) {
			return t.getCause();
		}

		return t;
	}
1271193
public Throwable unwrap() {
		Throwable cause = getCause();
		return (cause instanceof WrappingRuntimeException) ? ((WrappingRuntimeException) cause).unwrap() : cause;
	}
189790
@SuppressWarnings({ "unchecked", "rawtypes" })
	@Override
	public RequestBody convert(T value) throws IOException {
		Buffer buffer = new Buffer();	
		
		try {	
			binderContext.serializeCollection((Collection) value, (Class)clazz,buffer.outputStream()); 			
			return RequestBody.create(MEDIA_TYPE, buffer.readByteString());
		} catch (Exception e) {			
			e.printStackTrace();
			return null;
		} finally
		{
			buffer.close();
		}
		
		
	}
1153795
public MethodHandle nop() {
        if (type().returnType() != void.class) {
            throw new InvalidTransformException("must have void return type to nop: " + type());
        }
        return invoke(Binder
                .from(type())
                .drop(0, type().parameterCount())
                .cast(Object.class)
                .constant(null));
    }
1179623
public Object getBodyAs(Type type) {
    if (response == null) {
      return null;
    }
    String body = response.getBody();
    if (TextUtils.isEmpty(body)) {
      return null;
    }
    try {
      return Wasp.getParser().fromBody(response.getBody(), type);
    } catch (Exception e) {
      throw new RuntimeException(e);
    }
  }
693503
public T get()
    throws InvalidBucketNameException, NoSuchAlgorithmException, InsufficientDataException, IOException,
           InvalidKeyException, NoResponseException, XmlPullParserException, ErrorResponseException,
           InternalException {
    if (ex == null) {
      return type;
    }

    if (ex instanceof InvalidBucketNameException) {
      throw (InvalidBucketNameException) ex;
    } else if (ex instanceof NoSuchAlgorithmException) {
      throw (NoSuchAlgorithmException) ex;
    } else if (ex instanceof InsufficientDataException) {
      throw (InsufficientDataException) ex;
    } else if (ex instanceof IOException) {
      throw (IOException) ex;
    } else if (ex instanceof InvalidKeyException) {
      throw (InvalidKeyException) ex;
    } else if (ex instanceof NoResponseException) {
      throw (NoResponseException) ex;
    } else if (ex instanceof XmlPullParserException) {
      throw (XmlPullParserException) ex;
    } else if (ex instanceof ErrorResponseException) {
      throw (ErrorResponseException) ex;
    } else {
      throw (InternalException) ex;
    }
  }
226667
@Nullable
    private Comparable<?> getCallingObject() {
        String sig = getSigConstantOperand();
        if (Values.SIG_VOID.equals(SignatureUtils.getReturnSignature(sig))) {
            return null;
        }

        int numParameters = SignatureUtils.getNumParameters(sig);

        if (stack.getStackDepth() <= numParameters) {
            return null;
        }

        OpcodeStack.Item caller = stack.getStackItem(numParameters);
        UserObject uo = (UserObject) caller.getUserValue();
        if ((uo != null) && (uo.caller != null)) {
            return uo.caller;
        }

        int reg = caller.getRegisterNumber();
        if (reg >= 0) {
            return Integer.valueOf(reg);
        }

        /*
         * We ignore the possibility of two fields with the same name in different
         * classes
         */
        XField f = caller.getXField();
        if (f != null) {
            return f.getName();
        }
        return null;
    }
296202
public function getBody()
    {
        // If this value has been read from the stream, retrieve it from storage
        if (null !== $this->input[self::INPUT_METHOD_BODY]) {
            return $this->input[self::INPUT_METHOD_BODY];
        }

        if (is_resource($this->stream) && 'stream' === get_resource_type($this->stream)) {
            $streamData = stream_get_contents($this->stream);
        } elseif (is_string($this->stream)) {
            $stream = @fopen($this->stream, "r");

            if (false === $stream) {
                throw new InternalErrorException('Unable to open request input stream.');
            }

            $streamData = stream_get_contents($stream);

            fclose($stream);
        } else {
            $streamData = false;
        }

        if (false === $streamData) {
            throw new InternalErrorException('Unable to open request input stream.');
        }

        $this->input[self::INPUT_METHOD_BODY] = $streamData;

        return $this->input[self::INPUT_METHOD_BODY];
    }
1114731
public Object convertToMessage()
    {
        try {
            Object reply = this.getRawData();

            org.w3c.dom.Node nodeBody = this.getMessageBody(reply, false);

            if (this.getConvertToMessage() == null)
                return null;
            Object msg = this.getConvertToMessage().unmarshalRootElement(nodeBody, this);

            return msg;
        } catch(Throwable ex) {
            this.setMessageException(ex);
        }
        return null;    // Error
    }