package rpc;

import org.springframework.beans.factory.annotation.Autowired;
import ru.cg.webbpm.modules.webkit.annotations.RpcCall;
import ru.cg.webbpm.modules.webkit.annotations.RpcService;
import ru.cg.webbpm.modules.webkit.beans.Behavior;
import service.ConfigExecutorService;

import java.util.List;

/**
 * @author Evgenii Malkov
 */
@RpcService
public class ConfigExecutorRpcService extends Behavior {

    private final ConfigExecutorService configExecutorService;

    public ConfigExecutorRpcService(@Autowired ConfigExecutorService configExecutorService) {
        this.configExecutorService = configExecutorService;
    }

    @RpcCall
    public void callConfigExecutor(String methodPath, List<String> ids) {
        configExecutorService.call(methodPath, ids);
    }
}
