Fuego Process API

fuego.papi
Interface ProcessDiagram


public interface ProcessDiagram

This interface represents the diagram of a given process. It has several methods to decorate the process or add different labels to activities and other objects.


Field Summary
static String THEME_BPMN
           
static String THEME_BUSINESS_ANALYST
           
static String THEME_CLASSIC
           
static String THEME_COLOR_BPMN
           
static String THEME_UML
           
static String[] themes
           
static String TRANSITION_CONDITION
           
static String TRANSITION_DESCRIPTION
           
static String TRANSITION_NAME
           
 
Method Summary
 BufferedImage getIconForActivity(String activityId)
          Gets the icon image of the activity using the selected theme.
 BufferedImage getImage()
          Gets the image of the process.
 BufferedImage getImageForActivity(String activityId)
          Gets the image being used to render the activity shape by returning the corresponding image taken from the used theme or the custom image if the designer has used a local image
 String getRelativePathForActivityIconImage(String activityId)
           
 String getRelativePathForActivityImage(String activityId)
           
 Shape getShapeForActivity(String activityId)
          Gets the shape of the bounds of the passed activity
 void highlightActivityPath(String[] activityIds)
          Sets an activity path to be highlighted in the process diagram.
 void setDrawFlowOnly(boolean value)
          Sets the diagram to draw only the flow of the process excluding global activities and roles with only globals inside
 void setHorizontalDrawing(boolean isHorizontalDrawing)
          Defines if the process will be drawn horizontally.
 void setLocale(Locale loc)
          Sets the default locale for the process so all visible labels are printed in this locale if available Otherwise the default locale will be used.
 void setScale(float scale)
           
 void setTheme(String themeName)
          Sets the theme to be used in the drawing
 void setTransitionMessageType(String type)
          Sets what to render as label for conditional transitions
 void showIconInActivity(String activityId, ImageIcon icon)
          Shows an icon in the upper right side of the activity
 void showTextInActivity(String activityId, String text)
          Sets a label to be located in the upper side of the activity.
 

Field Detail

TRANSITION_CONDITION


public static final String TRANSITION_CONDITION
See Also:
Constant Field Values

TRANSITION_NAME


public static final String TRANSITION_NAME
See Also:
Constant Field Values

TRANSITION_DESCRIPTION


public static final String TRANSITION_DESCRIPTION
See Also:
Constant Field Values

THEME_CLASSIC


public static final String THEME_CLASSIC
See Also:
Constant Field Values

THEME_UML


public static final String THEME_UML
See Also:
Constant Field Values

THEME_BPMN


public static final String THEME_BPMN
See Also:
Constant Field Values

THEME_COLOR_BPMN


public static final String THEME_COLOR_BPMN
See Also:
Constant Field Values

THEME_BUSINESS_ANALYST


public static final String THEME_BUSINESS_ANALYST
See Also:
Constant Field Values

themes


public static final String[] themes
Method Detail

setDrawFlowOnly


public void setDrawFlowOnly(boolean value)
Sets the diagram to draw only the flow of the process excluding global activities and roles with only globals inside

Parameters:
value -

setHorizontalDrawing


public void setHorizontalDrawing(boolean isHorizontalDrawing)
Defines if the process will be drawn horizontally. This means roles as rows intead of roles as columns

Parameters:
isHorizontalDrawing -

getIconForActivity


public BufferedImage getIconForActivity(String activityId)
Gets the icon image of the activity using the selected theme.

Parameters:
activityId -
Returns:

getImage


public BufferedImage getImage()
Gets the image of the process. This method should be invoked after setting all the texts and decorations to the process

Returns:
The image of the process

getImageForActivity


public BufferedImage getImageForActivity(String activityId)
Gets the image being used to render the activity shape by returning the corresponding image taken from the used theme or the custom image if the designer has used a local image

Parameters:
activityId -
Returns:
The image of the activity

setLocale


public void setLocale(Locale loc)
Sets the default locale for the process so all visible labels are printed in this locale if available Otherwise the default locale will be used.

Parameters:
loc -

getRelativePathForActivityIconImage


public String getRelativePathForActivityIconImage(String activityId)

getRelativePathForActivityImage


public String getRelativePathForActivityImage(String activityId)

setScale


public void setScale(float scale)

getShapeForActivity


public Shape getShapeForActivity(String activityId)
Gets the shape of the bounds of the passed activity

Parameters:
activityId - - The activity's name
Returns:
The shape with the activity's bound inside the image.

setTheme


public void setTheme(String themeName)
Sets the theme to be used in the drawing

Parameters:
themeName -

setTransitionMessageType


public void setTransitionMessageType(String type)
Sets what to render as label for conditional transitions

Parameters:
type - The type of message to render: TRANSITION_CONDITION, TRANSITION_NAME, TRANSITION_DESCRIPTION
See Also:
TRANSITION_CONDITION, TRANSITION_NAME, TRANSITION_DESCRIPTION

highlightActivityPath


public void highlightActivityPath(String[] activityIds)
Sets an activity path to be highlighted in the process diagram. By passing null the highlighted path is reset

Parameters:
activityIds -

showIconInActivity


public void showIconInActivity(String activityId,
                               ImageIcon icon)
Shows an icon in the upper right side of the activity

Parameters:
activityId -
icon -

showTextInActivity


public void showTextInActivity(String activityId,
                               String text)
Sets a label to be located in the upper side of the activity. Label's lengths should not be greater than 100 characters

Parameters:
activityId -
text -

Fuego Process API

© Copyright 1996/2003 Fuego Inc. All Rights Reserved