package cn.stylefeng.workflow.instance.api;

import cn.stylefeng.workflow.api.entity.instance.RuntimeInstance;
import cn.stylefeng.workflow.api.entity.instance.RuntimeNode;
import cn.stylefeng.workflow.api.pojo.InstanceContext;
import cn.stylefeng.workflow.api.pojo.InstanceVariable;

import java.util.List;
import java.util.Map;

public interface WorkflowStatusApi {

    InstanceContext buildInstanceContext(Long instanceId);

    InstanceContext buildInstanceContext(Long definitionId, Long instanceId);

    InstanceContext buildInstanceContext(Long definitionId, RuntimeInstance runtimeInstance, InstanceVariable instanceVariable);

    boolean getInstanceFinishFlag(InstanceContext instanceContext);

    List<RuntimeNode> getCurrentRuntimeNodeList(Long instanceId);

    Map<Long, List<RuntimeNode>> getCurrentRuntimeNodeList(List<Long> instanceIdList);

}
