Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

ABAP Objects and Web Dynpro

Former Member
0 Likes
506

Hello everyone,

I would like to know if it is possible to have instances of a class as a part of a controller context. You know, like if you added a service call to a BAPI or a function group, but with method calls to an object instead.

I have a feeling, that it is uncommon to bring Web Dynpro and the object orientation of ABAP Objects together.

For example, i don't want the event handling code of my controllers to call function groups, which in turn make calls to my object oriented model. Is there a way to skip that nasty imperative step?

Sorry for asking questions which may sound vague or naive, I'm kind of a beginner regarding Web Dynpro and ABAP.

cheers,

Jens Barthel

3 REPLIES 3
Read only

narin_nandivada3
Active Contributor
0 Likes
478

Hi Jens,

Please check this thread..

Please check this for information regarding Webdynpro ABAP

/message/3396618#3396618 [original link is broken]

Hope this would give you some idea.

Good luck

Narin

Read only

0 Likes
478

Thanks Narin, I'll check.

Jens

Read only

alejandro_bindi
Active Contributor
0 Likes
478

There's no need at all to have function modules in the way.

You can have either controller attributes or context attributes defined as object references, and then call methods from those objects instead...

In both cases, you just have to use TYPE REF TO instead of TYPE when defining the attributes.

Furthermore, if you have a central class through which you interact with your OO model, you can define it as Assistance class and then you'll have an instance automatically in all the controllers...the drawback / advantage is that you do not control its instantiation which is done by the framework.

Regards

Edited by: Alejandro Bindi on Oct 14, 2008 6:23 PM