001package org.andromda.cartridges.jbpm.metafacades;
002
003import org.andromda.cartridges.jbpm.JBpmProfile;
004
005/**
006 * MetafacadeLogic implementation for org.andromda.cartridges.jbpm.metafacades.JBpmState.
007 *
008 * @see org.andromda.cartridges.jbpm.metafacades.JBpmState
009 */
010public class JBpmStateLogicImpl
011    extends JBpmStateLogic
012{
013    private static final long serialVersionUID = 34L;
014    /**
015     * @param metaObject
016     * @param context
017     */
018    public JBpmStateLogicImpl (Object metaObject, String context)
019    {
020        super (metaObject, context);
021    }
022
023    /**
024     * @return hasStereotype(JBpmProfile.STEREOTYPE_TASK)
025     */
026    protected boolean handleIsTaskNode()
027    {
028        return hasStereotype(JBpmProfile.STEREOTYPE_TASK);
029    }
030
031    /**
032     * @return getPartition()
033     * @see #getPartition()
034     */
035    protected Object handleGetSwimlane()
036    {
037        return this.getPartition();
038    }
039
040    /**
041     *
042     * @see org.andromda.cartridges.jbpm.metafacades.JBpmStateVertex#getNodeClassName()
043     */
044    @Override
045    public String getNodeClassName()
046    {
047        return this.getSuperJBpmEventState().getNodeClassName();
048    }
049
050    /**
051     *
052     * @see org.andromda.cartridges.jbpm.metafacades.JBpmStateVertex#getNodePackageName()
053     */
054    @Override
055    public String getNodePackageName()
056    {
057        return this.getSuperJBpmEventState().getNodePackageName();
058    }
059
060    /**
061     *
062     * @see org.andromda.cartridges.jbpm.metafacades.JBpmStateVertex#getProcessDefinition()
063     */
064    @Override
065    public JBpmProcessDefinition getProcessDefinition()
066    {
067        return this.getSuperJBpmEventState().getProcessDefinition();
068    }
069
070    /**
071     * <p>
072     * True if this element is part of a business process usecase.
073     * </p>
074     * @see org.andromda.cartridges.jbpm.metafacades.JBpmStateVertex#isContainedInBusinessProcess()
075     */
076    @Override
077    public boolean isContainedInBusinessProcess()
078    {
079        return this.getSuperJBpmEventState().isContainedInBusinessProcess();
080    }
081}