public class AttributeRuleInfo
extends com.supermap.data.InternalHandle
记录管理属性规则信息。
构造器和说明 |
---|
AttributeRuleInfo()
构造属性规则信息对象。
|
限定符和类型 | 方法和说明 |
---|---|
LinkedHashMap<String,Object> |
getCheckParameters()
获取规则参数的接口。
|
Date |
getCreateTime()
获取规则创建时间
|
String |
getDescription()
获取规则描述
|
String |
getErrorMessage()
获取字段名
|
long |
getErrorNumber()
获取当前规则错误码
|
int |
getEvaluationOrder()
获取当前规则的执行顺序
|
String |
getExpression()
获取规则的代码片段或者sql语句
|
String |
getFieldName()
获取字段名
|
boolean |
getIsEnabled()
获取当前规则是否启用
|
String |
getName()
获取规则名字
|
String |
getRulerType()
获取规则器类型
|
int |
getSeverity()
获取当前规则严重等级
|
long |
getSutype()
获取规则适用的子类编码
|
ArrayList<TriggeringEventType> |
getTriggeringEvents()
获取当前规则支持的事件类型
|
AttributeRuleType |
getType()
获取规则类型
返回当前规则是计算类型、约束类型或者验证类型
|
String |
getVersion()
获取规则当前规则的组件版本
|
void |
setCheckParameters(LinkedHashMap<String,Object> hashMap)
设置规则参数的接口。
|
void |
setDescription(String desc)
设置规则描述
|
void |
setErrorMessage(String errorMessage)
设置当前规则的错误描述信息
|
void |
setErrorNumber(long errorNumber)
设置当前规则的错误码
|
void |
setEvaluationOrder(int order)
设置当前规则的执行顺序
|
void |
setExpression(String expression)
设置规则代码片段
|
void |
setFieldName(String fieldName)
设置字段名称
|
void |
setIsEnabled(boolean isEnabled)
设置当前规则是否启用
|
void |
setName(String name)
设置规则名字
|
void |
setRulerType(String ruleEngineType)
设置当前规则的执行器类型
|
void |
setSeverity(int severity)
设置当前规则的严重程度
|
void |
setSutype(long subtypeCode)
这只规则适用的子类
|
void |
setTriggeringEvents(TriggeringEventType... triggeringEventTypes)
设置当前规则的触发事件类型
|
void |
setType(AttributeRuleType attributeRuleType)
设置规则类型
|
public LinkedHashMap<String,Object> getCheckParameters()
public void setCheckParameters(LinkedHashMap<String,Object> hashMap)
hashMap
- 配置具体支持底层的函数以及函数参数。
值域检测:
检测字段值是否在值域范围内,或者是否在子类指定的值域内
例:{"CheckParameters":{"Function":"CheckDomain","FieldName":"BuildType","DomainName":"建筑类型","Filter":""}}
属性查询:
任何属性过滤条件,包括多表的,采用子查询构造条件
例:{"CheckParameters":{"Function":"QueryAttributes","QueryExpression":"smid > 1"}}
字段唯一值:
检测字段是否有重复的值
例:{"CheckParameters":{"Function":"CheckUniqueFieldValue","CompareFields":""a,b","Filter":""}}
子对象个数:
检测子对象个数
参数Evaluationgoal 有如下格式(其中a,b表示子对象个数)
is equal to a
is not equal to a
is less than a
is less than or equal to a
is greater than a
is greater than or equal to a
is between (a,b)
is between [a,b]
is not between (a,b)
is not between [a,b]
例:{"CheckParameters":{"Function":"CheckPartCount","Evaluationgoal":"is less than 2","Filter":""}}
空对象检查:
检测是否有空对象存在
例:{"CheckParameters":{"Function":"CheckGeometry","Filter":""}}
面周长面积检测:
检测面对象的面积和周长,如果是面积,可以检测整个对象以及子对象的面积,如果
是周长,可以检测整个对象,子对象以及每个线段的长度。单位统一:米
面积或周长参数采用如下格式(其中a,b表示子面积值或周长值)
is equal to a
is not equal to a
is less than a
is less than or equal to a
is greater than a
is greater than or equal to a
is between (a,b)
is between [a,b]
is not between (a,b)
is not between [a,b]
参数PolygonEvaluationGeometry的值为polygon,parts,segments中的一项
例:{"CheckParameters":{"Function":"CheckPolygonPerimeterAndArea ","Area":"is less than 2.0","PolylineEvaluationGeometry":"polygon","Filter":""}}
{"CheckParameters":{"Function":"CheckPolygonPerimeterAndArea","Perimeter":"is less than 2.0","PolygonEvaluationGeometry":"segments","Filter":""}}
线长度检测:
可以分别针对整个线对象,子对象或者每一线段做检测
参数PolylineEvaluationGeometry的值为polyline,parts,segments中的一项
例:{"CheckParameters":{"Function":"CheckPolylineLength","Length":"is less than 2.0","PolylineEvaluationGeometry":"segments","Filter":""}}
面内无重叠:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":0,"Tolerance":0.0001,"Filter":""}}
面内无缝隙:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":1,"Tolerance":0.0001,"Filter":""}}
面内无锐角:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":37,"Angle":5,"Filter":""}}
线内无打折:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":34,"Angle":5,"Filter":""}}
无复杂对象:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":23,"Filter":""}}
面与面无重叠:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":2,"CompareDatasetName":"Builds" ,"Tolerance":0.0001,"Filter":""}}
线或面边界无冗余节点:{"CheckParameters":{"Function":"CheckTopo","TopologyRule":33,"Tolerance":20,"Filter":""}}
public void setName(String name)
name
- 当前规则的名字,此数据集内唯一public String getName()
public void setType(AttributeRuleType attributeRuleType)
attributeRuleType
- 标明当前规则是计算类型、约束类型或者验证类型public AttributeRuleType getType()
public void setDescription(String desc)
desc
- 描述信息public String getDescription()
public long getSutype()
public void setSutype(long subtypeCode)
subtypeCode
- 当前数据集的子类的值public void setExpression(String expression)
expression
- 代码片段或者Sql语句public String getExpression()
public void setFieldName(String fieldName)
fieldName
- 计算型规则必填,保存结算结果的字段public String getFieldName()
public void setIsEnabled(boolean isEnabled)
isEnabled
- 是否启用public boolean getIsEnabled()
public void setTriggeringEvents(TriggeringEventType... triggeringEventTypes)
triggeringEventTypes
- 参数值为TriggeringEventType枚举,1或多个值public ArrayList<TriggeringEventType> getTriggeringEvents()
public void setSeverity(int severity)
severity
- 严重等级值public int getSeverity()
public void setErrorNumber(long errorNumber)
errorNumber
- 错误码public long getErrorNumber()
public void setErrorMessage(String errorMessage)
errorMessage
- 错误描述信息public String getErrorMessage()
public void setRulerType(String ruleEngineType)
ruleEngineType
- 执行器类型,为了扩展当前预定义“SQL” “Java” “Python”“SparkSQL”四种public String getRulerType()
public String getVersion()
public void setEvaluationOrder(int order)
public int getEvaluationOrder()
public Date getCreateTime()
Copyright © 2021–2024 SuperMap. All rights reserved.