anchor.diff:      INTERFACES zif_abapgit_object.
       ALIASES mo_files FOR zif_abapgit_object~mo_files.
   
  +    METHODS:
  +      constructor
  +        IMPORTING
  +          is_item     TYPE zif_abapgit_definitions=>ty_item
  +          iv_language TYPE spras.
  +
  +  PRIVATE SECTION.
  +    DATA:
  +      mv_objectname TYPE tobj-objct.
  +
  +    METHODS:
  +      delete_documentation
  +        RAISING
  +          zcx_abapgit_exception.
  +
   ENDCLASS.
   
   CLASS zcl_abapgit_object_suso IMPLEMENTATION.
  +
  +  METHOD constructor.
  +
  +    super->constructor( is_item     = is_item
  +                        iv_language = iv_language ).
  +
  +    mv_objectname = ms_item-obj_name.
  +
  +  ENDMETHOD.
   
     METHOD zif_abapgit_object~has_changed_since.
       rv_changed = abap_true.
  
positive.code: 
      tadir_insert( iv_package ).
  
      lv_objectname = ms_item-obj_name.
      CALL FUNCTION 'SUSR_COMMEDITCHECK'
        EXPORTING
          objectname      = lv_objectname
  
negative.code: 
    METHOD zif_abapgit_object~delete.
  
      " FM SUSR_DELETE_OBJECT calls the UI. Therefore we reimplement it here.
  
      CONSTANTS:
        co_act_delete TYPE activ_auth VALUE '06'.
  
      DATA:
        lv_act_head TYPE cl_suso_gen=>td_act,
        lv_dummy    TYPE string,
        lo_suso     TYPE REF TO cl_suso_gen,
        lv_failed   TYPE abap_bool.
  
      CREATE OBJECT lo_suso.
  
      lv_failed = lo_suso->suso_load_from_db( mv_objectname ).
  
      IF lv_failed = abap_true.
        " Object & does not exist; choose an existing object
        MESSAGE s111(01) WITH mv_objectname INTO lv_dummy.
        zcx_abapgit_exception=>raise_t100( ).
      ENDIF.
  
      lo_suso->get_suso_edit_mode( EXPORTING id_object      = mv_objectname
                                             id_planed_act  = co_act_delete
                                   IMPORTING ed_mode_head   = lv_act_head ).
      IF lv_act_head <> co_act_delete.
        zcx_abapgit_exception=>raise( |AUTH { mv_objectname }: Delete not allowed| ).
      ENDIF.
  
      IF lo_suso->suso_collect_in_cts( mv_objectname ) IS NOT INITIAL.
        RETURN.
      ENDIF.
  
      delete_documentation( ).
  
      DELETE FROM tobj  WHERE objct  = mv_objectname.
      DELETE FROM tobjt WHERE object = mv_objectname.
      DELETE FROM tactz WHERE brobj  = mv_objectname.
  
      CALL FUNCTION 'SUPV_DELETE_OBJECT_ASSIGNMENTS'
        EXPORTING
          object_name  = mv_objectname
          all_releases = abap_true.
  
      CALL FUNCTION 'RS_TREE_OBJECT_PLACEMENT'
        EXPORTING
          object    = mv_objectname
          type      = 'SUSO'
          operation = 'DELETE'.
  
    ENDMETHOD.
  
    METHOD delete_documentation.
  
      DATA:
        lv_docu_obj TYPE dokhl-object,
        lv_dummy    TYPE sy-langu.
  
      lv_docu_obj  = mv_objectname.
  
      SELECT SINGLE langu
             FROM dokil INTO lv_dummy
             WHERE id   = 'UO'                            "#EC CI_GENBUFF
             AND object = lv_docu_obj.
  
      IF sy-subrc = 0.
  
        CALL FUNCTION 'DOKU_DELETE_ALL'
          EXPORTING
            doku_id                        = 'UO'
            doku_object                    = lv_docu_obj
            suppress_transport             = space
          EXCEPTIONS
            header_without_text            = 1
            index_without_header           = 2
            no_authority_for_devclass_xxxx = 3
            no_docu_found                  = 4
            object_is_already_enqueued     = 5
            object_is_enqueued_by_corr     = 6
            techn_enqueue_problem          = 7
            user_break                     = 8
            OTHERS                         = 9.
  
        IF sy-subrc <> 0.
          zcx_abapgit_exception=>raise_t100( ).
        ENDIF.
  
      ENDIF.
  
    ENDMETHOD.
  
  
    METHOD zif_abapgit_object~jump.
  
      CALL FUNCTION 'SUSR_SHOW_OBJECT'
        EXPORTING
          object = mv_objectname.
  
    ENDMETHOD.
  
  