02.05.2014 Views

CoreandServices.book - Ocean - Schlumberger

CoreandServices.book - Ocean - Schlumberger

CoreandServices.book - Ocean - Schlumberger

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Custom Processes<br />

The wrapper re-uses the definitions and information from the given Workstep to build a<br />

process:<br />

• An instance of the workstep argument package is used for state persistence of the<br />

process.<br />

• The workstep's UI is used for the Process settings dialog.<br />

The process UI will use whatever UI is provided for the workstep. It can be the default UI<br />

generated by <strong>Ocean</strong> or a custom UI you created.<br />

Using the <strong>Ocean</strong>-generated UI makes things easy. <strong>Ocean</strong> will transfer the data between<br />

your workstep’s argument package and the default UI automatically. <strong>Ocean</strong> takes the<br />

values the user enters into the UI and loads them into the argument package before the<br />

process runs. When the process is finished, <strong>Ocean</strong> pulls the output arguments from the<br />

argument package and populates the UI with them so the end user can see the results.<br />

Step 2 - Custom UI: Change UI Behavior<br />

If you have provided a custom UI, <strong>Ocean</strong> will not be able to connect your argument<br />

package to your custom UI. You will have to write the code to transfer the data between<br />

the UI and the argument package. This will be done when the user clicks on your Apply<br />

or OK buttons.<br />

Now your custom UI is going to be called from two different environments: from the<br />

Workflow editor and from the Process diagram. The behavior of your UI is different in<br />

each instance.<br />

As we saw previously, when your UI is called from the Workflow editor, the Apply button<br />

will update the argument package and call the argument package changed method.<br />

When your UI is called from the Process diagram, the behavior is different. The Apply<br />

button will still update the argument package, but then it needs to actually invoke the<br />

workstep behind it and then update the UI to display any output values.<br />

<strong>Schlumberger</strong> Private<br />

Workflow 6-341

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

Saved successfully!

Ooh no, something went wrong!