本文整理汇总了Java中com.rapidminer.operator.Value类的典型用法代码示例。如果您正苦于以下问题:Java Value类的具体用法?Java Value怎么用?Java Value使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Value类属于com.rapidminer.operator包,在下文中一共展示了Value类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: Data2Log
import com.rapidminer.operator.Value; //导入依赖的package包/类
public Data2Log(OperatorDescription description) {
super(description);
exampleSetInput.addPrecondition(new AttributeSetPrecondition(exampleSetInput, AttributeSetPrecondition
.getAttributesByParameter(this, PARAMETER_ATTRIBUTE_NAME)));
exampleSetInput.addPrecondition(new ExampleSetSizePrecondition(exampleSetInput, this, PARAMETER_EXAMPLE_INDEX));
getTransformer().addPassThroughRule(exampleSetInput, exampleSetOutput);
addValue(new Value("data_value", "The value from the data which should be logged.") {
@Override
public Object getValue() {
return currentValue;
}
@Override
public boolean isNominal() {
return isNominal;
}
});
}
示例2: fillValueCombo
import com.rapidminer.operator.Value; //导入依赖的package包/类
private void fillValueCombo() {
valueCombo.removeAllItems();
Operator operator = process.getOperator((String) operatorCombo.getSelectedItem());
if (operator != null) {
switch (typeCombo.getSelectedIndex()) {
case 0:
for (Value value : operator.getValues()) {
valueCombo.addItem(value.getKey());
}
if (valueCombo.getItemCount() == 0) {
valueCombo.addItem("no values");
}
break;
case 1:
for (ParameterType type : operator.getParameters().getParameterTypes()) {
valueCombo.addItem(type.getKey());
}
if (valueCombo.getItemCount() == 0) {
valueCombo.addItem("no params");
}
break;
}
}
valueCombo.setSelectedIndex(-1);
}
示例3: Data2Log
import com.rapidminer.operator.Value; //导入依赖的package包/类
public Data2Log(OperatorDescription description) {
super(description);
exampleSetInput.addPrecondition(new AttributeSetPrecondition(exampleSetInput, AttributeSetPrecondition.getAttributesByParameter(this, PARAMETER_ATTRIBUTE_NAME)));
exampleSetInput.addPrecondition(new ExampleSetSizePrecondition(exampleSetInput, this, PARAMETER_EXAMPLE_INDEX));
getTransformer().addPassThroughRule(exampleSetInput, exampleSetOutput);
addValue(new Value("data_value", "The value from the data which should be logged.") {
public Object getValue() {
return currentValue;
}
public boolean isNominal() {
return isNominal;
}
});
}
示例4: fillValueCombo
import com.rapidminer.operator.Value; //导入依赖的package包/类
private void fillValueCombo() {
valueCombo.removeAllItems();
Operator operator = process.getOperator((String) operatorCombo.getSelectedItem());
if (operator != null) {
switch (typeCombo.getSelectedIndex()) {
case 0:
Iterator i = operator.getValues().iterator();
while (i.hasNext()) {
valueCombo.addItem(((Value) i.next()).getKey());
}
if (valueCombo.getItemCount() == 0)
valueCombo.addItem("no values");
break;
case 1:
i = operator.getParameters().getParameterTypes().iterator();
while (i.hasNext()) {
valueCombo.addItem(((ParameterType) i.next()).getKey());
}
if (valueCombo.getItemCount() == 0)
valueCombo.addItem("no params");
break;
}
}
valueCombo.setSelectedIndex(-1);
}
示例5: ExceptionHandling
import com.rapidminer.operator.Value; //导入依赖的package包/类
public ExceptionHandling(OperatorDescription description) {
super(description, "Try", "Catch");
inputExtender.start();
getTransformer().addRule(inputExtender.makePassThroughRule());
getTransformer().addRule(new SubprocessTransformRule(getSubprocess(0)));
getTransformer().addRule(new SubprocessTransformRule(getSubprocess(1)));
getTransformer().addRule(outputExtender.makePassThroughRule());
outputExtender.start();
addValue(new Value("success", "Indicates whether the execution was successful") {
@Override
public Object getValue() {
return withoutError;
}
@Override
public boolean isNominal() {
return true;
}
});
addValue(new Value("exception", "The exception that occured during execution.") {
@Override
public Object getValue() {
return throwable;
}
@Override
public boolean isNominal() {
return true;
}
});
}
示例6: fillValueCombo
import com.rapidminer.operator.Value; //导入依赖的package包/类
private void fillValueCombo() {
valueCombo.removeAllItems();
Operator operator = process.getOperator((String) operatorCombo.getSelectedItem());
if (operator != null) {
switch (typeCombo.getSelectedIndex()) {
case 0:
Iterator i = operator.getValues().iterator();
while (i.hasNext()) {
valueCombo.addItem(((Value) i.next()).getKey());
}
if (valueCombo.getItemCount() == 0) {
valueCombo.addItem("no values");
}
break;
case 1:
i = operator.getParameters().getParameterTypes().iterator();
while (i.hasNext()) {
valueCombo.addItem(((ParameterType) i.next()).getKey());
}
if (valueCombo.getItemCount() == 0) {
valueCombo.addItem("no params");
}
break;
}
}
valueCombo.setSelectedIndex(-1);
}
示例7: ExceptionHandling
import com.rapidminer.operator.Value; //导入依赖的package包/类
public ExceptionHandling(OperatorDescription description) {
super(description, "Try", "Catch");
inputExtender.start();
getTransformer().addRule(inputExtender.makePassThroughRule());
getTransformer().addRule(new SubprocessTransformRule(getSubprocess(0)));
getTransformer().addRule(new SubprocessTransformRule(getSubprocess(1)));
getTransformer().addRule(outputExtender.makePassThroughRule());
outputExtender.start();
addValue(new Value("success", "Indicates whether the execution was successful") {
@Override
public Object getValue() {
return withoutError;
}
@Override
public boolean isNominal() {
return true;
}
});
addValue(new Value("exception", "The exception that occured during execution.") {
@Override
public Object getValue() {
return throwable;
}
@Override
public boolean isNominal() {
return true;
}
});
}