Using supertypes of attributes

Dart, Jocelyn jocelyn.dart at sap.com
Wed Jun 30 18:38:08 EDT 2004


Mike,
Use an "Interface" object to hold your attributes and/or method/parameters/exceptions names and assign the interface to all of the relevant objects - each object to provide their own implementation of the interface method.
Same concept as Java "interfaces".
Jocelyn.
 
-----Original Message-----
From: SAP Workflow [mailto:Owner-SAP-WUG at MITVMA.MIT.EDU] On Behalf Of Michael Pokraka
Sent: Thursday,1 July 2004 12:27 AM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Using supertypes of attributes
 
 
Hi all,
I've an attribute 'Sales Document' which is used in different workflows for
different document types (read: different Business objects). However I'm
struggling to keep it generic, as SAP won't let me assign a VBAK attribute
to e.g. a BUS2102 or a BUS2032 container element. The only (nasty)
workaround I can think of is to create a seperate attribute for each
document type.
Now, for methods a task can be created for a common supertype, and you can
call this method with any subtype without a problem. In the OO world this is
known as polymorpohism. I know this is expecting a bit much from business
objects, but still I'm curious if there is any sneaky way around creating
individual attributes....
Any ideas welcome,
Cheers
Mike
 


More information about the SAP-WUG mailing list