コード例 #1
0
 /**
  * This method checks to determine whether the specified port is allowed to have incoming flows
  * attached to it.
  *
  * @param portView
  * @return true if flows can end at this port, false otherwise.
  */
 private boolean acceptsIncomingFlows(PortView portView) {
   CellView parentView = portView.getParentView();
   YAWLPort yawlPort = (YAWLPort) portView.getCell();
   YAWLCell vertex = (YAWLCell) parentView.getCell();
   return yawlPort.acceptsIncomingFlows()
       && vertex.acceptsIncomingFlows()
       && getNet().acceptsIncomingFlows(vertex);
 }
コード例 #2
0
 /**
  * This method checks to determine whether the specified port can have outgoing flows drawn from
  * it.
  *
  * @param portView
  * @return true if flows can start from this port, false otherwise.
  */
 private boolean generatesOutgoingFlows(PortView portView) {
   CellView parentView = portView.getParentView();
   YAWLPort yawlPort = (YAWLPort) portView.getCell();
   YAWLCell vertex = (YAWLCell) parentView.getCell();
   return yawlPort.generatesOutgoingFlows()
       && vertex.generatesOutgoingFlows()
       && getNet().generatesOutgoingFlows(vertex);
 }