def METHOD_NAME(model, data, *args):
  if len(args)==5 and type(args[4]) is bool:
    message = ("This function signature has been deprecated and will be removed in future releases of Pinocchio. "
               "Please change for the new signature of impulseDynamics(model,data[,q],v_before,J[,r_coeff[,inv_damping]]).")
    _warnings.warn(message, category=DeprecatedWarning, stacklevel=2)
    q = args[0]
    v_before = args[1]
    J = args[2]
    r_coeff = args[3]
    updateKinematics = args[4]
    inv_damping = 0.
    if updateKinematics:
      return pin.METHOD_NAME(model,data,q,v_before,J,r_coeff,inv_damping)
    else:
      return pin.METHOD_NAME(model,data,v_before,J,r_coeff,inv_damping)
  return pin.METHOD_NAME(model, data, *args)