package {{packageName}}.client.{{lowerCase api.codeName}}.runtime.service;

import lombok.extern.slf4j.Slf4j;
import net.ibizsys.central.r8.service.R8SubSysServiceAPIRuntime;
import net.ibizsys.central.service.ISubSysServiceAPIDERuntime;
import net.ibizsys.model.service.IPSSubSysServiceAPIDE;
import {{packageName}}.client.{{lowerCase api.codeName}}.runtime.service.dataentity.*;

/**
 * 提供外部容器启动服务能力
 */
@Slf4j
public class {{api.codeName}}R8SubSysServiceAPIRuntime extends R8SubSysServiceAPIRuntime {

    @Override
    protected ISubSysServiceAPIDERuntime createSubSysServiceAPIDERuntime(IPSSubSysServiceAPIDE iPSSubSysServiceAPIDE) throws Exception {
        String strEntityName = iPSSubSysServiceAPIDE.getName();
        switch (strEntityName){
{{#each api.apiEntities}}
            case "{{apiDataEntity.name}}":
                return new {{apiDataEntity.codeName}}SubSysServiceAPIDERuntime();
{{/each}}
            default:
                return new RT4EBSXR8SubSysServiceAPIDERuntime();
        }
    }
}