當前位置: 首頁>>代碼示例>>Java>>正文


Java PortProvider類代碼示例

本文整理匯總了Java中com.rapidminer.parameter.PortProvider的典型用法代碼示例。如果您正苦於以下問題:Java PortProvider類的具體用法?Java PortProvider怎麽用?Java PortProvider使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


PortProvider類屬於com.rapidminer.parameter包,在下文中一共展示了PortProvider類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = super.getParameterTypes();
	ParameterType type = FileInputPortHandler.makeFileParameterType(this, PARAMETER_FILENAME,
			"Name of the file to read the data from.", getFileSuffix(), new PortProvider() {

				@Override
				public Port getPort() {
					return fileInputPort;
				}
			});
	type.setExpert(false);
	types.add(type);
	DataManagementParameterHelper.addParameterTypes(types, this);
	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-studio,代碼行數:17,代碼來源:BytewiseExampleSource.java

示例2: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = super.getParameterTypes();
	types.add(new ParameterTypeString(PARAMETER_COMMAND, "Command to execute.", false, false));
	ParameterTypeBoolean t = new ParameterTypeBoolean(PARAMETER_LOG_STDOUT, "If set to true, the stdout stream of the command is redirected to the logfile.", true);
	t.registerDependencyCondition(new PortConnectedCondition(this, new PortProvider() {
		@Override public Port getPort() { return stdout; }
	}, false, false));
	types.add(t);

	ParameterTypeBoolean e = new ParameterTypeBoolean(PARAMETER_LOG_STDERR, "If set to true, the stderr stream of the command is redirected to the logfile.", true);
	e.registerDependencyCondition(new PortConnectedCondition(this, new PortProvider() {
		@Override public Port getPort() { return stderr; }
	}, false, false));
	types.add(e);
	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:18,代碼來源:CommandLineOperator.java

示例3: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = new LinkedList<ParameterType>();
	types.add(makeFileParameterType());
	// types.add(new ParameterTypeFile(PARAMETER_CSV_FILE,
	// "The CSV file which should be written.", "csv", false));
	types.add(new ParameterTypeString(PARAMETER_COLUMN_SEPARATOR, "The column separator.", ";", false));
	types.add(new ParameterTypeBoolean(PARAMETER_WRITE_ATTRIBUTE_NAMES, "Indicates if the attribute names should be written as first row.", true, false));
	types.add(new ParameterTypeBoolean(PARAMETER_QUOTE_NOMINAL_VALUES, "Indicates if nominal values should be quoted with double quotes.", true, false));
	types.add(new ParameterTypeBoolean(PARAMETER_FORMAT_DATE,
			"Indicates if date attributes are written as a formated string or as milliseconds past since January 1, 1970, 00:00:00 GMT", true, true));
	ParameterType type = new ParameterTypeBoolean(PARAMETER_APPEND_FILE,
			"Indicates if new content should be appended to the file or if the pre-existing file content should be overwritten.", false, false);
	type.registerDependencyCondition(new PortConnectedCondition(this, new PortProvider() {

		@Override
		public Port getPort() {
			return fileOutputPort;
		}
	}, true, false));
	types.add(type);
	types.addAll(super.getParameterTypes());
	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:25,代碼來源:CSVExampleSetWriter.java

示例4: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = super.getParameterTypes();
	types.add(FileInputPortHandler.makeFileParameterType(this, PARAMETER_DATA_FILE, "Name of the Xrff file to read the data from.", "xrff", new PortProvider() {
		@Override
		public Port getPort() {			
			return fileInputPort;
		}
	}));
	types.add(new ParameterTypeString(PARAMETER_ID_ATTRIBUTE, "The (case sensitive) name of the id attribute"));
	types.add(new ParameterTypeCategory(PARAMETER_DATAMANAGEMENT, "Determines, how the data is represented internally.", DataRowFactory.TYPE_NAMES, DataRowFactory.TYPE_DOUBLE_ARRAY));
	types.add(new ParameterTypeString(PARAMETER_DECIMAL_POINT_CHARACTER, "Character that is used as decimal point.", "."));
	ParameterType type = new ParameterTypeDouble(PARAMETER_SAMPLE_RATIO, "The fraction of the data set which should be read (1 = all; only used if sample_size = -1)", 0.0d, 1.0d, 1.0d);
	type.setExpert(false);
	types.add(type);
	types.add(new ParameterTypeInt(PARAMETER_SAMPLE_SIZE, "The exact number of samples which should be read (-1 = use sample ratio; if not -1, sample_ratio will not have any effect)", -1, Integer.MAX_VALUE, -1));

	types.addAll(RandomGenerator.getRandomGeneratorParameters(this));

	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:22,代碼來源:XrffExampleSource.java

示例5: makeFileParameterType

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
/**
 * Creates (but does not add) the file parameter named by {@link #getFileParameterName()} that
 * depends on whether or not {@link #fileInputPort} is connected.
 */
protected ParameterType makeFileParameterType() {
	return FileInputPortHandler.makeFileParameterType(this, getFileParameterName(),
			"Name of the file to read the data from.", new PortProvider() {

				@Override
				public Port getPort() {
					return fileInputPort;
				}
			}, true, getFileExtensions());
}
 
開發者ID:transwarpio,項目名稱:rapidminer,代碼行數:15,代碼來源:AbstractDataResultSetReader.java

示例6: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = super.getParameterTypes();

	/*
	 * ParameterType fileParam = new ParameterTypeFile(PARAMETER_EXCEL_FILE,
	 * "Name of the excel file to read the data from.", "xls", false);
	 * fileParam.registerDependencyCondition(new InputPortNotConnectedCondition(this, new
	 * PortProvider() {
	 *
	 * @Override public Port getPort() { return fileInputPort; } }, true));
	 * types.add(fileParam);
	 */
	types.add(FileInputPortHandler.makeFileParameterType(this, PARAMETER_EXCEL_FILE,
			"Name of the file to read the data from.", "xls", new PortProvider() {

		@Override
		public Port getPort() {
			return fileInputPort;
		}
	}));

	types.add(new ParameterTypeInt(PARAMETER_SHEET_NUMBER, "The number of the sheet which should be imported.", 1,
			Integer.MAX_VALUE, 1, false));

	types.addAll(Encoding.getParameterTypes(this));

	return types;
}
 
開發者ID:transwarpio,項目名稱:rapidminer,代碼行數:30,代碼來源:ExcelFormatExampleSource.java

示例7: makeFileParameterType

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
/**
 * Creates the file parameter named by fileParameterName that depends on whether or not the port
 * returned by the given PortProvider is connected.
 */
public static ParameterType makeFileParameterType(ParameterHandler parameterHandler, String parameterName,
		String fileExtension, PortProvider portProvider) {
	final ParameterTypeFile fileParam = new ParameterTypeFile(parameterName, "Name of the file to write the data in.",
			true, new String[] { fileExtension });
	fileParam.setExpert(false);
	fileParam.registerDependencyCondition(new PortConnectedCondition(parameterHandler, portProvider, true, false));
	return fileParam;
}
 
開發者ID:transwarpio,項目名稱:rapidminer,代碼行數:13,代碼來源:FileOutputPortHandler.java

示例8: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = new LinkedList<ParameterType>();
	types.add(makeFileParameterType());
	// types.add(new ParameterTypeFile(PARAMETER_CSV_FILE,
	// "The CSV file which should be written.", "csv", false));
	types.add(new ParameterTypeString(PARAMETER_COLUMN_SEPARATOR, "The column separator.", ";", false));
	types.add(new ParameterTypeBoolean(PARAMETER_WRITE_ATTRIBUTE_NAMES,
			"Indicates if the attribute names should be written as first row.", true, false));
	types.add(new ParameterTypeBoolean(PARAMETER_QUOTE_NOMINAL_VALUES,
			"Indicates if nominal values should be quoted with double quotes.", true, false));
	types.add(new ParameterTypeBoolean(
			PARAMETER_FORMAT_DATE,
			"Indicates if date attributes are written as a formated string or as milliseconds past since January 1, 1970, 00:00:00 GMT",
			true, true));
	ParameterType type = new ParameterTypeBoolean(
			PARAMETER_APPEND_FILE,
			"Indicates if new content should be appended to the file or if the pre-existing file content should be overwritten.",
			false, false);
	type.registerDependencyCondition(new PortConnectedCondition(this, new PortProvider() {

		@Override
		public Port getPort() {
			return fileOutputPort;
		}
	}, true, false));
	types.add(type);
	types.addAll(super.getParameterTypes());
	return types;
}
 
開發者ID:transwarpio,項目名稱:rapidminer,代碼行數:31,代碼來源:CSVExampleSetWriter.java

示例9: makeFileParameterType

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
/**
 * Creates (but does not add) the file parameter named by {@link #getFileParameterName()} that
 * depends on whether or not {@link #fileOutputPort} is connected.
 */
protected ParameterType makeFileParameterType() {
	return FileOutputPortHandler.makeFileParameterType(this, getFileParameterName(), new PortProvider() {

		@Override
		public Port getPort() {
			return fileOutputPort;
		}
	}, getFileExtensions());
}
 
開發者ID:transwarpio,項目名稱:rapidminer,代碼行數:14,代碼來源:AbstractStreamWriter.java

示例10: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = super.getParameterTypes();

	/*
	 * ParameterType fileParam = new ParameterTypeFile(PARAMETER_EXCEL_FILE,
	 * "Name of the excel file to read the data from.", "xls", false);
	 * fileParam.registerDependencyCondition(new InputPortNotConnectedCondition(this, new
	 * PortProvider() {
	 *
	 * @Override public Port getPort() { return fileInputPort; } }, true));
	 * types.add(fileParam);
	 */
	types.add(FileInputPortHandler.makeFileParameterType(this, PARAMETER_EXCEL_FILE,
			"Name of the file to read the data from.", "xls", new PortProvider() {

				@Override
				public Port getPort() {
					return fileInputPort;
				}
			}));

	types.add(new ParameterTypeInt(PARAMETER_SHEET_NUMBER, "The number of the sheet which should be imported.", 1,
			Integer.MAX_VALUE, 1, false));

	types.addAll(Encoding.getParameterTypes(this));

	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-studio,代碼行數:30,代碼來源:ExcelFormatExampleSource.java

示例11: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = new LinkedList<ParameterType>();
	types.add(makeFileParameterType());
	// types.add(new ParameterTypeFile(PARAMETER_CSV_FILE,
	// "The CSV file which should be written.", "csv", false));
	types.add(new ParameterTypeString(PARAMETER_COLUMN_SEPARATOR, "The column separator.", ";", false));
	types.add(new ParameterTypeBoolean(PARAMETER_WRITE_ATTRIBUTE_NAMES,
			"Indicates if the attribute names should be written as first row.", true, false));
	types.add(new ParameterTypeBoolean(PARAMETER_QUOTE_NOMINAL_VALUES,
			"Indicates if nominal values should be quoted with double quotes.", true, false));
	types.add(new ParameterTypeBoolean(PARAMETER_FORMAT_DATE,
			"Indicates if date attributes are written as a formated string or as milliseconds past since January 1, 1970, 00:00:00 GMT",
			true, true));
	ParameterType type = new ParameterTypeBoolean(PARAMETER_APPEND_FILE,
			"Indicates if new content should be appended to the file or if the pre-existing file content should be overwritten.",
			false, false);
	type.registerDependencyCondition(new PortConnectedCondition(this, new PortProvider() {

		@Override
		public Port getPort() {
			return fileOutputPort;
		}
	}, true, false));
	types.add(type);
	types.addAll(super.getParameterTypes());
	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-studio,代碼行數:29,代碼來源:CSVExampleSetWriter.java

示例12: makeFileParameterType

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
/** Creates (but does not add) the file parameter named by {@link #getFileParameterName()} 
 *  that depends on whether or not {@link #fileInputPort} is connected. */
protected ParameterType makeFileParameterType() {
	return FileInputPortHandler.makeFileParameterType(this, getFileParameterName(), "Name of the file to read the data from.", new PortProvider() {
		@Override
		public Port getPort() {
			return fileInputPort;
		}
	}, getFileExtensions());
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:11,代碼來源:AbstractDataResultSetReader.java

示例13: getParameterTypes

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
@Override
public List<ParameterType> getParameterTypes() {
	List<ParameterType> types = super.getParameterTypes();

	/*
	 * ParameterType fileParam = new ParameterTypeFile(PARAMETER_EXCEL_FILE,
	 * "Name of the excel file to read the data from.", "xls", false);
	 * fileParam.registerDependencyCondition(new
	 * InputPortNotConnectedCondition(this, new PortProvider() {
	 * 
	 * @Override public Port getPort() { return fileInputPort; } }, true));
	 * types.add(fileParam);
	 */
	types.add(FileInputPortHandler.makeFileParameterType(this,
			PARAMETER_EXCEL_FILE, "Name of the file to read the data from.", "xls", new PortProvider() {
				@Override
				public Port getPort() {
					return fileInputPort;
				}
			}));

	types.add(new ParameterTypeInt(PARAMETER_SHEET_NUMBER,
			"The number of the sheet which should be imported.", 1,
			Integer.MAX_VALUE, 1, false));

	types.addAll(Encoding.getParameterTypes(this));

	return types;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:30,代碼來源:ExcelFormatExampleSource.java

示例14: makeFileParameterType

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
private ParameterType makeFileParameterType() {
	return FileInputPortHandler.makeFileParameterType(this, getFileParameterName(), "Name of the file to read the data from.", new PortProvider() {
		@Override
		public Port getPort() {
			return fileInputPort;
		}
	}, getFileExtension());
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:9,代碼來源:SASExampleSource.java

示例15: makeFileParameterType

import com.rapidminer.parameter.PortProvider; //導入依賴的package包/類
/** Creates the file parameter named by fileParameterName 
 *  that depends on whether or not the port returned by the given PortProvider is connected. */
public static ParameterType makeFileParameterType(ParameterHandler parameterHandler, String parameterName, String fileExtension, PortProvider portProvider) {
	final ParameterTypeFile fileParam = new ParameterTypeFile(parameterName, "Name of the file to write the data in.", true, new String[] { fileExtension });
	fileParam.setExpert(false);
	fileParam.registerDependencyCondition(new PortConnectedCondition(parameterHandler, portProvider, true, false));
	return fileParam;
}
 
開發者ID:rapidminer,項目名稱:rapidminer-5,代碼行數:9,代碼來源:FileOutputPortHandler.java


注:本文中的com.rapidminer.parameter.PortProvider類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。