com.vaadin.ui.Upload Java Examples

The following examples show how to use com.vaadin.ui.Upload. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PIPImportWindow.java    From XACML with MIT License 6 votes vote down vote up
@AutoGenerated
private VerticalLayout buildMainLayout() {
	// common part: create layout
	mainLayout = new VerticalLayout();
	mainLayout.setImmediate(false);
	mainLayout.setWidth("-1px");
	mainLayout.setHeight("-1px");
	mainLayout.setMargin(true);
	mainLayout.setSpacing(true);
	
	// top-level component properties
	setWidth("-1px");
	setHeight("-1px");
	
	// upload_1
	upload = new Upload();
	upload.setImmediate(false);
	upload.setWidth("-1px");
	upload.setHeight("-1px");
	mainLayout.addComponent(upload);
	
	return mainLayout;
}
 
Example #2
Source File: BulkUploadHandler.java    From hawkbit with Eclipse Public License 1.0 5 votes vote down vote up
void buildLayout() {
    final HorizontalLayout horizontalLayout = new HorizontalLayout();
    upload = new Upload();
    upload.setEnabled(false);
    upload.setButtonCaption(i18n.getMessage("caption.bulk.upload"));
    upload.setReceiver(this);
    upload.setImmediate(true);
    upload.setWidthUndefined();
    upload.addSucceededListener(this);
    upload.addFailedListener(this);
    upload.addStartedListener(this);
    horizontalLayout.addComponent(upload);
    horizontalLayout.setComponentAlignment(upload, Alignment.BOTTOM_RIGHT);
    setCompositionRoot(horizontalLayout);
}
 
Example #3
Source File: BulkUploadHandler.java    From hawkbit with Eclipse Public License 1.0 4 votes vote down vote up
/**
 * @return the upload
 */
public Upload getUpload() {
    return upload;
}
 
Example #4
Source File: PolicyUploadWindow.java    From XACML with MIT License 4 votes vote down vote up
@AutoGenerated
private VerticalLayout buildMainLayout() {
	// common part: create layout
	mainLayout = new VerticalLayout();
	mainLayout.setImmediate(false);
	mainLayout.setWidth("-1px");
	mainLayout.setHeight("-1px");
	mainLayout.setMargin(true);
	mainLayout.setSpacing(true);
	
	// top-level component properties
	setWidth("-1px");
	setHeight("-1px");
	
	// upload
	upload = new Upload();
	upload.setCaption("Upload Xacml Policy File");
	upload.setImmediate(false);
	upload.setWidth("-1px");
	upload.setHeight("-1px");
	mainLayout.addComponent(upload);
	
	// checkBoxImportAttributes
	checkBoxImportAttributes = new CheckBox();
	checkBoxImportAttributes
			.setCaption("Import attributes into attribute dictionary.");
	checkBoxImportAttributes.setImmediate(false);
	checkBoxImportAttributes.setWidth("-1px");
	checkBoxImportAttributes.setHeight("-1px");
	mainLayout.addComponent(checkBoxImportAttributes);
	
	// checkBoxIgnoreStandard
	checkBoxIgnoreStandard = new CheckBox();
	checkBoxIgnoreStandard.setCaption("Ignore Standard Attributes");
	checkBoxIgnoreStandard.setImmediate(false);
	checkBoxIgnoreStandard.setWidth("-1px");
	checkBoxIgnoreStandard.setHeight("-1px");
	mainLayout.addComponent(checkBoxIgnoreStandard);
	mainLayout.setComponentAlignment(checkBoxIgnoreStandard, new Alignment(
			20));
	
	// checkBoxImportObligations
	checkBoxImportObligations = new CheckBox();
	checkBoxImportObligations
			.setCaption("Import obligations into obligation dictionary.");
	checkBoxImportObligations.setImmediate(false);
	checkBoxImportObligations.setWidth("-1px");
	checkBoxImportObligations.setHeight("-1px");
	mainLayout.addComponent(checkBoxImportObligations);
	
	// checkBoxImportAdvice
	checkBoxImportAdvice = new CheckBox();
	checkBoxImportAdvice
			.setCaption("Import advice into advice dictionary.");
	checkBoxImportAdvice.setImmediate(false);
	checkBoxImportAdvice.setWidth("-1px");
	checkBoxImportAdvice.setHeight("-1px");
	mainLayout.addComponent(checkBoxImportAdvice);
	
	return mainLayout;
}