21.03.2013 Views

Object Oriented ABAP

Object Oriented ABAP

Object Oriented ABAP

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

22. How to use <strong>ABAP</strong> Classes in Process Steps of Business Workflow?<br />

In process steps we can use methods and attributes of <strong>ABAP</strong> classes in the same way as<br />

methods and attributes of Business <strong>Object</strong> Repository (BOR) objects. We can call these<br />

methods in the process context.<br />

Features:<br />

While using the <strong>ABAP</strong> Classes in the Process Steps the methods may contain dialogs, they<br />

can be synchronous or asynchronous; they may appear in the workflow log, and so on.<br />

In general, we can use any method that is implemented as a public method. The method<br />

can be implemented in the class itself, in one of the super classes of the class, or by way of<br />

an interface.<br />

The maximum permitted length for methods that are implemented by way of an interface,<br />

for example IF_WORKFLOW~FIND_BY_LPOR, is 30 characters. If the method name is too<br />

long, we can choose a shorter name for the method by defining an alias. If the method is<br />

implemented in the class or in a super class, the name of the method cannot be longer than<br />

30 characters, so this limitation does not apply.<br />

Parameters:<br />

We can assign values from the workflow container to the method parameters. Conversely,<br />

export parameters can be entered as workflow container values. The following overview<br />

shows how the individual types can be used as parameters:<br />

Simple types (string, integer, and so on)<br />

Data Dictionary types (structures, tables, complex types)<br />

References to objects from the Business <strong>Object</strong> Repository<br />

References to <strong>ABAP</strong> classes (supporting the IF_WORKFLOW interface)<br />

We can transfer method parameters that represent a persistent object (IF_WORKFLOW or<br />

BOR <strong>Object</strong>) in the following ways:<br />

<strong>ABAP</strong> classes (with IF_WORKFLOW interface)<br />

TYPE SIBFLPORB<br />

<strong>Object</strong> is transferred using the persistent display<br />

TYPE REF TO

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!