本文整理匯總了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;
}
});
}