public class UpdateFactFunctionDescriptor extends Object implements FunctionDescriptor
| 构造器和说明 |
|---|
UpdateFactFunctionDescriptor() |
| 限定符和类型 | 方法和说明 |
|---|---|
Object |
doFunction(Object object,
String property,
WorkingMemory workingMemory)
函数运行时要执行的方法
|
Argument |
getArgument()
通过定义一个Argument实例来定义函数所采用的参数,该方法必须要返回一个Argument对象,不能返回null。
|
String |
getLabel()
返回函数显示名称,该名称不能与既有函数Label同名
|
String |
getName()
返回函数名,建议返回一个首字母大写的英文名,该名称不能与既有函数同名
|
boolean |
isDisabled() |
void |
setDisabled(boolean disabled) |
public Argument getArgument()
FunctionDescriptorgetArgument 在接口中 FunctionDescriptorpublic Object doFunction(Object object, String property, WorkingMemory workingMemory)
FunctionDescriptordoFunction 在接口中 FunctionDescriptorobject - 第一个参数运行时的具体值对象property - 当Argument对象中needProperty属性为true时,在使用该函数时定义的具体的属性名,注意这里是属性name而非LabelworkingMemory - 当前运行时的WorkingMemory对象public String getName()
FunctionDescriptorgetName 在接口中 FunctionDescriptorpublic String getLabel()
FunctionDescriptorgetLabel 在接口中 FunctionDescriptorpublic boolean isDisabled()
isDisabled 在接口中 FunctionDescriptorpublic void setDisabled(boolean disabled)
Copyright © 2018 Bstek. All rights reserved.