tripal_bulk_loader.DEPRECATED.inc 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <?php
  2. /**
  3. * @file
  4. * Wrapper functions to provide backwards compatibility for the tripal analysis
  5. * api
  6. */
  7. /**
  8. * @deprecated Restructured API to make naming more readable and consistent.
  9. * Function was deprecated in Tripal 2.0 and will be removed 2 releases from
  10. * now. This function has been replaced by
  11. * tripal_is_bulk_loader_record_name_unique().
  12. *
  13. * @see tripal_is_bulk_loader_record_name_unique().
  14. */
  15. function tripal_bulk_loader_is_record_name_unique($new_record_name, $template_id, $template_array = NULL, $current_priority = NULL) {
  16. tripal_report_error(
  17. 'tripal_deprecated',
  18. TRIPAL_NOTICE,
  19. "DEPRECATED: %old_function has been replaced with %new_function. Please update your code.",
  20. [
  21. '%old_function' => 'tripal_bulk_loader_is_record_name_unique',
  22. '%new_function' => 'tripal_is_bulk_loader_record_name_unique',
  23. ]
  24. );
  25. return tripal_is_bulk_loader_record_name_unique($new_record_name, $template_id, $template_array, $current_priority);
  26. }
  27. /**
  28. * @deprecated Restructured API to make naming more readable and consistent.
  29. * Function was deprecated in Tripal 2.0 and will be removed 2 releases from
  30. * now. This function has been replaced by
  31. * tripal_delete_bulk_loader_record().
  32. *
  33. * @see tripal_delete_bulk_loader_record().
  34. */
  35. function tripal_bulk_loader_delete_record($delete_priority, $template_array) {
  36. tripal_report_error(
  37. 'tripal_deprecated',
  38. TRIPAL_NOTICE,
  39. "DEPRECATED: %old_function has been replaced with %new_function. Please update your code.",
  40. [
  41. '%old_function' => 'tripal_bulk_loader_delete_record',
  42. '%new_function' => 'tripal_delete_bulk_loader_record',
  43. ]
  44. );
  45. return tripal_delete_bulk_loader_record($delete_priority, $template_array);
  46. }
  47. /**
  48. * @deprecated Restructured API to make naming more readable and consistent.
  49. * Function was deprecated in Tripal 2.0 and will be removed 2 releases from
  50. * now. This function has been replaced by tripal_delete_bulk_loader_field().
  51. *
  52. * @see tripal_delete_bulk_loader_field().
  53. */
  54. function tripal_bulk_loader_delete_field($priority, $delete_field_index, $template_array) {
  55. tripal_report_error(
  56. 'tripal_deprecated',
  57. TRIPAL_NOTICE,
  58. "DEPRECATED: %old_function has been replaced with %new_function. Please update your code.",
  59. [
  60. '%old_function' => 'tripal_bulk_loader_delete_field',
  61. '%new_function' => 'tripal_delete_bulk_loader_field',
  62. ]
  63. );
  64. return tripal_delete_bulk_loader_field($priority, $delete_field_index, $template_array);
  65. }