All files / src/persist zcl_abapgit_persist_factory.clas.abap

93.44% Statements 57/61
0% Branches 0/2
100% Functions 0/0
93.44% Lines 57/61

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 621x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x 1x     1x 1x 1x 1x 1x 1x 1x 1x 1x     1x 1x 1x 1x 1x  
CLASS zcl_abapgit_persist_factory DEFINITION
  PUBLIC
  CREATE PRIVATE
  GLOBAL FRIENDS zcl_abapgit_persist_injector .
 
  PUBLIC SECTION.
 
    CLASS-METHODS get_repo
      RETURNING
        VALUE(ri_repo) TYPE REF TO zif_abapgit_persist_repo .
    CLASS-METHODS get_repo_cs
      RETURNING
        VALUE(ri_repo_cs) TYPE REF TO zif_abapgit_persist_repo_cs .
    CLASS-METHODS get_settings
      RETURNING
        VALUE(ri_settings) TYPE REF TO zif_abapgit_persist_settings .
  PROTECTED SECTION.
  PRIVATE SECTION.
 
    CLASS-DATA gi_repo TYPE REF TO zif_abapgit_persist_repo .
    CLASS-DATA gi_repo_cs TYPE REF TO zif_abapgit_persist_repo_cs .
    CLASS-DATA gi_settings TYPE REF TO zif_abapgit_persist_settings .
ENDCLASS.
 
 
 
CLASS ZCL_ABAPGIT_PERSIST_FACTORY IMPLEMENTATION.
 
 
  METHOD get_repo.
 
    IF gi_repo IS INITIAL.
      CREATE OBJECT gi_repo TYPE zcl_abapgit_persistence_repo.
    ENDIF.
 
    ri_repo = gi_repo.
 
  ENDMETHOD.
 
 
  METHOD get_repo_cs.
 
    IF gi_repo_cs IS INITIAL.
      CREATE OBJECT gi_repo_cs TYPE zcl_abapgit_persistence_repo.
    ENDIF.
 
    ri_repo_cs = gi_repo_cs.
 
  ENDMETHOD.
 
 
  METHOD get_settings.
 
    IF gi_settings IS INITIAL.
      CREATE OBJECT gi_settings TYPE zcl_abapgit_persist_settings.
    ENDIF.
 
    ri_settings = gi_settings.
 
  ENDMETHOD.
ENDCLASS.