Read classification certificates

In this example we are looking up the certificate qualifiers of a specific material for a plant.

  smat_read_bc        TYPE REF TO /aeb/cl_ta_pb_smat_read_bc,
  smat_mo             TYPE REF TO /aeb/if_ta_pb_smat_mo,
  tt_smat_cls_mo      TYPE /aeb/if_ta_pb_smat_cls_mo=>tt_smat_cls_mo,
  smat_cls_mo         TYPE REF TO /aeb/if_ta_pb_smat_cls_mo,
  country_iso_code_nv TYPE REF TO /aeb/cl_01_char_2_nv,
  tt_smat_cer_mo      TYPE /aeb/if_ta_pb_smat_cer_mo=>tt_smat_cer_mo,
  smat_cer_mo         TYPE REF TO /aeb/if_ta_pb_smat_cer_mo,
  qualifier           TYPE /aeb/ta_pb_cert_qualifier,
  qualifiers          TYPE STANDARD TABLE OF /aeb/ta_pb_cert_qualifier WITH DEFAULT KEY.

smat_read_bc = /aeb/cl_ta_pb_smat_read_bc=>new_for( im_material_no    = 'MAT_NO'
                                                    im_material_plant = 'PLANT' ).
smat_mo = smat_read_bc->get_material( ).
tt_smat_cls_mo = smat_mo->get_classifications( ).

LOOP AT tt_smat_cls_mo INTO smat_cls_mo.
  country_iso_code_nv = smat_cls_mo->get_ctry_iso_code( ).
  CASE country_iso_code_nv->v.
    WHEN 'DE'.
      tt_smat_cer_mo = smat_cls_mo->get_smat_cer_mos( ).
      LOOP AT tt_smat_cer_mo INTO smat_cer_mo.
        qualifier = smat_cer_mo->get_qualifier( ).
        APPEND qualifier TO qualifiers.