Documentation and textpool encapsulation

173 views
Skip to first unread message

VictorKostas

unread,
Jan 9, 2008, 6:06:24 AM1/9/08
to SAPlink
Hi all,

Since documentation and textpool should be included automatically in
download file when appropriate object is downloaded I moved textpool
and documentation methods at ZSAPLINK level.
E.g. when a class is downloaded class textpool and class documentation
will be included in dowload file. When a class is uploaded also
textpool and documentation will be uploaded.

I hope this change will be helpful.

Dan McWeeney

unread,
Jan 9, 2008, 10:38:23 AM1/9/08
to sap...@googlegroups.com
The only worry there is what about things like tables?  Do they have documentation?  Is it structure the same way?  Maybe we need to add a abstract method to the ZSAPLINK class so that plugin developers can include the documentation with their plugin.

Or are you saying that indeed every object from CLASSes to BW Cubes has the same API to access their documentation?

VictorKostas

unread,
Jan 10, 2008, 6:08:56 AM1/10/08
to SAPlink
Documentation is stored always in the same way. The only thing needed
is the combination of ID and OBJECT to access documentation.
E.g. tables/structures/views ID='TB', OBJECT=<table/str/view name>.
For Class and Message Class exist several ID-OBJECT combinations.
If requested I can give the whole changed package so SAPLink team can
use/amend it.

Following objects are documentation relevant (so far):
-CLASS
-DATA_ELEMENTS
-FUNCTIONGROUP
-MESSAGE_CLASS
-PROGRAM
-TABLES
-VIEWS

Above objects have the same idea for implementing documentation.
Probably all objects documentation-relevant not listed here will have
the same logic as above (tables DOKIL/DOKHL).

I have implemented several methods for documentation.
GET_DOCUMENTATION_SINGLE (Add single object documentation to XML)
CREATE_DOCUMENTATION (Create documentation from XML)
SET_DOCUKEY (Set Documentation id & object)
ADD_DOCUKEY (Add document key)
GET_DOCUMENTATION (Add documentation to XML)

The idea is to build a internal table of ID-OBJECT combinations
(ADD_DOCUKEY).
Then the internal table built before will be used in
CREATE_DOCUMENTATION/GET_DOCUMENTATION for upload/download.
Method SET_DOCUKEY is called from constructor. If SET_DOCUKEY is
redefined in a class (e.g. ZSAPLINK_PROGRAM) method add_docuKey( ID =
'??' Object = objName ) should be called.

Regards,
Victor

Nicola Fankhauser

unread,
Jan 11, 2008, 9:18:09 AM1/11/08
to sap...@googlegroups.com
hi

VictorKostas wrote:
> Since documentation and textpool should be included automatically in
> download file when appropriate object is downloaded I moved textpool
> and documentation methods at ZSAPLINK level.
> E.g. when a class is downloaded class textpool and class documentation
> will be included in dowload file. When a class is uploaded also
> textpool and documentation will be uploaded.

I think this feature is important. do you happen to know if there is
some possibility to edit documentation in a documentation-focused way in
the first place?

also I am quite irritated by the fact that in the ABAP workbench you
have no idea whether there is some documentation available for an ABAP
class or not - AFAIK the only way to find out is to press the little
button to display the documentation and hope there is some.

also while coding, not seeing the documentation right away is very
awkward and leads to the situation that no one writes any documentation
using the ABAP workbench.

does anyone here have some proven, best practices or ideas in this field?

thanks & regards
nicola

Eddie Herrmann

unread,
Jan 11, 2008, 10:24:47 AM1/11/08
to sap...@googlegroups.com
We have entertained the thought about creating an ABAPdoc add-on, that would work similar to Javadoc and ASDoc.  It would be similar to Onno's ABAPdoc for function modules, but it would be for classes and be developed as an add-on to SAPlink.  It would have an option to generate HTML documentation and include it in a nugget.

I know this doesn't necessarily solve your problem, but I thought I would at least throw it out there.

-ewH
Reply all
Reply to author
Forward
0 new messages