The HR Reporting reuse class CL_HRGRT_DOCUMENT_CONTAINER
, aka the Document Container,
is the singleton instance into which you place the output from your report. This output is then automatically fetched by the Document
Display
UIBB.
The singleton state is ensured because the constructor is a private method, so it cannot be called externally, but is called internally by method GET_INSTANCE
.At INITIALIZE
in your feeder class, you call the super class INITIALIZE
method which calls the GET_INSTANCE
method of the Document Container. The attribute GO_INSTANCE
on
this class is a reference to the class itself, so the method GET_INSTANCE
checks if the reference is bound, and only creates the instance if the reference is still initial.
Since the Document Display UIBB HRGRT_FC_DOCUMENT_DISPLAY
fetches the data from the Document Container, there are only two steps for you to carry out in your feeder class:
At INITIALIZE
, ensure the class is instantiated. If you have not redefined this method, this is done for you already in the super method. If you must redefine for other reasons, all you need do is call the super method, also see Get
the Global Data (Method INITIALIZE).
At GET_DATA
, move the output from your reporting scenario to the Document Container using its method SET_DOCUMENT
.
Note
See the class constants in GC_DOC_TYPE
to know what to use when filling the method parameter IV_CONTENT_TYPE
. The method needs to know whether it is a PDF, spreadsheet and so on.
Caution
Currently the only document types supported are PDF and Office types.