Compare commits
95 Commits
91adb9517e
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| 094dcf857d | |||
| 50a369c722 | |||
|
|
b97f9aa32b | ||
| 11e25fd0de | |||
| eb57d2d228 | |||
| bcb0ca03b1 | |||
| 7610076760 | |||
| e52aaa1680 | |||
|
|
fecfb8d39c | ||
|
|
150966824e | ||
|
|
a4d9e8d8eb | ||
|
|
a0d8f555f9 | ||
|
|
705021b391 | ||
|
|
889cc02631 | ||
|
|
cc1e003bc4 | ||
| eeed692ba6 | |||
| b3563a05d6 | |||
| a7c19fb7e7 | |||
| 36809d4033 | |||
| 1dba7584cd | |||
| 35d2766442 | |||
| ce832fb16d | |||
| e9503358d3 | |||
| 3b3370c440 | |||
| d8719c30c6 | |||
| 9ff0e50bba | |||
|
|
2838938cfa | ||
| c4cc3cc30b | |||
|
|
d1f720f691 | ||
|
|
cb1019b7d7 | ||
| 18827cfbe7 | |||
| 3fe32e4ac3 | |||
|
|
168ced6b27 | ||
|
|
499734efe8 | ||
|
|
27c8fc13c6 | ||
|
|
505092bcf4 | ||
|
|
41ba11dc9b | ||
|
|
158512cd12 | ||
|
|
3a3ab0c9c6 | ||
|
|
b08c74260d | ||
|
|
02e9ca26a1 | ||
|
|
8958ecd6dc | ||
|
|
6656479327 | ||
|
|
18ccf490e4 | ||
| 4a0602ce4e | |||
| 8844830afc | |||
| bcc450141e | |||
| 25e6ac1cbe | |||
| 8b2f4dab89 | |||
| 4f60d68c4f | |||
| b63ad360d0 | |||
|
|
c724a7acf7 | ||
|
|
185e490560 | ||
|
|
d13359c803 | ||
|
|
65ea1cfd6b | ||
|
|
4455d38a61 | ||
|
|
6dd4392f0c | ||
|
|
974f403784 | ||
|
|
82bbfb83ca | ||
|
|
fc7b5e6c63 | ||
|
|
8dc867acb6 | ||
|
|
c17197d6e5 | ||
| 76022cf09a | |||
| 4ff5bf500c | |||
| be417189e0 | |||
| a88d74ea1d | |||
|
|
c2bfb43d41 | ||
|
|
c5d81a4c52 | ||
|
|
6d76cb8d5e | ||
|
|
b97837ec6a | ||
|
|
f2e81c6e5c | ||
|
|
83a38c6db8 | ||
|
|
22e71a24d3 | ||
|
|
6019738aca | ||
| 7847dbc89f | |||
| cc01c9ece8 | |||
| 8f29e230d0 | |||
| 711d7bf3da | |||
|
|
29e17773af | ||
|
|
db97d8a026 | ||
|
|
2e55254412 | ||
|
|
1504c3fc1b | ||
|
|
0cf4c9b47e | ||
|
|
fa0c93044c | ||
|
|
33a77428db | ||
| 26a89a66d1 | |||
| f72105134f | |||
|
|
2198e108a4 | ||
|
|
fe94cec559 | ||
| af3a97175a | |||
| c1c67e826b | |||
| 8a946c4c84 | |||
| d9a55d0c95 | |||
|
|
7b578f5d63 | ||
| dde470c9da |
@@ -76,6 +76,11 @@
|
|||||||
<artifactId>solution-rule</artifactId>
|
<artifactId>solution-rule</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.solution</groupId>
|
||||||
|
<artifactId>solution-scene</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
|
|||||||
@@ -42,6 +42,12 @@ public class BehaviortreeController extends BaseController
|
|||||||
@Autowired
|
@Autowired
|
||||||
private BehaviortreeProcessor behaviortreeProcessor;
|
private BehaviortreeProcessor behaviortreeProcessor;
|
||||||
|
|
||||||
|
@GetMapping(value = "/platform/{id}")
|
||||||
|
public AjaxResult fromPlatform(@PathVariable("id") Integer id)
|
||||||
|
{
|
||||||
|
return success(behaviortreeService.findOneByPlatformId(id));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询行为树主列表
|
* 查询行为树主列表
|
||||||
*/
|
*/
|
||||||
@@ -114,4 +120,5 @@ public class BehaviortreeController extends BaseController
|
|||||||
{
|
{
|
||||||
return toAjax(behaviortreeService.deleteBehaviortreeByIds(ids));
|
return toAjax(behaviortreeService.deleteBehaviortreeByIds(ids));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package com.solution.web.controller.behaviour;
|
||||||
|
|
||||||
|
import com.solution.common.core.controller.BaseController;
|
||||||
|
import com.solution.common.core.domain.AjaxResult;
|
||||||
|
import com.solution.system.service.HbNodeCommandService;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/node/command")
|
||||||
|
public class HbNodeCommandController extends BaseController {
|
||||||
|
|
||||||
|
private final HbNodeCommandService nodeCommandService;
|
||||||
|
|
||||||
|
public HbNodeCommandController(HbNodeCommandService nodeCommandService) {
|
||||||
|
this.nodeCommandService = nodeCommandService;
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping(value = "/all")
|
||||||
|
public AjaxResult all() {
|
||||||
|
return success(nodeCommandService.findAll());
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,114 @@
|
|||||||
|
package com.solution.web.controller.rule;
|
||||||
|
|
||||||
|
import com.solution.common.core.controller.BaseController;
|
||||||
|
import com.solution.common.core.domain.AjaxResult;
|
||||||
|
import com.solution.rule.domain.FireRuleExecuteDTO;
|
||||||
|
import com.solution.rule.domain.simplerulepojo.Task;
|
||||||
|
import com.solution.rule.domain.ultimately.dto.FireRuleInputDTO;
|
||||||
|
import com.solution.rule.service.FireRuleService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Api("火力规则")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/system/firerule")
|
||||||
|
public class FireRuleController extends BaseController {
|
||||||
|
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private FireRuleService ruleService;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 开始执行规则匹配
|
||||||
|
* @param fireRuleExecuteDTO 敌方参数
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@PostMapping("/start")
|
||||||
|
@ApiOperation("开始执行规则匹配")
|
||||||
|
public AjaxResult execute(@RequestBody FireRuleExecuteDTO fireRuleExecuteDTO){
|
||||||
|
return success(ruleService.execute(fireRuleExecuteDTO));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取所有武器平台和组件
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GetMapping("/weapon")
|
||||||
|
@ApiOperation("获取所有武器平台和组件")
|
||||||
|
public AjaxResult getPlatformComponentNames(){
|
||||||
|
return success(ruleService.getPlatformComponentNames());
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取通信组件的所有平台和组件
|
||||||
|
* @param scenarioId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GetMapping("/comm")
|
||||||
|
@ApiOperation("获取通信组件的所有平台和组件")
|
||||||
|
public AjaxResult getCommPlatformComponentNames(Integer scenarioId){
|
||||||
|
return success(ruleService.getCommPlatformComponentNames(scenarioId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据场景id获取所有平台及其组件
|
||||||
|
* @param scenarioId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GetMapping("/platforms/{scenarioId}")
|
||||||
|
public AjaxResult platformsScenarioId(@PathVariable Integer scenarioId){
|
||||||
|
return success(ruleService.findPlatformComponents(scenarioId));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/platforms")
|
||||||
|
public AjaxResult platforms(){
|
||||||
|
return success(ruleService.findAllPlatformComponents());
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/platforms/basic")
|
||||||
|
public AjaxResult platformsBasic(){
|
||||||
|
return success(ruleService.findAllBasicPlatformComponents());
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据平台id获取平台下所有组件
|
||||||
|
* @param platformId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GetMapping("/component/{platformId}")
|
||||||
|
@ApiOperation("根据平台id获取平台下所有组件")
|
||||||
|
public AjaxResult getComponents(@PathVariable Integer platformId){
|
||||||
|
return success(ruleService.getComponents(platformId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 开始执行规则匹配
|
||||||
|
* @param task 敌方参数
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@PostMapping("/rule")
|
||||||
|
@ApiOperation("开始执行规则匹配")
|
||||||
|
public AjaxResult execute(@RequestBody Task task){
|
||||||
|
return success(ruleService.executeTask(task));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 开始执行规则匹配
|
||||||
|
* @param task 敌方参数
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@PostMapping("/rule")
|
||||||
|
@ApiOperation("开始执行规则匹配")
|
||||||
|
public AjaxResult rule(@RequestBody FireRuleInputDTO task){
|
||||||
|
return success(ruleService.rule(task));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,56 +1,65 @@
|
|||||||
package com.solution.web.controller.rule;
|
package com.solution.web.controller.rule;
|
||||||
|
|
||||||
|
import com.solution.common.annotation.Log;
|
||||||
import com.solution.common.core.controller.BaseController;
|
import com.solution.common.core.controller.BaseController;
|
||||||
import com.solution.common.core.domain.AjaxResult;
|
import com.solution.common.core.domain.AjaxResult;
|
||||||
import com.solution.rule.domain.FireRuleExecuteDTO;
|
import com.solution.common.core.page.TableDataInfo;
|
||||||
import com.solution.rule.service.RuleService;
|
import com.solution.common.enums.BusinessType;
|
||||||
|
import com.solution.rule.domain.Rule;
|
||||||
|
import com.solution.rule.service.IRuleService;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Api("红蓝对抗规则管理")
|
||||||
@Api("火力规则")
|
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/api/system/firerule")
|
@RequestMapping("/api/system/rule")
|
||||||
public class RuleController extends BaseController {
|
public class RuleController extends BaseController {
|
||||||
|
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private RuleService ruleService;
|
private IRuleService ruleService;
|
||||||
|
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:rule:list')")
|
||||||
/**
|
@GetMapping("/list")
|
||||||
* 开始执行规则匹配
|
@ApiOperation("查询规则列表")
|
||||||
* @param fireRuleExecuteDTO 敌方参数
|
public TableDataInfo list(Rule rule) {
|
||||||
* @return
|
startPage();
|
||||||
*/
|
List<Rule> list = ruleService.selectRuleList(rule);
|
||||||
@PostMapping("/start")
|
return getDataTable(list);
|
||||||
@ApiOperation("开始执行规则匹配")
|
|
||||||
public AjaxResult execute(@RequestBody FireRuleExecuteDTO fireRuleExecuteDTO){
|
|
||||||
return success(ruleService.execute(fireRuleExecuteDTO));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PreAuthorize("@ss.hasPermi('system:rule:query')")
|
||||||
* 获取所有武器平台和组件
|
@GetMapping("/{id}")
|
||||||
* @return
|
@ApiOperation("获取规则详情")
|
||||||
*/
|
public AjaxResult getInfo(@PathVariable Integer id) {
|
||||||
@GetMapping("/weapon")
|
return success(ruleService.selectRuleById(id));
|
||||||
@ApiOperation("获取所有武器平台和组件")
|
|
||||||
public AjaxResult getPlatformComponentNames(){
|
|
||||||
return success(ruleService.getPlatformComponentNames());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PreAuthorize("@ss.hasPermi('system:rule:add')")
|
||||||
* 获取通信组件的所有平台和组件
|
@Log(title = "规则管理", businessType = BusinessType.INSERT)
|
||||||
* @param scenarioId
|
@PostMapping
|
||||||
* @return
|
@ApiOperation("新增规则")
|
||||||
*/
|
public AjaxResult add(@RequestBody Rule rule) {
|
||||||
@GetMapping("/comm")
|
return toAjax(ruleService.insertRule(rule));
|
||||||
@ApiOperation("获取通信组件的所有平台和组件")
|
|
||||||
public AjaxResult getCommPlatformComponentNames(Integer scenarioId){
|
|
||||||
return success(ruleService.getCommPlatformComponentNames(scenarioId));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:rule:edit')")
|
||||||
|
@Log(title = "规则管理", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
@ApiOperation("修改规则")
|
||||||
|
public AjaxResult edit(@RequestBody Rule rule) {
|
||||||
|
return toAjax(ruleService.updateRule(rule));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:rule:remove')")
|
||||||
|
@Log(title = "规则管理", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
@ApiOperation("删除规则")
|
||||||
|
public AjaxResult remove(@PathVariable Integer[] ids) {
|
||||||
|
return toAjax(ruleService.deleteRuleByIds(ids));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
package com.solution.web.controller.scene;
|
||||||
|
|
||||||
|
import com.solution.common.annotation.Log;
|
||||||
|
import com.solution.common.core.controller.BaseController;
|
||||||
|
import com.solution.common.core.domain.AjaxResult;
|
||||||
|
import com.solution.common.core.page.TableDataInfo;
|
||||||
|
import com.solution.common.enums.BusinessType;
|
||||||
|
import com.solution.scene.domain.AfsimScenario;
|
||||||
|
import com.solution.scene.domain.AfsimScenarioForm;
|
||||||
|
import com.solution.scene.service.SceneService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 场景管理
|
||||||
|
*/
|
||||||
|
@Api("场景管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/system/scene")
|
||||||
|
public class SceneController extends BaseController {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private SceneService sceneService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 保存场景配置
|
||||||
|
*/
|
||||||
|
@ApiOperation("保存场景配置")
|
||||||
|
@PostMapping("/saveSceneConfig")
|
||||||
|
@Log(title = "行为树主", businessType = BusinessType.INSERT)
|
||||||
|
public AjaxResult saveSceneConfig(@RequestBody AfsimScenario afsimScenario)
|
||||||
|
{
|
||||||
|
return toAjax(sceneService.saveOrUpdate(afsimScenario));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取场景列表
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GetMapping("/list")
|
||||||
|
@ApiOperation("获取场景列表")
|
||||||
|
public TableDataInfo list(){
|
||||||
|
startPage();
|
||||||
|
List<AfsimScenario> list = sceneService.selectSceneList();
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return success(sceneService.findOneById(id));
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -20,8 +20,11 @@ import com.solution.web.core.graph.GraphEdge;
|
|||||||
import com.solution.web.core.graph.GraphNode;
|
import com.solution.web.core.graph.GraphNode;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
import org.springframework.util.StringUtils;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
@Component
|
@Component
|
||||||
@@ -98,12 +101,19 @@ public class BehaviortreeProcessor {
|
|||||||
instanceKeyMap.put(node.getKey(), instance);
|
instanceKeyMap.put(node.getKey(), instance);
|
||||||
|
|
||||||
if (node.hasParameters()) {
|
if (node.hasParameters()) {
|
||||||
|
if (node.isMultiable()) {
|
||||||
|
List<Nodeparameter> nodeparameters = createMultiableNodeparameter(behaviortree, node, instance);
|
||||||
|
for (Nodeparameter nodeparameter : nodeparameters) {
|
||||||
|
nodeparameterService.insertNodeparameter(nodeparameter);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
// 插入parameter nodeparameter
|
// 插入parameter nodeparameter
|
||||||
for (Templateparameterdef parameter : node.getParameters()) {
|
for (Templateparameterdef parameter : node.getParameters()) {
|
||||||
Nodeparameter nodeparameter = createNodeParameter(behaviortree, parameter, instance);
|
Nodeparameter nodeparameter = createNodeParameter(behaviortree, parameter, instance);
|
||||||
nodeparameterService.insertNodeparameter(nodeparameter);
|
nodeparameterService.insertNodeparameter(nodeparameter);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
nodeKeyIndexMap.put(node.getKey(), index);
|
nodeKeyIndexMap.put(node.getKey(), index);
|
||||||
|
|
||||||
index++;
|
index++;
|
||||||
@@ -148,6 +158,47 @@ public class BehaviortreeProcessor {
|
|||||||
return connection;
|
return connection;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private List<Nodeparameter> createMultiableNodeparameter(Behaviortree behaviortree, GraphNode node,
|
||||||
|
Treenodeinstance instance) {
|
||||||
|
|
||||||
|
List<Nodeparameter> nodeparameters = new ArrayList<>();
|
||||||
|
|
||||||
|
Map<Long, List<String>> idValues = new HashMap<>();
|
||||||
|
List<String> tmpValues = null;
|
||||||
|
Map<Long, List<Templateparameterdef>> mappedValues = new HashMap<>();
|
||||||
|
List<Templateparameterdef> tmpDefs = null;
|
||||||
|
|
||||||
|
for (Templateparameterdef parameter : node.getParameters()) {
|
||||||
|
tmpDefs = mappedValues.get(parameter.getId() );
|
||||||
|
if (null == tmpDefs) {
|
||||||
|
tmpDefs = new ArrayList<>();
|
||||||
|
}
|
||||||
|
tmpDefs.add(parameter);
|
||||||
|
mappedValues.put(parameter.getId(), tmpDefs);
|
||||||
|
|
||||||
|
tmpValues = idValues.get(parameter.getId() );
|
||||||
|
if (null == tmpValues) {
|
||||||
|
tmpValues = new ArrayList<>();
|
||||||
|
}
|
||||||
|
tmpValues.add(parameter.getDefaultValue());
|
||||||
|
idValues.put(parameter.getId(), tmpValues);
|
||||||
|
}
|
||||||
|
|
||||||
|
int index = 0;
|
||||||
|
for (Long id : idValues.keySet()) {
|
||||||
|
tmpValues = idValues.get(id);
|
||||||
|
Nodeparameter nodeparameter = new Nodeparameter();
|
||||||
|
nodeparameter.setTreeId(behaviortree.getId());
|
||||||
|
nodeparameter.setNodeInstanceId(instance.getId());
|
||||||
|
nodeparameter.setParamDefId(id);
|
||||||
|
nodeparameter.setValue(StringUtils.collectionToCommaDelimitedString(tmpValues));
|
||||||
|
nodeparameter.setGroupIndex(index);
|
||||||
|
nodeparameters.add(nodeparameter);
|
||||||
|
index++;
|
||||||
|
}
|
||||||
|
return nodeparameters;
|
||||||
|
}
|
||||||
|
|
||||||
private Nodeparameter createNodeParameter(Behaviortree behaviortree, Templateparameterdef parameter,
|
private Nodeparameter createNodeParameter(Behaviortree behaviortree, Templateparameterdef parameter,
|
||||||
Treenodeinstance instance) {
|
Treenodeinstance instance) {
|
||||||
Nodeparameter nodeparameter = new Nodeparameter();
|
Nodeparameter nodeparameter = new Nodeparameter();
|
||||||
@@ -155,6 +206,7 @@ public class BehaviortreeProcessor {
|
|||||||
nodeparameter.setNodeInstanceId(instance.getId());
|
nodeparameter.setNodeInstanceId(instance.getId());
|
||||||
nodeparameter.setParamDefId(parameter.getId());
|
nodeparameter.setParamDefId(parameter.getId());
|
||||||
nodeparameter.setValue(parameter.getDefaultValue());
|
nodeparameter.setValue(parameter.getDefaultValue());
|
||||||
|
nodeparameter.setGroupIndex(parameter.getGroupIndex());
|
||||||
return nodeparameter;
|
return nodeparameter;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -170,4 +222,5 @@ public class BehaviortreeProcessor {
|
|||||||
return instance;
|
return instance;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -33,6 +33,8 @@ public class GraphNode implements Serializable {
|
|||||||
|
|
||||||
private String category;
|
private String category;
|
||||||
|
|
||||||
|
private boolean multiable;
|
||||||
|
|
||||||
private List<Templateparameterdef> parameters;
|
private List<Templateparameterdef> parameters;
|
||||||
|
|
||||||
private List<GraphVariable> variables;
|
private List<GraphVariable> variables;
|
||||||
@@ -61,6 +63,14 @@ public class GraphNode implements Serializable {
|
|||||||
'}';
|
'}';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isMultiable() {
|
||||||
|
return multiable;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMultiable(boolean multiable) {
|
||||||
|
this.multiable = multiable;
|
||||||
|
}
|
||||||
|
|
||||||
public String getCategory() {
|
public String getCategory() {
|
||||||
return category;
|
return category;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -46,6 +46,17 @@ public class Behaviortree extends BaseEntity
|
|||||||
@Excel(name = "储存行为树的节点关系图")
|
@Excel(name = "储存行为树的节点关系图")
|
||||||
private String xmlContent;
|
private String xmlContent;
|
||||||
|
|
||||||
|
@Excel(name = "平台ID")
|
||||||
|
private Integer platformId;
|
||||||
|
|
||||||
|
public Integer getPlatformId() {
|
||||||
|
return platformId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPlatformId(Integer platformId) {
|
||||||
|
this.platformId = platformId;
|
||||||
|
}
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
@@ -118,14 +129,15 @@ public class Behaviortree extends BaseEntity
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
return "Behaviortree{" +
|
||||||
.append("id", getId())
|
"id=" + id +
|
||||||
.append("name", getName())
|
", name='" + name + '\'' +
|
||||||
.append("description", getDescription())
|
", description='" + description + '\'' +
|
||||||
.append("createdAt", getCreatedAt())
|
", createdAt=" + createdAt +
|
||||||
.append("updatedAt", getUpdatedAt())
|
", updatedAt=" + updatedAt +
|
||||||
.append("englishName", getEnglishName())
|
", englishName='" + englishName + '\'' +
|
||||||
.append("xmlContent", getXmlContent())
|
", xmlContent='" + xmlContent + '\'' +
|
||||||
.toString();
|
", platformId=" + platformId +
|
||||||
|
'}';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,55 @@
|
|||||||
|
package com.solution.system.domain;
|
||||||
|
/*
|
||||||
|
* This file is part of the kernelstudio package.
|
||||||
|
*
|
||||||
|
* (c) 2014-2026 zlin <admin@kernelstudio.com>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE file
|
||||||
|
* that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
public class HbNodeCommand implements Serializable {
|
||||||
|
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
private String command;
|
||||||
|
|
||||||
|
private String chineseName;
|
||||||
|
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
public Integer getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(Integer id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCommand() {
|
||||||
|
return command;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCommand(String command) {
|
||||||
|
this.command = command;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getChineseName() {
|
||||||
|
return chineseName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setChineseName(String chineseName) {
|
||||||
|
this.chineseName = chineseName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDescription() {
|
||||||
|
return description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDescription(String description) {
|
||||||
|
this.description = description;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -32,6 +32,8 @@ public class Nodeparameter extends BaseEntity
|
|||||||
@Excel(name = "节点实例设置的具体参数值 (覆盖模板默认值)")
|
@Excel(name = "节点实例设置的具体参数值 (覆盖模板默认值)")
|
||||||
private String value;
|
private String value;
|
||||||
|
|
||||||
|
private int groupIndex;
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
@@ -80,6 +82,14 @@ public class Nodeparameter extends BaseEntity
|
|||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getGroupIndex() {
|
||||||
|
return groupIndex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGroupIndex(int groupIndex) {
|
||||||
|
this.groupIndex = groupIndex;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
|||||||
@@ -42,6 +42,8 @@ public class Nodetemplate extends BaseEntity
|
|||||||
@Excel(name = "模版类型,节点模版或者条件判断,例如“node”,precondition“")
|
@Excel(name = "模版类型,节点模版或者条件判断,例如“node”,precondition“")
|
||||||
private String templateType;
|
private String templateType;
|
||||||
|
|
||||||
|
private boolean multiable;
|
||||||
|
|
||||||
public Nodetemplate() {
|
public Nodetemplate() {
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -53,6 +55,7 @@ public class Nodetemplate extends BaseEntity
|
|||||||
this.description = template.description;
|
this.description = template.description;
|
||||||
this.englishName = template.englishName;
|
this.englishName = template.englishName;
|
||||||
this.templateType = template.templateType;
|
this.templateType = template.templateType;
|
||||||
|
this.multiable = template.multiable;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
@@ -125,6 +128,14 @@ public class Nodetemplate extends BaseEntity
|
|||||||
return templateType;
|
return templateType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isMultiable() {
|
||||||
|
return multiable;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMultiable(boolean multiable) {
|
||||||
|
this.multiable = multiable;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
|||||||
@@ -42,6 +42,8 @@ public class Templateparameterdef extends BaseEntity
|
|||||||
@Excel(name = "判断参数模版是节点的参数模版还是条件的参数模版")
|
@Excel(name = "判断参数模版是节点的参数模版还是条件的参数模版")
|
||||||
private String templateType;
|
private String templateType;
|
||||||
|
|
||||||
|
private int groupIndex;
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
@@ -112,6 +114,14 @@ public class Templateparameterdef extends BaseEntity
|
|||||||
return templateType;
|
return templateType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int getGroupIndex() {
|
||||||
|
return groupIndex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGroupIndex(int groupIndex) {
|
||||||
|
this.groupIndex = groupIndex;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.solution.system.mapper;
|
package com.solution.system.mapper;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.solution.system.domain.Behaviortree;
|
import com.solution.system.domain.Behaviortree;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -11,6 +12,9 @@ import com.solution.system.domain.Behaviortree;
|
|||||||
*/
|
*/
|
||||||
public interface BehaviortreeMapper
|
public interface BehaviortreeMapper
|
||||||
{
|
{
|
||||||
|
|
||||||
|
Behaviortree findOneByPlatformId(Integer platformId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询行为树主
|
* 查询行为树主
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.system.mapper;
|
||||||
|
/*
|
||||||
|
* This file is part of the kernelstudio package.
|
||||||
|
*
|
||||||
|
* (c) 2014-2026 zlin <admin@kernelstudio.com>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE file
|
||||||
|
* that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import com.solution.system.domain.HbNodeCommand;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface HbNodeCommandMapper {
|
||||||
|
|
||||||
|
List<HbNodeCommand> findAll();
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.system.service;
|
||||||
|
/*
|
||||||
|
* This file is part of the kernelstudio package.
|
||||||
|
*
|
||||||
|
* (c) 2014-2026 zlin <admin@kernelstudio.com>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE file
|
||||||
|
* that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import com.solution.system.domain.HbNodeCommand;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface HbNodeCommandService {
|
||||||
|
|
||||||
|
List<HbNodeCommand> findAll();
|
||||||
|
}
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.solution.system.service;
|
package com.solution.system.service;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.solution.system.domain.Behaviortree;
|
import com.solution.system.domain.Behaviortree;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -11,6 +12,9 @@ import com.solution.system.domain.Behaviortree;
|
|||||||
*/
|
*/
|
||||||
public interface IBehaviortreeService
|
public interface IBehaviortreeService
|
||||||
{
|
{
|
||||||
|
|
||||||
|
Behaviortree findOneByPlatformId(Integer platformId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询行为树主
|
* 查询行为树主
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -1,6 +1,9 @@
|
|||||||
package com.solution.system.service.impl;
|
package com.solution.system.service.impl;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
|
import com.solution.common.constant.ExceptionConstants;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import com.solution.system.mapper.BehaviortreeMapper;
|
import com.solution.system.mapper.BehaviortreeMapper;
|
||||||
@@ -19,6 +22,12 @@ public class BehaviortreeServiceImpl implements IBehaviortreeService
|
|||||||
@Autowired
|
@Autowired
|
||||||
private BehaviortreeMapper behaviortreeMapper;
|
private BehaviortreeMapper behaviortreeMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Behaviortree findOneByPlatformId(Integer platformId)
|
||||||
|
{
|
||||||
|
return behaviortreeMapper.findOneByPlatformId(platformId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询行为树主
|
* 查询行为树主
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package com.solution.system.service.impl;
|
||||||
|
/*
|
||||||
|
* This file is part of the kernelstudio package.
|
||||||
|
*
|
||||||
|
* (c) 2014-2026 zlin <admin@kernelstudio.com>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE file
|
||||||
|
* that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import com.solution.system.domain.HbNodeCommand;
|
||||||
|
import com.solution.system.mapper.HbNodeCommandMapper;
|
||||||
|
import com.solution.system.service.HbNodeCommandService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class HbNodeCommandServiceImpl implements HbNodeCommandService {
|
||||||
|
|
||||||
|
private final HbNodeCommandMapper hbNodeCommandMapper;
|
||||||
|
|
||||||
|
public HbNodeCommandServiceImpl(HbNodeCommandMapper hbNodeCommandMapper) {
|
||||||
|
this.hbNodeCommandMapper = hbNodeCommandMapper;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<HbNodeCommand> findAll() {
|
||||||
|
return hbNodeCommandMapper.findAll();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -14,6 +14,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<result property="xmlContent" column="xml_content" />
|
<result property="xmlContent" column="xml_content" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="findOneByPlatformId" resultMap="BehaviortreeResult">
|
||||||
|
select * from behaviortree
|
||||||
|
where platform_id=#{platformId}
|
||||||
|
limit 1
|
||||||
|
</select>
|
||||||
|
|
||||||
<sql id="selectBehaviortreeVo">
|
<sql id="selectBehaviortreeVo">
|
||||||
select id, name, description, created_at, updated_at, english_name, xml_content from behaviortree
|
select id, name, description, created_at, updated_at, english_name, xml_content from behaviortree
|
||||||
</sql>
|
</sql>
|
||||||
@@ -44,6 +50,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="updatedAt != null">updated_at,</if>
|
<if test="updatedAt != null">updated_at,</if>
|
||||||
<if test="englishName != null and englishName != ''">english_name,</if>
|
<if test="englishName != null and englishName != ''">english_name,</if>
|
||||||
<if test="xmlContent != null">xml_content,</if>
|
<if test="xmlContent != null">xml_content,</if>
|
||||||
|
<if test="platformId != null">platform_id,</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
<if test="name != null and name != ''">#{name},</if>
|
<if test="name != null and name != ''">#{name},</if>
|
||||||
@@ -52,9 +59,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="updatedAt != null">#{updatedAt},</if>
|
<if test="updatedAt != null">#{updatedAt},</if>
|
||||||
<if test="englishName != null and englishName != ''">#{englishName},</if>
|
<if test="englishName != null and englishName != ''">#{englishName},</if>
|
||||||
<if test="xmlContent != null">#{xmlContent},</if>
|
<if test="xmlContent != null">#{xmlContent},</if>
|
||||||
|
<if test="platformId != null">#{platformId},</if>
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
<insert id="insert" parameterType="com.solution.scene.domain.AfsimScenario">
|
||||||
|
INSERT INTO afsim_scenario (name, description, scenario_path, communication_graph)
|
||||||
|
VALUES (#{name}, #{description}, #{scenarioPath}, #{communicationGraph})
|
||||||
|
</insert>
|
||||||
|
|
||||||
<update id="updateBehaviortree" parameterType="Behaviortree">
|
<update id="updateBehaviortree" parameterType="Behaviortree">
|
||||||
update behaviortree
|
update behaviortree
|
||||||
<trim prefix="SET" suffixOverrides=",">
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
|||||||
@@ -0,0 +1,19 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.solution.system.mapper.HbNodeCommandMapper">
|
||||||
|
|
||||||
|
<resultMap type="com.solution.system.domain.HbNodeCommand" id="HbNodeCommandMapperMap">
|
||||||
|
<result property="id" column="id"/>
|
||||||
|
<result property="command" column="command"/>
|
||||||
|
<result property="description" column="description"/>
|
||||||
|
<result property="chineseName" column="chinese_name"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="findAll" resultMap="HbNodeCommandMapperMap">
|
||||||
|
select *
|
||||||
|
from bh_node_command
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
@@ -10,6 +10,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<result property="nodeInstanceId" column="node_instance_id" />
|
<result property="nodeInstanceId" column="node_instance_id" />
|
||||||
<result property="paramDefId" column="param_def_id" />
|
<result property="paramDefId" column="param_def_id" />
|
||||||
<result property="value" column="value" />
|
<result property="value" column="value" />
|
||||||
|
<result property="groupIndex" column="group_index" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<delete id="deleteByTreeId">
|
<delete id="deleteByTreeId">
|
||||||
@@ -17,7 +18,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
<sql id="selectNodeparameterVo">
|
<sql id="selectNodeparameterVo">
|
||||||
select id, treeId, node_instance_id, param_def_id, value from nodeparameter
|
select id, treeId, node_instance_id, param_def_id,`value`, group_index from nodeparameter
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectNodeparameterList" parameterType="Nodeparameter" resultMap="NodeparameterResult">
|
<select id="selectNodeparameterList" parameterType="Nodeparameter" resultMap="NodeparameterResult">
|
||||||
@@ -41,12 +42,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="nodeInstanceId != null">node_instance_id,</if>
|
<if test="nodeInstanceId != null">node_instance_id,</if>
|
||||||
<if test="paramDefId != null">param_def_id,</if>
|
<if test="paramDefId != null">param_def_id,</if>
|
||||||
<if test="value != null">value,</if>
|
<if test="value != null">value,</if>
|
||||||
|
group_index
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
<if test="treeId != null">#{treeId},</if>
|
<if test="treeId != null">#{treeId},</if>
|
||||||
<if test="nodeInstanceId != null">#{nodeInstanceId},</if>
|
<if test="nodeInstanceId != null">#{nodeInstanceId},</if>
|
||||||
<if test="paramDefId != null">#{paramDefId},</if>
|
<if test="paramDefId != null">#{paramDefId},</if>
|
||||||
<if test="value != null">#{value},</if>
|
<if test="value != null">#{value},</if>
|
||||||
|
#{groupIndex}
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@@ -57,6 +60,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="nodeInstanceId != null">node_instance_id = #{nodeInstanceId},</if>
|
<if test="nodeInstanceId != null">node_instance_id = #{nodeInstanceId},</if>
|
||||||
<if test="paramDefId != null">param_def_id = #{paramDefId},</if>
|
<if test="paramDefId != null">param_def_id = #{paramDefId},</if>
|
||||||
<if test="value != null">value = #{value},</if>
|
<if test="value != null">value = #{value},</if>
|
||||||
|
group_index=#{groupIndex}
|
||||||
</trim>
|
</trim>
|
||||||
where id = #{id}
|
where id = #{id}
|
||||||
</update>
|
</update>
|
||||||
|
|||||||
@@ -12,10 +12,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<result property="description" column="description" />
|
<result property="description" column="description" />
|
||||||
<result property="englishName" column="english_name" />
|
<result property="englishName" column="english_name" />
|
||||||
<result property="templateType" column="templete_type" />
|
<result property="templateType" column="templete_type" />
|
||||||
|
<result property="multiable" column="is_multiable" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectNodetemplateVo">
|
<sql id="selectNodetemplateVo">
|
||||||
select id, type, name, logic_handler, description, english_name, templete_type from nodetemplate
|
select id, type, name, logic_handler, description, english_name, templete_type, is_multiable from nodetemplate
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectNodetemplateList" parameterType="Nodetemplate" resultMap="NodetemplateResult">
|
<select id="selectNodetemplateList" parameterType="Nodetemplate" resultMap="NodetemplateResult">
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
select id, template_id, param_key, data_type, default_value, description, template_type from templateparameterdef
|
select id, template_id, param_key, data_type, default_value, description, template_type from templateparameterdef
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectTemplateparameterdefList" parameterType="Templateparameterdef" resultMap="TemplateparameterdefResult">
|
<select id="selectTemplateparameterdefList" parameterType="templateparameterdef" resultMap="TemplateparameterdefResult">
|
||||||
<include refid="selectTemplateparameterdefVo"/>
|
<include refid="selectTemplateparameterdefVo"/>
|
||||||
<where>
|
<where>
|
||||||
<if test="templateId != null "> and template_id = #{templateId}</if>
|
<if test="templateId != null "> and template_id = #{templateId}</if>
|
||||||
|
|||||||
@@ -113,6 +113,12 @@
|
|||||||
<artifactId>javax.servlet-api</artifactId>
|
<artifactId>javax.servlet-api</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.projectlombok</groupId>
|
||||||
|
<artifactId>lombok</artifactId>
|
||||||
|
<version>1.18.34</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.hutool</groupId>
|
<groupId>cn.hutool</groupId>
|
||||||
<artifactId>hutool-all</artifactId>
|
<artifactId>hutool-all</artifactId>
|
||||||
|
|||||||
@@ -13,4 +13,6 @@ public class ExceptionConstants {
|
|||||||
|
|
||||||
public static final String NOT_FOUND_F22_COMPONENT = "未找到 F-22 组件";
|
public static final String NOT_FOUND_F22_COMPONENT = "未找到 F-22 组件";
|
||||||
|
|
||||||
|
public static final String SCENE_CONFIG_NOT_NULL = "场景配置不能为空";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,4 +6,6 @@ public class PlatformAndModuleConstants {
|
|||||||
public static final String RED_NEBO_M_1 = "red_nebo_m_1";
|
public static final String RED_NEBO_M_1 = "red_nebo_m_1";
|
||||||
|
|
||||||
public static final String RED_NEBO_M_2 = "red_nebo_m_2";
|
public static final String RED_NEBO_M_2 = "red_nebo_m_2";
|
||||||
|
|
||||||
|
public static final String RED_TANK_1 = "red_tank_1";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,18 +16,61 @@
|
|||||||
rule模块
|
rule模块
|
||||||
</description>
|
</description>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<!-- Drools 版本,建议使用稳定版,如 7.74.1.Final 或 8.x 系列 -->
|
||||||
|
<drools.version>7.74.1.Final</drools.version>
|
||||||
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|
||||||
|
<!-- 1. Drools 核心引擎 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.drools</groupId>
|
||||||
|
<artifactId>drools-core</artifactId>
|
||||||
|
<version>${drools.version}</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.drools</groupId>
|
||||||
|
<artifactId>drools-templates</artifactId>
|
||||||
|
<version>${drools.version}</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 2. KIE API(Drools 属于 KIE 项目的一部分,此依赖提供核心 API) -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.kie</groupId>
|
||||||
|
<artifactId>kie-api</artifactId>
|
||||||
|
<version>${drools.version}</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 3. 规则编译器(用于编译 .drl 等规则文件) -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.drools</groupId>
|
||||||
|
<artifactId>drools-compiler</artifactId>
|
||||||
|
<version>${drools.version}</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 4. Spring 整合(如果需要和 Spring/Spring Boot 深度整合) -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.kie</groupId>
|
||||||
|
<artifactId>kie-spring</artifactId>
|
||||||
|
<version>${drools.version}</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 流式解析工具-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.fasterxml.jackson.core</groupId>
|
||||||
|
<artifactId>jackson-databind</artifactId>
|
||||||
|
<version>2.15.2</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
<!-- 通用工具-->
|
<!-- 通用工具-->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.solution</groupId>
|
<groupId>com.solution</groupId>
|
||||||
<artifactId>solution-common</artifactId>
|
<artifactId>solution-common</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.projectlombok</groupId>
|
|
||||||
<artifactId>lombok</artifactId>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>io.springfox</groupId>
|
<groupId>io.springfox</groupId>
|
||||||
|
|||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package com.solution.rule.config;
|
||||||
|
|
||||||
|
import org.kie.api.KieBase;
|
||||||
|
import org.kie.api.KieServices;
|
||||||
|
import org.kie.api.builder.KieBuilder;
|
||||||
|
import org.kie.api.builder.KieFileSystem;
|
||||||
|
import org.kie.api.builder.KieRepository;
|
||||||
|
import org.kie.api.builder.Message;
|
||||||
|
import org.kie.api.runtime.KieContainer;
|
||||||
|
import org.kie.api.runtime.KieSession;
|
||||||
|
import org.kie.internal.io.ResourceFactory;
|
||||||
|
import org.kie.spring.KModuleBeanFactoryPostProcessor;
|
||||||
|
import org.springframework.context.annotation.Bean;
|
||||||
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
import org.springframework.core.io.Resource;
|
||||||
|
import org.springframework.core.io.support.PathMatchingResourcePatternResolver;
|
||||||
|
import org.springframework.core.io.support.ResourcePatternResolver;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
@Configuration
|
||||||
|
public class DroolsConfig {
|
||||||
|
|
||||||
|
private static final String RULE_PATH = "classpath*:rules/**/*.drl";
|
||||||
|
|
||||||
|
private final KieServices kieServices = KieServices.Factory.get();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 加载规则文件
|
||||||
|
*/
|
||||||
|
@Bean
|
||||||
|
public KieFileSystem kieFileSystem() throws IOException {
|
||||||
|
KieFileSystem kieFileSystem = kieServices.newKieFileSystem();
|
||||||
|
|
||||||
|
ResourcePatternResolver resolver = new PathMatchingResourcePatternResolver();
|
||||||
|
Resource[] resources = resolver.getResources(RULE_PATH);
|
||||||
|
|
||||||
|
for (Resource resource : resources) {
|
||||||
|
kieFileSystem.write(
|
||||||
|
ResourceFactory.newInputStreamResource(resource.getInputStream())
|
||||||
|
.setSourcePath("rules/" + resource.getFilename())
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
return kieFileSystem;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 构建 KieContainer
|
||||||
|
*/
|
||||||
|
@Bean
|
||||||
|
public KieContainer kieContainer(KieFileSystem kieFileSystem) {
|
||||||
|
|
||||||
|
KieBuilder kieBuilder = kieServices.newKieBuilder(kieFileSystem);
|
||||||
|
kieBuilder.buildAll();
|
||||||
|
|
||||||
|
// 检查错误
|
||||||
|
if (kieBuilder.getResults().hasMessages(Message.Level.ERROR)) {
|
||||||
|
throw new RuntimeException("Drools规则编译错误:\n" +
|
||||||
|
kieBuilder.getResults().toString());
|
||||||
|
}
|
||||||
|
|
||||||
|
KieRepository repository = kieServices.getRepository();
|
||||||
|
|
||||||
|
return kieServices.newKieContainer(repository.getDefaultReleaseId());
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* KieBase
|
||||||
|
*/
|
||||||
|
@Bean
|
||||||
|
public KieBase kieBase(KieContainer kieContainer) {
|
||||||
|
return kieContainer.getKieBase();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* KieSession(推荐加)
|
||||||
|
*/
|
||||||
|
@Bean
|
||||||
|
public KieSession kieSession(KieContainer kieContainer) {
|
||||||
|
return kieContainer.newKieSession();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 必须是 static
|
||||||
|
*/
|
||||||
|
@Bean
|
||||||
|
public static KModuleBeanFactoryPostProcessor kiePostProcessor() {
|
||||||
|
return new KModuleBeanFactoryPostProcessor();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package com.solution.rule.domain;
|
||||||
|
/*
|
||||||
|
* This file is part of the kernelstudio package.
|
||||||
|
*
|
||||||
|
* (c) 2014-2026 zlin <admin@kernelstudio.com>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE file
|
||||||
|
* that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class BasicPlatform implements Serializable {
|
||||||
|
|
||||||
|
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
public Integer getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(Integer id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDescription() {
|
||||||
|
return description;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDescription(String description) {
|
||||||
|
this.description = description;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package com.solution.rule.domain;
|
||||||
|
/*
|
||||||
|
* This file is part of the kernelstudio package.
|
||||||
|
*
|
||||||
|
* (c) 2014-2026 zlin <admin@kernelstudio.com>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE file
|
||||||
|
* that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class Platform extends BasicPlatform {
|
||||||
|
|
||||||
|
private List<PlatformComponent> components;
|
||||||
|
|
||||||
|
public List<PlatformComponent> getComponents() {
|
||||||
|
return components;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setComponents(List<PlatformComponent> components) {
|
||||||
|
this.components = components;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -4,6 +4,8 @@ import io.swagger.annotations.ApiModel;
|
|||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 平台挂载的组件实体类
|
* 平台挂载的组件实体类
|
||||||
* 对应表 platform_component
|
* 对应表 platform_component
|
||||||
@@ -29,4 +31,7 @@ public class PlatformComponent {
|
|||||||
|
|
||||||
@ApiModelProperty(value = "组件数量")
|
@ApiModelProperty(value = "组件数量")
|
||||||
private Long num;
|
private Long num;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "平台参数(List<String>)")
|
||||||
|
private List<String> platformParams;
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.solution.rule.domain;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@ApiModel("红蓝对抗规则")
|
||||||
|
public class Rule {
|
||||||
|
@ApiModelProperty("规则ID")
|
||||||
|
private Integer id;
|
||||||
|
|
||||||
|
@ApiModelProperty("规则名称")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
@ApiModelProperty("场景类型:0-防御,1-空降,null表示通用")
|
||||||
|
private Integer sceneType;
|
||||||
|
|
||||||
|
@ApiModelProperty("触发条件(JSON格式)")
|
||||||
|
private String conditions;
|
||||||
|
|
||||||
|
@ApiModelProperty("响应动作(JSON格式)")
|
||||||
|
private String actions;
|
||||||
|
|
||||||
|
@ApiModelProperty("优先级(数值越小优先级越高)")
|
||||||
|
private Integer priority;
|
||||||
|
|
||||||
|
@ApiModelProperty("是否启用(0禁用,1启用)")
|
||||||
|
private Boolean enabled;
|
||||||
|
|
||||||
|
@ApiModelProperty("创建时间")
|
||||||
|
private Date createdTime;
|
||||||
|
|
||||||
|
@ApiModelProperty("更新时间")
|
||||||
|
private Date updatedTime;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.rule.domain.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class ComponentJsonDTO {
|
||||||
|
|
||||||
|
//组件类型
|
||||||
|
private String type;
|
||||||
|
//组件名称
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
//组件参数列表
|
||||||
|
private List<PlatformJsonDTO> parameters;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.rule.domain.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class ComponentParamJsonDTO {
|
||||||
|
|
||||||
|
// 参数名称
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
private String def;
|
||||||
|
|
||||||
|
// 参数值
|
||||||
|
private String value;
|
||||||
|
|
||||||
|
// 参数单位
|
||||||
|
private String unit;
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
package com.solution.rule.domain.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class PlatformJsonDTO {
|
||||||
|
// 装备ID
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
// 装备名称
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
// 平台类型 (Platform_type)
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
// 子组件列表(武器、传感器、通信等)
|
||||||
|
private List<ComponentJsonDTO> components;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
package com.solution.rule.domain.dto;
|
|
||||||
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 规则请求参数
|
|
||||||
*/
|
|
||||||
@Data
|
|
||||||
public class RequestDTO {
|
|
||||||
|
|
||||||
//编队数量
|
|
||||||
private Long formationNum;
|
|
||||||
|
|
||||||
//武装直升机数量
|
|
||||||
private Long gunshipNum;
|
|
||||||
|
|
||||||
//无人机数量
|
|
||||||
private Long droneNum;
|
|
||||||
|
|
||||||
//单兵武器数量
|
|
||||||
private Long singleWeaponNum;
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package com.solution.rule.domain.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.sound.midi.Track;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class TaskJsonDTO {
|
||||||
|
|
||||||
|
//任务id
|
||||||
|
private Long attackId;
|
||||||
|
|
||||||
|
//任务名称
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
//任务类型
|
||||||
|
private String dataType;
|
||||||
|
|
||||||
|
//任务下的平台
|
||||||
|
private List<PlatformJsonDTO> platforms;
|
||||||
|
|
||||||
|
//任务轨迹
|
||||||
|
private List<Track> tracks;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.rule.domain.dto;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class TrackJsonDTO {
|
||||||
|
|
||||||
|
// 轨迹ID
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
// 轨迹名称
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
// 轨迹点列表
|
||||||
|
private List<TrackPointJsonDTO> points;
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package com.solution.rule.domain.dto;
|
||||||
|
|
||||||
|
public class TrackPointJsonDTO {
|
||||||
|
|
||||||
|
// 轨迹点索引
|
||||||
|
private int index;
|
||||||
|
|
||||||
|
// 经度
|
||||||
|
private double longitude;
|
||||||
|
|
||||||
|
// 纬度
|
||||||
|
private double latitude;
|
||||||
|
|
||||||
|
// 高度(米)
|
||||||
|
private double height;
|
||||||
|
|
||||||
|
// 速度(米/秒)
|
||||||
|
private double speed;
|
||||||
|
|
||||||
|
// 航向角(度)
|
||||||
|
private double heading;
|
||||||
|
|
||||||
|
// 时间点(秒)
|
||||||
|
private double time;
|
||||||
|
}
|
||||||
@@ -20,4 +20,7 @@ public class WeaponModelDTO {
|
|||||||
|
|
||||||
@ApiModelProperty("平台组件")
|
@ApiModelProperty("平台组件")
|
||||||
private List<PlatformComponent> components;
|
private List<PlatformComponent> components;
|
||||||
|
|
||||||
|
@ApiModelProperty("平台参数(List<String>)")
|
||||||
|
private List<String> platformParams;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,52 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import com.solution.common.utils.sign.Md5Utils;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单个属性的定义
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class Attribute {
|
||||||
|
|
||||||
|
//uuid
|
||||||
|
@JsonProperty("_uuid")
|
||||||
|
private String uuid;
|
||||||
|
/** 属性数据类型(如:float、int、string、bool、enum) */
|
||||||
|
private String attDataType;
|
||||||
|
/** 属性定义(英文标识) */
|
||||||
|
private String attDef;
|
||||||
|
/** 属性默认值 */
|
||||||
|
private String attDefaultValue;
|
||||||
|
/** 属性详细信息 */
|
||||||
|
private Object attDetail;
|
||||||
|
/** 属性说明(中文描述) */
|
||||||
|
private String attExplain;
|
||||||
|
/** 属性ID */
|
||||||
|
private String attId;
|
||||||
|
/** 属性名称(中文) */
|
||||||
|
private String attName;
|
||||||
|
/** 属性取值范围(格式:最小值|最大值) */
|
||||||
|
private String attRange;
|
||||||
|
/** 属性单位 */
|
||||||
|
private String attUnit;
|
||||||
|
/** 是否为内置属性 */
|
||||||
|
private boolean builtIn;
|
||||||
|
/** 枚举信息 */
|
||||||
|
private String enumInfo;
|
||||||
|
/** 是否为关键属性 */
|
||||||
|
private boolean isKey;
|
||||||
|
/** 是否为公共属性 */
|
||||||
|
private boolean isPublic;
|
||||||
|
/** 是否可搜索 */
|
||||||
|
private boolean isSearch;
|
||||||
|
/** 是否为文本域 */
|
||||||
|
private boolean isTextarea;
|
||||||
|
/** 模型信息(可以是对象或数组,此处定义为具体对象) */
|
||||||
|
private List<ModelInfo> mdlInfo;
|
||||||
|
/** 是否只读(0-可编辑,1-只读) */
|
||||||
|
private int readOnly;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 字典项实体
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class DictItem {
|
||||||
|
/** 编码 */
|
||||||
|
private String code;
|
||||||
|
/** 说明 */
|
||||||
|
private String explain;
|
||||||
|
/** 名称 */
|
||||||
|
private String name;
|
||||||
|
/** 唯一标识符 */
|
||||||
|
private String uuid;
|
||||||
|
}
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class Equipments {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class Force {
|
||||||
|
|
||||||
|
//对象句柄
|
||||||
|
private String ObjectHandle;
|
||||||
|
|
||||||
|
//类型
|
||||||
|
private Integer type;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 阵营实体
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class ForceSides {
|
||||||
|
|
||||||
|
//分组类型
|
||||||
|
private String groupType;
|
||||||
|
|
||||||
|
private List<Force> postures;
|
||||||
|
|
||||||
|
//对象句柄
|
||||||
|
private String ObjectHandle;
|
||||||
|
|
||||||
|
//阵营名称
|
||||||
|
private String ForceSideName;
|
||||||
|
|
||||||
|
//作战目标
|
||||||
|
private String warGoal;
|
||||||
|
}
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 模型信息实体
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class ModelInfo {
|
||||||
|
/** 模型ID */
|
||||||
|
@JsonProperty("_id")
|
||||||
|
private String id;
|
||||||
|
/** 类别 */
|
||||||
|
private String category;
|
||||||
|
/** 分类ID */
|
||||||
|
private String classifyId;
|
||||||
|
/** 分类名称 */
|
||||||
|
private String classifyName;
|
||||||
|
/** 创建时间(时间戳) */
|
||||||
|
private long createTime;
|
||||||
|
/** 字典项列表 */
|
||||||
|
private List<DictItem> dict;
|
||||||
|
/** 模型系统ID */
|
||||||
|
private int mxSysId;
|
||||||
|
/** 名称 */
|
||||||
|
private String name;
|
||||||
|
/** 角色ID */
|
||||||
|
private int roleId;
|
||||||
|
/** 空间ID */
|
||||||
|
private int spaceId;
|
||||||
|
/** 更新时间(时间戳) */
|
||||||
|
private long updateTime;
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 引用属性对象
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class RefAttributeObject {
|
||||||
|
|
||||||
|
//属性列表
|
||||||
|
private Map<String, List<Attribute>> attributes;
|
||||||
|
|
||||||
|
private TrackParam trackParam;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 接收智唐接口实体
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class RequestDTO {
|
||||||
|
|
||||||
|
//引用属性对象(设备属性定义)
|
||||||
|
private RefAttributeObject refAttributeObject;
|
||||||
|
|
||||||
|
//阵营列表
|
||||||
|
private List<ForceSides> forceSides;
|
||||||
|
|
||||||
|
//装备列表
|
||||||
|
private List<Equipments> equipments;
|
||||||
|
|
||||||
|
//private List<Tasks> tasks;
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class Track {
|
||||||
|
//航迹名称
|
||||||
|
private String name;
|
||||||
|
//航迹开始时间
|
||||||
|
private int StartTime;
|
||||||
|
//航迹结束时间
|
||||||
|
private int EndTime;
|
||||||
|
//航迹类型
|
||||||
|
private String TrackType;
|
||||||
|
//航迹高度类型
|
||||||
|
private String HeightType;
|
||||||
|
//航迹海面类型
|
||||||
|
private String seaType;
|
||||||
|
//航迹点集合
|
||||||
|
private List<TrackPoint> TrackPoints;
|
||||||
|
//航迹所属阵营
|
||||||
|
private String Color;
|
||||||
|
//航迹总点数
|
||||||
|
private int PointCount;
|
||||||
|
}
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import javax.sound.midi.Track;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 航迹参数
|
||||||
|
*/
|
||||||
|
public class TrackParam {
|
||||||
|
|
||||||
|
private Map<String, List<Track>> tracks;
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.solution.rule.domain.request;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 航迹节点实体
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class TrackPoint {
|
||||||
|
//航迹索引
|
||||||
|
private String index;
|
||||||
|
//经度
|
||||||
|
private String longitude;
|
||||||
|
//纬度
|
||||||
|
private String latitude;
|
||||||
|
//高度
|
||||||
|
private String height;
|
||||||
|
//航速
|
||||||
|
private String speed;
|
||||||
|
//航向角
|
||||||
|
private String psia;
|
||||||
|
//时间
|
||||||
|
private String time;
|
||||||
|
//活动
|
||||||
|
private String active;
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class ComponentParam {
|
||||||
|
|
||||||
|
//唯一标识符
|
||||||
|
private String uuid;
|
||||||
|
|
||||||
|
//组件默认参数
|
||||||
|
private String attDefaultValue;
|
||||||
|
|
||||||
|
//参数单位
|
||||||
|
private String attExplain;
|
||||||
|
|
||||||
|
//组件数量
|
||||||
|
private Integer number;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class Coordinate {
|
||||||
|
|
||||||
|
//经度
|
||||||
|
private BigDecimal longitude;
|
||||||
|
|
||||||
|
//纬度
|
||||||
|
private BigDecimal latitude;
|
||||||
|
|
||||||
|
//高度
|
||||||
|
private Integer height;
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class SubComponents {
|
||||||
|
|
||||||
|
//设备id
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
//设备名称
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
//设备组件参数
|
||||||
|
private List<ComponentParam> componentParams;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 简单任务实体
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class Task {
|
||||||
|
|
||||||
|
//任务id
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
//任务名称
|
||||||
|
private String drawName;
|
||||||
|
|
||||||
|
//任务类型
|
||||||
|
private String dataType;
|
||||||
|
|
||||||
|
//任务所属阵营
|
||||||
|
private String side;
|
||||||
|
|
||||||
|
//任务威胁等级(1-3)
|
||||||
|
private String threatLevel;
|
||||||
|
|
||||||
|
//任务航迹
|
||||||
|
private List<TrackPoints> trackPoints;
|
||||||
|
|
||||||
|
//任务武器
|
||||||
|
private List<Weapon> taskWeapons;
|
||||||
|
|
||||||
|
//任务目标id
|
||||||
|
private String targetId;
|
||||||
|
|
||||||
|
//作战区经纬高
|
||||||
|
private List<Coordinate> warZoneLocation;
|
||||||
|
|
||||||
|
//防区经纬高
|
||||||
|
private List<Coordinate> defZoneLocation;
|
||||||
|
|
||||||
|
//阵型类型:TRIANGLE/DIAMOND/LINE/COLUMN/WEDGE
|
||||||
|
private String formationType;
|
||||||
|
|
||||||
|
//阵型基础间距(米)
|
||||||
|
private Integer formationSpacingMeters;
|
||||||
|
|
||||||
|
//主僚标准距离(米)
|
||||||
|
private Integer mainWingDistanceMeters;
|
||||||
|
|
||||||
|
//阵型朝向(0~359)
|
||||||
|
private Integer formationHeadingDeg;
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class TrackPoints extends Coordinate{
|
||||||
|
|
||||||
|
// 轨迹索引
|
||||||
|
private Integer index;
|
||||||
|
|
||||||
|
// // 轨迹点经度
|
||||||
|
// private BigDecimal longitude;
|
||||||
|
//
|
||||||
|
// // 轨迹点纬度
|
||||||
|
// private BigDecimal latitude;
|
||||||
|
//
|
||||||
|
// // 轨迹点高度
|
||||||
|
// private Integer height;
|
||||||
|
|
||||||
|
//速度
|
||||||
|
private Integer speed;
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class Weapon {
|
||||||
|
|
||||||
|
//装备id
|
||||||
|
private String equipmentId;
|
||||||
|
|
||||||
|
//装备名称
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
//装备类型
|
||||||
|
private String supportType;
|
||||||
|
|
||||||
|
//装备组件
|
||||||
|
private List<SubComponents> components;
|
||||||
|
|
||||||
|
//装备部署位置(经纬高)
|
||||||
|
private Coordinate coordinate;
|
||||||
|
|
||||||
|
//武器数量
|
||||||
|
private Integer number;
|
||||||
|
|
||||||
|
//武器命中率
|
||||||
|
private Double hitRate;
|
||||||
|
|
||||||
|
//目标id
|
||||||
|
private String targetId;
|
||||||
|
|
||||||
|
//编队角色:MAIN=主机,WING=僚机
|
||||||
|
private String formationRole;
|
||||||
|
|
||||||
|
//僚机相对主机距离(米)
|
||||||
|
private Integer wingRelativeDistanceMeters;
|
||||||
|
|
||||||
|
//僚机相对主机方位角(度)
|
||||||
|
private Integer wingRelativeBearingDeg;
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
package com.solution.rule.domain.simplerulepojo.fact;
|
||||||
|
|
||||||
|
import com.solution.rule.domain.simplerulepojo.Task;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class FactTask {
|
||||||
|
|
||||||
|
private Task blueTask;
|
||||||
|
|
||||||
|
private Task redTask;
|
||||||
|
}
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备组件参数项
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleComponentParamDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 参数唯一标识
|
||||||
|
*/
|
||||||
|
private String uuid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 属性默认值
|
||||||
|
*/
|
||||||
|
private String attDefaultValue;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 属性说明
|
||||||
|
*/
|
||||||
|
private String attExplain;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 数量
|
||||||
|
*/
|
||||||
|
private Integer number;
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经纬高坐标点
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleCoordinateDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
private Double longitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
private Double latitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 高程(米)
|
||||||
|
*/
|
||||||
|
private Double height;
|
||||||
|
}
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputArithmeticRefDTO {
|
||||||
|
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 火力规则输入根文档,与 {@code 火力规则输入-无注释.json} 顶层字段对应。
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 来源场景文件名
|
||||||
|
*/
|
||||||
|
private String sourceFile;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 蓝方任务列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleTaskInputDTO> tasks;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方侧异构条目列表(武器、场景任务节点、装备、指挥所、防区等)
|
||||||
|
*/
|
||||||
|
private List<FireRuleInputRedWeaponElementDTO> redWeapons;
|
||||||
|
}
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputDeviceRefDTO {
|
||||||
|
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
private String refId;
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputLauncherConfigurationDTO {
|
||||||
|
|
||||||
|
private String classifyName;
|
||||||
|
|
||||||
|
private Integer isMount;
|
||||||
|
|
||||||
|
private FireRuleInputMountedWeaponRefDTO mountedWeapon;
|
||||||
|
|
||||||
|
private Integer number;
|
||||||
|
}
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputMountedWeaponRefDTO {
|
||||||
|
|
||||||
|
@JsonProperty("_id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 防区圆形条目中 isWing 为对象时的样式字段
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedCircleStyleDTO {
|
||||||
|
|
||||||
|
private String outlineWidth;
|
||||||
|
|
||||||
|
private String lineType;
|
||||||
|
|
||||||
|
private String outlineColor;
|
||||||
|
|
||||||
|
private String color;
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedCommSlotDTO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleInputArithmeticRefDTO arithmetic;
|
||||||
|
|
||||||
|
private FireRuleInputDeviceRefDTO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private Boolean employLabel;
|
||||||
|
|
||||||
|
private String facilityName;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
}
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* redWeapons 条目中 isLead:可能是长机编队参数,也可能是圆形防区参数(字段并集)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedLeadPayloadDTO {
|
||||||
|
|
||||||
|
private String leader;
|
||||||
|
|
||||||
|
private String side;
|
||||||
|
|
||||||
|
private String supportType;
|
||||||
|
|
||||||
|
private List<FireRuleInputRedLeadPositionDTO> positions;
|
||||||
|
|
||||||
|
private String drawName;
|
||||||
|
|
||||||
|
private String airspaceType;
|
||||||
|
|
||||||
|
private String selectLonLat;
|
||||||
|
|
||||||
|
private String radius;
|
||||||
|
|
||||||
|
private String height;
|
||||||
|
|
||||||
|
private String extrudedHeight;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 长机/圆形等结构中的坐标点(示例中可能为数值或占位字符串)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedLeadPositionDTO {
|
||||||
|
|
||||||
|
private String longitude;
|
||||||
|
|
||||||
|
private String latitude;
|
||||||
|
|
||||||
|
private String height;
|
||||||
|
}
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedMotorizedSlotDTO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleInputArithmeticRefDTO arithmetic;
|
||||||
|
|
||||||
|
private FireRuleInputDeviceRefDTO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedPlatformSlotDTO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleInputArithmeticRefDTO arithmetic;
|
||||||
|
|
||||||
|
private FireRuleInputDeviceRefDTO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private Boolean employLabel;
|
||||||
|
|
||||||
|
private String facilityName;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
|
||||||
|
@JsonProperty("TrackParamId")
|
||||||
|
private String trackParamId;
|
||||||
|
|
||||||
|
private List<Double> positions;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedSubComponentsDTO {
|
||||||
|
|
||||||
|
private List<FireRuleInputRedCommSlotDTO> communication;
|
||||||
|
|
||||||
|
@JsonProperty("motorized_assembly")
|
||||||
|
private List<FireRuleInputRedMotorizedSlotDTO> motorizedAssembly;
|
||||||
|
|
||||||
|
private List<FireRuleInputRedPlatformSlotDTO> platform;
|
||||||
|
|
||||||
|
private List<FireRuleInputRedWeaponSlotDTO> weapon;
|
||||||
|
}
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 输入 JSON 中 {@code redWeapons} 数组元素并集:武器摘要、红方装备、营指挥所、防区圆形等形态共用此类。
|
||||||
|
* <p>
|
||||||
|
* {@code isWing} 在 JSON 中可能为僚机数组或圆形样式对象,故使用 {@link Object} 承接;可结合
|
||||||
|
* {@link FireRuleInputRedWingItemDTO}、{@link FireRuleInputRedCircleStyleDTO} 在业务层转型。
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedWeaponElementDTO {
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
@JsonProperty("Name")
|
||||||
|
private String displayName;
|
||||||
|
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@JsonProperty("EquipmentID")
|
||||||
|
private String equipmentId;
|
||||||
|
|
||||||
|
private List<FireRuleWeaponComponentDTO> components;
|
||||||
|
|
||||||
|
private Object number;
|
||||||
|
|
||||||
|
private String successTargetRad;
|
||||||
|
|
||||||
|
private FireRuleInputRedLeadPayloadDTO isLead;
|
||||||
|
|
||||||
|
private Object isWing;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备类条目中为 {@code equipment} 等
|
||||||
|
*/
|
||||||
|
private String groupType;
|
||||||
|
|
||||||
|
@JsonProperty("SupportType")
|
||||||
|
private String supportType;
|
||||||
|
|
||||||
|
@JsonProperty("TroopsDetail")
|
||||||
|
private Map<String, Object> troopsDetail;
|
||||||
|
|
||||||
|
@JsonProperty("Platform_type")
|
||||||
|
private String platformType;
|
||||||
|
|
||||||
|
private Boolean isStrikeTarget;
|
||||||
|
|
||||||
|
private Boolean isReconTarget;
|
||||||
|
|
||||||
|
private Boolean isInterferenceTarget;
|
||||||
|
|
||||||
|
private Boolean isDefendImportantPlace;
|
||||||
|
|
||||||
|
@JsonProperty("OwnerForceSide")
|
||||||
|
private String ownerForceSide;
|
||||||
|
|
||||||
|
@JsonProperty("PlatID")
|
||||||
|
private String platId;
|
||||||
|
|
||||||
|
@JsonProperty("SubComponents")
|
||||||
|
private FireRuleInputRedSubComponentsDTO subComponents;
|
||||||
|
}
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedWeaponSlotDTO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleInputArithmeticRefDTO arithmetic;
|
||||||
|
|
||||||
|
private String codedQueue;
|
||||||
|
|
||||||
|
private FireRuleInputLauncherConfigurationDTO configuration;
|
||||||
|
|
||||||
|
private FireRuleInputDeviceRefDTO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private Boolean employLabel;
|
||||||
|
|
||||||
|
private String facilityName;
|
||||||
|
|
||||||
|
private String serialNumber;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleInputRedWingItemDTO {
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
private String distance;
|
||||||
|
|
||||||
|
private String angle;
|
||||||
|
|
||||||
|
private String alt;
|
||||||
|
}
|
||||||
@@ -0,0 +1,59 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单条火力规则任务输入(蓝方多任务时为列表中的一项)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleTaskInputDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务唯一标识
|
||||||
|
*/
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务名称
|
||||||
|
*/
|
||||||
|
private String drawName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务类型
|
||||||
|
*/
|
||||||
|
private String dataType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务所属阵营
|
||||||
|
*/
|
||||||
|
private String side;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 航迹所属实体或阵营标识
|
||||||
|
*/
|
||||||
|
private String trackPointsId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务航迹点列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleTrackPointDTO> trackPoints;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务武器配置列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleTaskWeaponDTO> taskWeapons;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务目标 id
|
||||||
|
*/
|
||||||
|
private String targetId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 作战区经纬高坐标列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleCoordinateDTO> warZoneLocation;
|
||||||
|
}
|
||||||
@@ -0,0 +1,50 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务挂载的武器配置
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleTaskWeaponDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备 id(武器唯一标识)
|
||||||
|
*/
|
||||||
|
private String equipmentId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备名称
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备类型
|
||||||
|
*/
|
||||||
|
private String supportType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备组件列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleWeaponComponentDTO> components;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备部署位置
|
||||||
|
*/
|
||||||
|
private FireRuleCoordinateDTO coordinate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 武器数量;对应 JSON 键 {@code number}。{@code _comment_number} 为注释键,不映射。
|
||||||
|
* 可为数值或业务文案(如「最大载弹量」)。
|
||||||
|
*/
|
||||||
|
private Object number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 该武器打击目标 id
|
||||||
|
*/
|
||||||
|
private String targetId;
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务航迹点
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleTrackPointDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 航迹点序号
|
||||||
|
*/
|
||||||
|
private Integer index;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
private Double longitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
private Double latitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 高度
|
||||||
|
*/
|
||||||
|
private Double height;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 速度
|
||||||
|
*/
|
||||||
|
private Double speed;
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务武器下的设备组件
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleWeaponComponentDTO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设备 id
|
||||||
|
*/
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设备名称
|
||||||
|
*/
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 组件参数列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleComponentParamDTO> componentParams;
|
||||||
|
}
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
/**
|
||||||
|
* 火力规则输入侧 DTO,与 {@code resources/json/火力规则输入-无注释.json} 对齐。
|
||||||
|
* <p>
|
||||||
|
* {@code redWeapons} 数组元素为并集类型 {@link com.solution.rule.domain.ultimately.dto.FireRuleInputRedWeaponElementDTO},
|
||||||
|
* 常见形态包括:武器摘要、红方装备(含子组件)、营指挥所、防区圆形等。
|
||||||
|
*/
|
||||||
|
package com.solution.rule.domain.ultimately.dto;
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 算法引用(id / 名称)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleArithmeticRefVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 算法 id
|
||||||
|
*/
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 算法名称
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
}
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装备组件参数项
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleComponentParamVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 参数唯一标识
|
||||||
|
*/
|
||||||
|
private String uuid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 属性默认值
|
||||||
|
*/
|
||||||
|
private String attDefaultValue;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 属性说明
|
||||||
|
*/
|
||||||
|
private String attExplain;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 数量或序号
|
||||||
|
*/
|
||||||
|
private Integer number;
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经纬高坐标点
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleCoordinateVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
private Double longitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
private Double latitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 高程(米)
|
||||||
|
*/
|
||||||
|
private Double height;
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 巡航航线偏移量项(上下 / 前后 / 左右 三选一与取值)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleCruiseRouteOffsetItemVO {
|
||||||
|
|
||||||
|
@JsonProperty("UpOrDown")
|
||||||
|
private Boolean upOrDown;
|
||||||
|
|
||||||
|
@JsonProperty("BeforeOrAfter")
|
||||||
|
private Boolean beforeOrAfter;
|
||||||
|
|
||||||
|
@JsonProperty("LeftOrRight")
|
||||||
|
private Boolean leftOrRight;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 偏移数值
|
||||||
|
*/
|
||||||
|
private Number value;
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设备引用
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleDeviceRefVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设备 id
|
||||||
|
*/
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设备名称
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 引用 id
|
||||||
|
*/
|
||||||
|
private String refId;
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务载荷中的单次执行块(含目标列表与类型)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleExecuteBlockVO {
|
||||||
|
|
||||||
|
private List<FireRuleExecuteTargetItemVO> targetList;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 执行类型,如 assault
|
||||||
|
*/
|
||||||
|
private String type;
|
||||||
|
}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 打击执行块中单个目标条目
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleExecuteTargetItemVO {
|
||||||
|
|
||||||
|
@JsonProperty("ID")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 阵列位置 id
|
||||||
|
*/
|
||||||
|
private Integer arrayPositionId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 阵列位置 id 备份
|
||||||
|
*/
|
||||||
|
private String arrayPositionIdBak;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 到达时间配置
|
||||||
|
*/
|
||||||
|
@JsonProperty("at_time")
|
||||||
|
private FireRuleTargetAttTimeVO atTime;
|
||||||
|
|
||||||
|
@JsonProperty("times_interval")
|
||||||
|
private Integer timesInterval;
|
||||||
|
|
||||||
|
private String attackType;
|
||||||
|
|
||||||
|
private String boost;
|
||||||
|
|
||||||
|
private String bootTime;
|
||||||
|
|
||||||
|
private String companion;
|
||||||
|
|
||||||
|
private String cruiseRouteId;
|
||||||
|
|
||||||
|
private List<FireRuleCruiseRouteOffsetItemVO> cruiseRouteOffset;
|
||||||
|
|
||||||
|
private String fireType;
|
||||||
|
|
||||||
|
private List<Object> strategy;
|
||||||
|
|
||||||
|
private String targetId;
|
||||||
|
|
||||||
|
private String weaponId;
|
||||||
|
|
||||||
|
private String weaponRelease;
|
||||||
|
|
||||||
|
private String weaponType;
|
||||||
|
|
||||||
|
private Integer weaponUseCount;
|
||||||
|
}
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发射架配置块
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleLauncherConfigurationVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分类名称
|
||||||
|
*/
|
||||||
|
private String classifyName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否挂载
|
||||||
|
*/
|
||||||
|
private Integer isMount;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 已挂载武器
|
||||||
|
*/
|
||||||
|
private FireRuleMountedWeaponRefVO mountedWeapon;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 数量
|
||||||
|
*/
|
||||||
|
private Integer number;
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 任务载荷中的挂载/任务清单项
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleMissionListItemVO {
|
||||||
|
|
||||||
|
private String label;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发射器类型,如 sam
|
||||||
|
*/
|
||||||
|
private String launcherType;
|
||||||
|
|
||||||
|
private Integer number;
|
||||||
|
|
||||||
|
private String value;
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 挂载武器简要信息
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleMountedWeaponRefVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 武器文档 id
|
||||||
|
*/
|
||||||
|
@JsonProperty("_id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 武器名称
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 火力规则输出根文档(与 {@code 火力规则输出.json} 字段一一对应)。
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleOutputVO {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 来源场景文件名
|
||||||
|
*/
|
||||||
|
private String sourceFile;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 火力规则任务列表(可含防区等输出字段)
|
||||||
|
*/
|
||||||
|
private List<FireRuleTaskInputVO> fireRuleInputs;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 场景任务节点列表
|
||||||
|
*/
|
||||||
|
@JsonProperty("Tasks")
|
||||||
|
private List<FireRuleSceneTaskNodeVO> tasks;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编组列表
|
||||||
|
*/
|
||||||
|
@JsonProperty("Groups")
|
||||||
|
private List<FireRuleSceneGroupNodeVO> groups;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方装备列表
|
||||||
|
*/
|
||||||
|
private List<FireRuleRedWeaponEquipmentVO> redWeapons;
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方装备子组件:通信类数组元素
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleRedCommunicationSlotVO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleArithmeticRefVO arithmetic;
|
||||||
|
|
||||||
|
private FireRuleDeviceRefVO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private Boolean employLabel;
|
||||||
|
|
||||||
|
private String facilityName;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方装备子组件:机动组件数组元素
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleRedMotorizedSlotVO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleArithmeticRefVO arithmetic;
|
||||||
|
|
||||||
|
private FireRuleDeviceRefVO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
}
|
||||||
@@ -0,0 +1,45 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方装备子组件:平台数组元素
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleRedPlatformSlotVO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleArithmeticRefVO arithmetic;
|
||||||
|
|
||||||
|
private FireRuleDeviceRefVO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private Boolean employLabel;
|
||||||
|
|
||||||
|
private String facilityName;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
|
||||||
|
@JsonProperty("TrackParamId")
|
||||||
|
private String trackParamId;
|
||||||
|
|
||||||
|
private List<Double> positions;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方装备子组件分组(按 communication / motorized_assembly / platform / weapon)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleRedSubComponentsVO {
|
||||||
|
|
||||||
|
private List<FireRuleRedCommunicationSlotVO> communication;
|
||||||
|
|
||||||
|
@JsonProperty("motorized_assembly")
|
||||||
|
private List<FireRuleRedMotorizedSlotVO> motorizedAssembly;
|
||||||
|
|
||||||
|
private List<FireRuleRedPlatformSlotVO> platform;
|
||||||
|
|
||||||
|
private List<FireRuleRedWeaponSlotVO> weapon;
|
||||||
|
}
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 火力规则输出中 redWeapons 数组的单项(红方装备/平台)
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleRedWeaponEquipmentVO {
|
||||||
|
|
||||||
|
@JsonProperty("SupportType")
|
||||||
|
private String supportType;
|
||||||
|
|
||||||
|
@JsonProperty("TroopsDetail")
|
||||||
|
private Map<String, Object> troopsDetail;
|
||||||
|
|
||||||
|
@JsonProperty("Platform_type")
|
||||||
|
private String platformType;
|
||||||
|
|
||||||
|
private Boolean isStrikeTarget;
|
||||||
|
|
||||||
|
private Boolean isReconTarget;
|
||||||
|
|
||||||
|
private Boolean isInterferenceTarget;
|
||||||
|
|
||||||
|
private Boolean isDefendImportantPlace;
|
||||||
|
|
||||||
|
private String groupType;
|
||||||
|
|
||||||
|
@JsonProperty("EquipmentID")
|
||||||
|
private String equipmentId;
|
||||||
|
|
||||||
|
@JsonProperty("Name")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
@JsonProperty("OwnerForceSide")
|
||||||
|
private String ownerForceSide;
|
||||||
|
|
||||||
|
@JsonProperty("PlatID")
|
||||||
|
private String platId;
|
||||||
|
|
||||||
|
@JsonProperty("SubComponents")
|
||||||
|
private FireRuleRedSubComponentsVO subComponents;
|
||||||
|
}
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
package com.solution.rule.domain.ultimately.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 红方装备子组件:武器 / 发射架子项
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
public class FireRuleRedWeaponSlotVO {
|
||||||
|
|
||||||
|
@JsonProperty("ObjectHandle")
|
||||||
|
private String objectHandle;
|
||||||
|
|
||||||
|
private FireRuleArithmeticRefVO arithmetic;
|
||||||
|
|
||||||
|
private String codedQueue;
|
||||||
|
|
||||||
|
private FireRuleLauncherConfigurationVO configuration;
|
||||||
|
|
||||||
|
private FireRuleDeviceRefVO device;
|
||||||
|
|
||||||
|
private String deviceId;
|
||||||
|
|
||||||
|
private String deviceName;
|
||||||
|
|
||||||
|
private Boolean employLabel;
|
||||||
|
|
||||||
|
private String facilityName;
|
||||||
|
|
||||||
|
private String serialNumber;
|
||||||
|
|
||||||
|
private String soleId;
|
||||||
|
|
||||||
|
private Map<String, Object> twiceModified;
|
||||||
|
|
||||||
|
private List<Object> zLists;
|
||||||
|
|
||||||
|
@JsonProperty("ParentPlat")
|
||||||
|
private String parentPlat;
|
||||||
|
}
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user