Create an abap report that creates a full functional class diagram including comments, and relations (also compositions) by reading the source code of a class.

Code to extract the data:
  TRY.
* Objektname: Klasse oder Interface
    DATA(lv_obj_name) = |ZCA_NN_NEURON|.

    DATA(o_source) = cl_oo_factory=>create_instance( )->create_clif_source( clif_name = lv_obj_name
                                                                            version   = if_oo_clif_source=>co_version_active ).

* Typ ausgeben
    WRITE: / COND string( WHEN o_source->get_type( ) = 0 THEN 'Class' ELSE 'Interface' ).

    ULINE.

* Code zum Objekt holen
    DATA(it_code) = VALUE rswsourcet( ).
    o_source->get_source( IMPORTING source = it_code ).

* Code ausgeben
*    LOOP AT it_code ASSIGNING FIELD-SYMBOL(<c>).
*      WRITE: / <c>.
*    ENDLOOP.

  CATCH cx_root INTO DATA(e_txt).
    WRITE: / e_txt->get_text( ).
ENDTRY.

Example Sourcecode:
TABLE_LINE
CLASS zca_nn_neuron DEFINITION
  PUBLIC
  FINAL
  CREATE PUBLIC.

  PUBLIC SECTION.

    TYPES:
      BEGIN OF ts_weight,
        value        TYPE float,
        gradient     TYPE float,
        target       TYPE zca_nn_neuid,
        mutationrate TYPE float,
      END OF ts_weight.

    "! Weights of this neuron
    TYPES tt_weights TYPE STANDARD TABLE OF ts_weight WITH DEFAULT KEY.

    DATA layer_number TYPE i.
    DATA neuron_index TYPE zca_nn_neuid.
    DATA neuron_value TYPE float.
    DATA neuron_gradient TYPE float.

    "! Weights of this neuron
    DATA gt_weights TYPE tt_weights.

    "! Constructor
    "! @parameter iv_layernumber | ID of the layer this neuron belongs to
    "! @parameter iv_neuronindex | ID of this neuron
    "! @parameter iv_neuronvalue | Value of this neuron
    "! @parameter it_weights | Weights of this neuron
    METHODS constructor
      IMPORTING
        !iv_layernumber TYPE i
        !iv_neuronindex TYPE i
        !iv_neuronvalue TYPE float
        !it_weights     TYPE tt_weights.

    "! Activates the neuron
    "! @parameter iv_function | Determines the activation function
    METHODS activateneuron
      IMPORTING
        !iv_function TYPE zca_nn_math=>tv_activation_function.

    "! Sets the desired value of the neuron
    "! @parameter iv_function | Activation function
    "! @parameter iv_value | Desired value
    METHODS set_desired
      IMPORTING
        !iv_function TYPE zca_nn_math=>tv_activation_function
        !iv_value    TYPE float.

    "! Computes the gradient of the neuron
    "! @parameter iv_function | Activation function
    "! @parameter iv_value | Desired value
    METHODS computegradient
      IMPORTING
        !iv_function TYPE zca_nn_math=>tv_activation_function
        !iv_value    TYPE float.

    "! Computes the gradient of the hidden layer
    "! @parameter iv_function | Activation function
    "! @parameter iv_value | Desired value
    METHODS computegradienthidden
      IMPORTING
        !iv_function TYPE zca_nn_math=>tv_activation_function
        !iv_value    TYPE float.
  PROTECTED SECTION.
  PRIVATE SECTION.
ENDCLASS.



CLASS zca_nn_neuron IMPLEMENTATION.


  METHOD activateneuron.
    neuron_value = zca_nn_math=>activationfunction( iv_param = iv_function iv_value = neuron_value ).
  ENDMETHOD.


  METHOD computegradient.
    DATA(lv_error) = neuron_value - iv_value.
    DATA(gradient_out) = lv_error.
*    DATA(gradient_out) = 2 * lv_error.
    neuron_gradient = gradient_out * zca_nn_math=>activationfunctionderivate( iv_param = iv_function iv_value = neuron_value ).
  ENDMETHOD.


  METHOD computegradienthidden.
    neuron_gradient = iv_value * zca_nn_math=>activationfunctionderivate( iv_param = iv_function iv_value = neuron_value ).
  ENDMETHOD.


  METHOD constructor.
    layer_number = iv_layernumber.
    neuron_index = iv_neuronindex.
    neuron_value = iv_neuronvalue.
    gt_weights = it_weights.
  ENDMETHOD.


  METHOD set_desired.
    computegradient( iv_function = iv_function iv_value = iv_value ).
  ENDMETHOD.
ENDCLASS.