abapGit/src/zcl_abapgit_auth.clas.abap
Lars Hvam 68d0571516
More classes to global (#1209)
* lcl_background to global

* lcl_branch_overview to global

* lcl_services_git to global

* lcl_services_repo and lcl_services_db to global

* lcl_services_abapgit to global

* lcl_gui_chunk_lib to global

* lcl_gui_view_tutorial to global

* lif_auth to global

* lcl_auth and lcl_gui_view_repo to global

* lcl_view_repo

* lcl_gui_page_syntax to global

* 2 pages to global

* refactor router, less dynamic references

* background pages to global

* branch overview to global

* settings page to global

* repo settings page to global

* explore page to global

* diff page to global

* debug info to global

* main page to global

* refactor router, no dynamic references

* db pages to global

* router to global

* gui to global

* clean up includes

* move type definnition to interface

to avoid syntax error after abapmerge

* move types to interface

* move types to interface

* rename tyep

* move type

* move types

* move type
2018-02-17 12:40:54 +01:00

31 lines
757 B
ABAP

CLASS zcl_abapgit_auth DEFINITION PUBLIC FINAL CREATE PUBLIC.
PUBLIC SECTION.
CLASS-METHODS:
is_allowed
IMPORTING iv_authorization TYPE zif_abapgit_auth=>ty_authorization
iv_param TYPE string OPTIONAL
RETURNING VALUE(rv_allowed) TYPE abap_bool.
ENDCLASS.
CLASS ZCL_ABAPGIT_AUTH IMPLEMENTATION.
METHOD is_allowed.
DATA: li_auth TYPE REF TO zif_abapgit_auth.
TRY.
CREATE OBJECT li_auth TYPE ('ZCL_ABAPGIT_AUTH_EXIT').
rv_allowed = li_auth->is_allowed( iv_authorization = iv_authorization
iv_param = iv_param ).
CATCH cx_sy_create_object_error.
rv_allowed = abap_true.
ENDTRY.
ENDMETHOD.
ENDCLASS.