protected boolean handleIsContainedInBusinessProcess()
{
boolean containedInBusinessProcess = false;
if (this.getState() != null)
{
final StateMachineFacade stateMachine = this.getState().getStateMachine();
if (stateMachine instanceof ActivityGraphFacade)
{
final ActivityGraphFacade activityGraph = (ActivityGraphFacade)stateMachine;
containedInBusinessProcess = activityGraph.getUseCase() instanceof JBpmProcessDefinition;
}