name
stringlengths
12
178
code_snippet
stringlengths
8
36.5k
score
float64
3.26
3.68
framework_Slot_setSpacing_rdh
/** * Set the spacing for the slot. The spacing determines if there should be * empty space around the slot when the slot. * * @param spacing * Should spacing be enabled */ public void setSpacing(boolean spacing) {if (spacing && (spacer == null)) { spacer = DOM.createDiv(); spacer.addClassName...
3.26
framework_Slot_getSpacingElement_rdh
/** * Get the element which is added to make the spacing. * * @return the spacing element */ @SuppressWarnings("deprecation") public Element getSpacingElement() { return DOM.asOld(spacer); }
3.26
framework_Slot_setExpandRatio_rdh
/** * Set how the slot should be expanded relative to the other slots. 0 means * that the slot should not participate in the division of space based on * the expand ratios but instead be allocated space based on its natural * size. Other values causes the slot to get a share of the otherwise * unallocated space in...
3.26
framework_Slot_setCaptionResizeListener_rdh
/** * Sets the caption resize listener for this slot. * * @param captionResizeListener * the listener to set, or {@code null} to remove a previously * set listener */ public void setCaptionResizeListener(ElementResizeListener captionResizeListener) {detachListeners();this.captionResizeListener = captionResize...
3.26
framework_Slot_m0_rdh
/** * Get the expand ratio for the slot. The expand ratio describes how the * slot should be resized compared to other slots in the layout * * @return the expand ratio of the slot * @see #setExpandRatio(double) */ public double m0() { return expandRatio; }
3.26
framework_Slot_hasCaption_rdh
/** * Does the slot have a caption. * * @return {@code true} if the slot has a caption, {@code false} otherwise */ public boolean hasCaption() { return caption != null; }
3.26
framework_CalendarTest_createCalendarEventPopup_rdh
/* Initializes a modal window to edit schedule event. */ private void createCalendarEventPopup() { VerticalLayout layout = new VerticalLayout(); // layout.setMargin(true); layout.setSpacing(true); scheduleEventPopup = new Window(null, layout); scheduleEventPopup.setWidth("300px"); scheduleEventPopup.setModal(true); sch...
3.26
framework_CalendarTest_deleteCalendarEvent_rdh
/* Removes the event from the data source and fires change event. */ private void deleteCalendarEvent() { BasicEvent event = getFormCalendarEvent(); if (dataSource.containsEvent(event)) { dataSource.removeEvent(event); } getUI().removeWindow(scheduleEventPopup); }
3.26
framework_CalendarTest_commitCalendarEvent_rdh
/* Adds/updates the event in the data source and fires change event. */ private void commitCalendarEvent() throws ValidationException, CommitException { scheduleEventFieldGroup.commit(); BasicEvent event = getFormCalendarEvent(); scheduledEventBinder.writeBean(event); if (event.getEnd() == null) { event.setE...
3.26
framework_CalendarTest_switchToWeekView_rdh
/* Switch the view to week view. */ public void switchToWeekView() { viewMode = Mode.WEEK; // weekButton.setVisible(false); // monthButton.setVisible(true); }
3.26
framework_CalendarTest_switchToDayView_rdh
/* Switch to day view (week view with a single day visible). */ public void switchToDayView() { viewMode = Mode.DAY; // monthButton.setVisible(true); // weekButton.setVisible(true); }
3.26
framework_PerformanceTestSubTreeCaching_populateContainer_rdh
/** * Adds n Table components to given container * * @param testContainer2 */ private void populateContainer(VerticalLayout container, int n) { for (int i = 0; i < n; i++) { // array_type array_element = [i]; final Table t = TestForTablesInitialColumnWidthLogicRendering.getTestTable(5, 100); ...
3.26
framework_BasicDateClickHandler_setDates_rdh
/** * Set the start and end dates for the event. * * @param event * The event that the start and end dates should be set * @param start * The start date * @param end * The end date */ protected void setDates(DateClickEvent event, Date start, Date end) { event.getComponent().setStartDate(start); e...
3.26
framework_AbstractColorPicker_setPosition_rdh
/** * Sets the position of the popup window. * * @param x * the x-coordinate * @param y * the y-coordinate */ public void setPosition(int x, int y) {positionX = x; positionY = y; if (window != null) { window.setPositionX(x); window.setPositionY(y); } }
3.26
framework_AbstractColorPicker_getHistoryVisibility_rdh
/** * Gets the visibility of the Color History. * * @since 7.5.0 * @return visibility of color history */ public boolean getHistoryVisibility() { return historyVisible; }
3.26
framework_AbstractColorPicker_colorChanged_rdh
/** * Fired when a color change event occurs. * * @param event * The color change event */ protected void colorChanged(ColorChangeEvent event) { setColor(event.getColor()); fireColorChanged(); }
3.26
framework_AbstractColorPicker_getPopupStyle_rdh
/** * Gets the style for the popup window. * * @since 7.5.0 * @return popup window style */ public PopupStyle getPopupStyle() { return popupStyle; }
3.26
framework_AbstractColorPicker_setHtmlContentAllowed_rdh
/** * Set whether the caption text is rendered as HTML or not. You might need * to re-theme component to allow higher content than the original text * style. * * If set to true, the captions are passed to the browser as html and the * developer is responsible for ensuring no harmful html is used. If set to * fal...
3.26
framework_AbstractColorPicker_setTextfieldVisibility_rdh
/** * Sets the visibility of the CSS color code text field. * * @param visible * The visibility */ public void setTextfieldVisibility(boolean visible) { f2 = visible; if (window != null) { window.setPreviewVisible(visible); } }
3.26
framework_AbstractColorPicker_setSwatchesVisibility_rdh
/** * Set the visibility of the Swatches Tab. * * @param visible * The visibility */public void setSwatchesVisibility(boolean visible) { if (((!visible) && (!hsvVisible)) && (!rgbVisible)) { throw new IllegalArgumentException("Cannot hide all tabs."); } f1 = visible; if (window != null) ...
3.26
framework_AbstractColorPicker_setHistoryVisibility_rdh
/** * Sets the visibility of the Color History. * * @param visible * The visibility */ public void setHistoryVisibility(boolean visible) { historyVisible = visible; if (window != null) { window.setHistoryVisible(visible); } }
3.26
framework_AbstractColorPicker_m2_rdh
/** * Hides a popup-window for color selection. */ public void m2() { showPopup(false); }
3.26
framework_AbstractColorPicker_setDefaultCaptionEnabled_rdh
/** * Set true if the component should show a default caption (css-code for the * currently selected color, e.g. #ffffff) when no other caption is * available. * * @param enabled */ public void setDefaultCaptionEnabled(boolean enabled) { m1().showDefaultCaption = enabled; }
3.26
framework_AbstractColorPicker_showPopup_rdh
/** * Shows or hides popup-window depending on the given parameter. If there is * no such window yet, one is created. * * @param open */ protected void showPopup(boolean open) { if (open && (!isReadOnly())) { if (parent == null) { parent = getUI();} if (window == null) { // Create the popup ...
3.26
framework_AbstractColorPicker_getSwatchesVisibility_rdh
/** * Gets the visibility of the Swatches Tab. * * @since 7.5.0 * @return visibility of the swatches tab */ public boolean getSwatchesVisibility() { return f1; }
3.26
framework_AbstractColorPicker_m0_rdh
/** * Set the visibility of the RGB Tab. * * @param visible * The visibility */ public void m0(boolean visible) { if (((!visible) && (!hsvVisible)) && (!f1)) {throw new IllegalArgumentException("Cannot hide all tabs."); } rgbVisible = visible; if (window != null) { window.setRGBTabVisible...
3.26
framework_AbstractColorPicker_getTextfieldVisibility_rdh
/** * Gets the visibility of CSS color code text field. * * @since 7.5.0 * @return visibility of css color code text field */ public boolean getTextfieldVisibility() { return f2; }
3.26
framework_AbstractColorPicker_setHSVVisibility_rdh
/** * Set the visibility of the HSV Tab. * * @param visible * The visibility */ public void setHSVVisibility(boolean visible) { if (((!visible) && (!rgbVisible)) && (!f1)) { throw new IllegalArgumentException("Cannot hide all tabs."); } hsvVisible = visible; if (window != null) { ...
3.26
framework_AbstractColorPicker_isDefaultCaptionEnabled_rdh
/** * Returns true if the component shows the default caption (css-code for the * currently selected color, e.g. #ffffff) if no other caption is available. */ public boolean isDefaultCaptionEnabled() { return getState(false).showDefaultCaption; }
3.26
framework_HasHierarchicalDataProvider_getTreeData_rdh
/** * Gets the backing {@link TreeData} instance of the data provider, if the * data provider is a {@link TreeDataProvider}. * * @return the TreeData instance used by the data provider * @throws IllegalStateException * if the type of the data provider is not * {@link TreeDataP...
3.26
framework_HasHierarchicalDataProvider_m0_rdh
/** * Sets the data items of this component provided as a stream. * <p> * The provided items are wrapped into a {@link TreeDataProvider} backed by * a flat {@link TreeData} structure. The data provider instance is used as * a parameter for the {@link #setDataProvider(DataProvider)} method. It * means that the ite...
3.26
framework_HasHierarchicalDataProvider_setItems_rdh
/** * Sets the data items of this listing. * <p> * The provided items are wrapped into a {@link TreeDataProvider} backed by * a flat {@link TreeData} structure. The data provider instance is used as * a parameter for the {@link #setDataProvider(DataProvider)} method. It * means that the items collection can be ac...
3.26
framework_Color_getRed_rdh
/** * Returns the red value of the color. */ public int getRed() { return red; }
3.26
framework_Color_checkRange_rdh
/** * Checks that all values are within the acceptable range of [0, 255]. * * @throws IllegalArgumentException * if any of the values fall outside of the range * @param red * @param green * @param blue * @param alpha */ private void checkRange(int red, int green, int blue, int alpha) { if ((((!m0(red)) |...
3.26
framework_Color_setBlue_rdh
/** * Sets the blue value of the color. Value must be within the range [0, * 255]. * * @param blue * new blue value */ public void setBlue(int blue) { if (m0(blue)) { this.blue = blue; } else { throw new IllegalArgumentException(OUTOFRANGE + blue); } }
3.26
framework_Color_m1_rdh
/** * Returns converted HSV components of the color. */ public float[] m1() { float[] hsv = new float[3]; int v10 = (red > green) ? red : green; if (blue > v10) { ...
3.26
framework_Color_m0_rdh
/** * Checks whether the value is within the acceptable range of [0, 255]. * * @param value * @return true if the value falls within the range, false otherwise */ private boolean m0(int value) { if ((value < 0) || (value > 255)) { return false; } return true; }
3.26
framework_Color_getGreen_rdh
/** * Returns the green value of the color. */ public int getGreen() { return green; }
3.26
framework_Color_getAlpha_rdh
/** * Returns the alpha value of the color. */ public int getAlpha() { return alpha; }
3.26
framework_Color_HSVtoRGB_rdh
/** * <p> * Converts HSV's hue, saturation and value into an RGB value. * <p> * The <code>saturation</code> and <code>value</code> components should be * floating-point values within the range [0.0-1.0]. * <p> * ...
3.26
framework_Color_getBlue_rdh
/** * Returns the blue value of the color. */ public int getBlue() { return blue; }
3.26
framework_Color_getRGB_rdh
/** * Returns RGB value of the color. */ public int getRGB() { return ((((alpha & 0xff) << 24) | ((red & 0xff) << 16)) | ((green & 0xff) << 8)) | ((blue & 0xff) << 0); }
3.26
framework_Color_HSLtoRGB_rdh
/** * <p> * Converts HSL's hue, saturation and lightness into an RGB value. * * @param hue * the hue of the color. The unit of the value is degrees and * should be between 0-360. * @param saturation * the saturation of the color. The unit of the value is * percentages and should be between 0-100; * @p...
3.26
framework_Color_setRed_rdh
/** * Sets the red value of the color. Value must be within the range [0, 255]. * * @param red * new red value */ public void setRed(int red) { if (m0(red)) { this.red = red; } else { throw new IllegalArgumentException(OUTOFRANGE + red); }}
3.26
framework_Color_getCSS_rdh
/** * Returns CSS representation of the Color, e.g. #000000. */ public String getCSS() { String redString = Integer.toHexString(red); redString = (redString.length() < 2) ? "0" + redString : redString; String greenString = Integer.toHexString(green); greenString = (greenString.length() < 2) ? "0" ...
3.26
framework_Color_setGreen_rdh
/** * Sets the green value of the color. Value must be within the range [0, * 255]. * * @param green * new green value */ public void setGreen(int green) { if (m0(green)) { this.green = green; } else { throw new IllegalArgumentException(OUTOFRANGE + green); } }
3.26
framework_Color_setAlpha_rdh
/** * Sets the alpha value of the color. Value must be within the range [0, * 255]. * * @param alpha * new alpha value */ public void setAlpha(int alpha) { if (m0(alpha)) { this.alpha = alpha; } else { throw new IllegalArgumentException(OUTOFRANGE + alpha); } }
3.26
framework_SingleSelectionModelImpl_setSelectedFromClient_rdh
/** * Sets the selection based on a client request. Does nothing if the select * component is {@linkplain SingleSelect#isReadOnly()} or if the selection * would not change. Otherwise updates the selection and fires a selection * change event with {@code isUserOriginated == true}. * * @param key * the key of th...
3.26
framework_SingleSelectionModelImpl_setSelectedFromServer_rdh
/** * Sets the selection based on server API call. Does nothing if the * selection would not change; otherwise updates the selection and fires a * selection change event with {@code isUserOriginated == false}. * * @param item * the item to select or {@code null} to clear selection */ protected void setSelected...
3.26
framework_SingleSelectionModelImpl_m1_rdh
/** * Sets the selected item. If the item is {@code null}, clears the current * selection if any. * * @param item * the selected item or {@code null} to clear selection * @since 8.1 */ protected void m1(T item) { if (getParent(...
3.26
framework_SingleSelectionModelImpl_asSingleSelect_rdh
/** * Gets a wrapper for using this grid as a single select in a binder. * * @return a single select wrapper for grid */ @Override public SingleSelect<T> asSingleSelect() { return new SingleSelect<T>() { @Override public void setValue(T value) { ...
3.26
framework_ResourceLoader_loadScript_rdh
/** * Load a script and notify a listener when the script is loaded. Calling * this method when the script is currently loading or already loaded * doesn't cause the script to be loaded again, but the listener will still * be notified when appropriate. * * @param scriptUrl * the url of the script to load * @p...
3.26
framework_ResourceLoader_loadStylesheet_rdh
/** * Load a stylesheet and notify a listener when the stylesheet is loaded. * Calling this method when the stylesheet is currently loading or already * loaded doesn't cause the stylesheet to be loaded again, but the listener * will still be notified when appropriate. * * @param stylesheetUrl * the url of the ...
3.26
framework_ResourceLoader_getResourceUrl_rdh
/** * Gets the absolute url of the loaded resource. * * @return the absolute url of the loaded resource */ public String getResourceUrl() {return resourceUrl; }
3.26
framework_ResourceLoader_loadHtmlImport_rdh
/** * Loads an HTML import and notify a listener when the HTML import is * loaded. Calling this method when the HTML import is currently loading or * already loaded doesn't cause the HTML import to be loaded again, but the * listener will still be notified when appropriate. * * @param ...
3.26
framework_ResourceLoader_runWhenHtmlImportsReady_rdh
/** * Executes a Runnable when all HTML imports are ready. If the browser does * not support triggering an event when HTML imports are ready, the Runnable * is executed immediately. * * @param runnable * the code to execute * @since 8.1 */ protected void runWhenHtmlImportsReady(Runnable runnable) { if (...
3.26
framework_ResourceLoader_m0_rdh
/** * Gets the resource loader that has fired this event. * * @return the resource loader */ public ResourceLoader m0() { return loader; }
3.26
framework_LoginForm_login_rdh
/** * Handles the login. * <p> * In deferred mode, this method is called after the dummy POST request that * triggers the password manager has been completed. In direct mode (the * default setting), it is called directly when the user hits the enter key * or clicks on the login button. In the latter case, you can...
3.26
framework_LoginForm_createPasswordField_rdh
/** * Customize the password field. Only for overriding, do not call. * * @return the password field * @since 7.7 */protected PasswordField createPasswordField() { throwIfInitialized(); return new PasswordField(getPasswordCaption()); }
3.26
framework_LoginForm_getUsernameCaption_rdh
/** * Gets the caption set with {@link #setUsernameCaption(String)}. Note that * this method might not match what is shown to the user if * {@link #createUsernameField()} has been overridden. * * @return the user name field caption */ public String getUsernameCaption() { return usernameCaption;}
3.26
framework_LoginForm_createLoginButton_rdh
/** * Customize the login button. Only for overriding, do not call. * * @return the login button * @since 7.7 */ protected Button createLoginButton() { throwIfInitialized(); return new Button(getLoginButtonCaption()); } /** * Gets the caption set with {@li...
3.26
framework_LoginForm_createUsernameField_rdh
/** * Customize the user name field. Only for overriding, do not call. * * @return the user name field * @since 7.7 */ protected TextField createUsernameField() { throwIfInitialized(); TextField field = new TextField(getUsernameCaption()); field.focus(); return field; }
3.26
framework_LoginForm_setUsernameCaption_rdh
/** * Sets the caption of the user name field. Note that the caption can only * be set with this method before the login form has been initialized * (attached). * <p> * As an alternative to calling this method, the method * {@link #createUsernameField()} can be overridden. * * @param usernameCaption * the ca...
3.26
framework_LoginForm_getPasswordCaption_rdh
/** * Gets the caption set with {@link #setPasswordCaption(String)}. Note that * this method might not match what is shown to the user if * {@link #createPasswordField()} has been overridden. * * @return the password field caption */ public String getPasswordCaption() { return passwordCaption; }
3.26
framework_LoginForm_setPasswordCaption_rdh
/** * Set the caption of the password field. Note that the caption can only be * set with this method before the login form has been initialized * (attached). * <p> * As an alternative to calling this method, the method * {@link #createPasswordField()} can be overridden. * * @param passwordCaption * the capt...
3.26
framework_LoginForm_createContent_rdh
/** * Create the content for the login form with the supplied user name field, * password field and the login button. You cannot use any other text fields * or buttons for this purpose. To replace these components with your own * implementations, override {@link #createUsernameField()}, * {@link #createPasswordFie...
3.26
framework_LoginForm_setLoginButtonCaption_rdh
/** * Sets the caption of the login button. Note that the caption can only be * set with this method before the login form has been initialized * (attached). * <p> * As an alternative to calling this method, the method * {@link #createLoginButton()} can be overridden. * * @param loginButtonCaption * new capt...
3.26
framework_StringToShortConverter_getFormat_rdh
/** * Returns the format used by * {@link #convertToPresentation(Short, Class, Locale)} and * {@link #convertToModel(String, Class, Locale)}. * * @param locale * The locale to use * @return A NumberFormat instance */ @Override protected NumberFormat getFormat(Locale locale) { if (locale == null) { ...
3.26
framework_CustomLayout_removeComponent_rdh
/** * Removes the component from this container from given location. * * @param location * the Location identifier of the component. */ public void removeComponent(String location) { this.removeComponent(slots.get(location)); }
3.26
framework_CustomLayout_setTemplateContents_rdh
/** * Set the contents of the template used to draw the custom layout. * * Note: setTemplateContents can be applied only before CustomLayout * instance has been attached. * * @param templateContents */ public void setTemplateContents(String templateContents) { getState().t...
3.26
framework_CustomLayout_addComponent_rdh
/** * Adds the component into this container. The component is added without * specifying the location (empty string is then used as location). Only one * component can be added to the default "" location and adding more * components into that location overwrites the old components. * * @param c * the componen...
3.26
framework_CustomLayout_getTemplateContents_rdh
/** * Get the contents of the template. */ public String getTemplateContents() { return getState(false).templateContents; }
3.26
framework_CustomLayout_getComponent_rdh
/** * Gets the child-component by its location. * * @param location * the name of the location where the requested component * resides. * @return the Component in the given location or null if not found. */ public Component getComponent(String location) { return slots.get(location); }
3.26
framework_CustomLayout_replaceComponent_rdh
/* Documented in superclass */ @Override public void replaceComponent(Component oldComponent, Component newComponent) { // Gets the locations String oldLocation = null; String newLocation = null; for (final String location : slots.keySet()) { final Component component = slots.get(location); ...
3.26
framework_CustomLayout_getTemplateName_rdh
/** * Get the name of the template. */ public String getTemplateName() { return getState(false).templateName; }
3.26
framework_CustomLayout_setTemplateName_rdh
/** * Set the name of the template used to draw custom layout. * * With GWT-adapter, the template with name 'templatename' is loaded from * VAADIN/themes/themename/layouts/templatename.html. If the theme has not * been set (with Application.setTheme()), themename is 'default'. * * @param templateName */ public ...
3.26
framework_OddEvenRowStyling_setup_rdh
/** * * @author jonatan */public class OddEvenRowStyling extends TestBase { @Override protected void setup() { Table t = new Table(); t.setPageLength(10); t.addContainerProperty("foo", String.class, ""); for (int i = 0; i < 33; i++) { t.addItem(i).getItemProperty...
3.26
framework_VTabsheetPanel_insert_rdh
/** * Inserts a widget before the specified index. * * @param w * the widget to be inserted * @param beforeIndex * the index before which it will be inserted * @throws IndexOutOfBoundsException * if <code>beforeIndex</code> is out of range */ public void insert(Widget w, int beforeIndex) { Element el...
3.26
framework_VTabsheetPanel_add_rdh
/** * Adds the specified widget to the deck. * * @param w * the widget to be added */ @Override public void add(Widget w) { Element el = createContainerElement(); DOM.appendChild(getElement(), el); super.add(w, el); }
3.26
framework_VTabsheetPanel_getVisibleWidget_rdh
/** * Gets the index of the currently-visible widget. * * @return the visible widget's index */ public int getVisibleWidget() { return getWidgetIndex(visibleWidget);}
3.26
framework_VTabsheetPanel_showWidget_rdh
/** * Shows the widget at the specified index. This causes the currently- * visible widget to be hidden. * * @param index * the index of the widget to be shown */ public void showWidget(int index) { checkIndexBoundsForAccess(index); Widget newVisible = getWidget(index); if (visibleWidget != new...
3.26
framework_ValueContext_getHasValue_rdh
/** * Returns an {@code Optional} for the {@code HasValue} used in the value * conversion. In certain complicated cases, ex. cross-field validation, * HasValue might be not available. * * @return the optional of {@code HasValue} * @since 8.1 */ public Optional<HasValue<?>> getHasValue() { return Optional.ofNull...
3.26
framework_ValueContext_getLocale_rdh
/** * Returns an {@code Optional} for the {@code Locale} used in the value * conversion. * * @return the optional of locale */ public Optional<Locale> getLocale() { return Optional.ofNullable(locale); }
3.26
framework_DateFieldElement_getISOFormatter_rdh
/** * Gets a date and time formatter for ISO-8601 dates. * * @return a date formatter for ISO-8601 * @since 8.1.0 */ protected DateTimeFormatter getISOFormatter() { return DateTimeFormatter.ISO_LOCAL_DATE; }
3.26
framework_DateFieldElement_setValue_rdh
/** * Set value of the date field element. * * @param chars * new value of the date field * @throws ReadOnlyException * if the date field is in readonly mode */ public void setValue(CharSequence chars) throws ReadOnlyException { if (isReadOnly()) { throw new ReadOnlyException(); } WebE...
3.26
framework_DateFieldElement_setDate_rdh
/** * Sets the value to the given date and time. * * @param value * the date and time to set. */ public void setDate(LocalDate value) { setISOValue(value.format(getISOFormatter())); }
3.26
framework_TreeElement_getValue_rdh
/** * Returns selected item of the tree. In multiselect mode returns first * selected item. If there is no selected item returns empty string * * @return selected item of the tree */ public String getValue() { List<WebElement> selectedElements = findElements(By.className("v-tree-node-selected")); if (sel...
3.26
framework_AbstractFieldElement_clientSelectElement_rdh
/** * Select contents of TextField Element. * * NOTE: When testing with firefox browser window should have focus in it * * @since 8.0 * @param elem * element which context will be select */ protected void clientSelectElement(WebElement elem) { JavascriptExecutor js = ((JavascriptExecutor) (getDriver())); ...
3.26
framework_MouseEvents_isAltKey_rdh
/** * Checks if the Alt key was down when the mouse event took place. * * @return true if Alt was down when the event occurred, false otherwise */ public boolean isAltKey() { return details.isAltKey(); }
3.26
framework_MouseEvents_m0_rdh
/** * Returns a human readable string representing which button has been * pushed. This is meant for debug purposes only and the string returned * could change. Use {@link #getButton()} to check which button was * pressed. * * @since 6.3 * @return A string representation of which button was pushed. */ public ...
3.26
framework_Form_m2_rdh
/** * Sets the item datasource for the form. * * <p> * Setting item datasource clears any fields, the form might contain and * adds all the properties as fields to the form. * </p> * * @see Item.Viewer#setItemDataSource(Item) */ @Override public void m2(Item newDataSource) { setItemDataSource(newDataSource...
3.26
framework_Form_getItemProperty_rdh
/** * The property identified by the property id. * * <p> * The property data source of the field specified with property id is * returned. If there is a (with specified property id) having no data * source, the field is returned instead of the data source. * </p> * * @see Item#getItemProperty(Object) */ @Ove...
3.26
framework_Form_setItemDataSource_rdh
/** * Set the item datasource for the form, but limit the form contents to * specified properties of the item. * * <p> * Setting item datasource clears any fields, the form might contain and * adds the specified the properties as fields to the form, in the specified * order. * </p> * * @see Item.Viewer#setIte...
3.26
framework_Form_replaceWithSelect_rdh
/** * Sets the form field to be selectable from static list of changes. * * <p> * The list values and descriptions are given as array. The value-array must * contain the current value of the field and the lengths of the arrays must * match. Null values are not supported. * </p> * * Note: since Vaadin 7.0, retu...
3.26
framework_Form_focus_rdh
/** * Focuses the first field in the form. * * @see Component.Focusable#focus() */ @Override public void focus() { final Field<?> f = getFirstFocusableField(); if (f != null) { f.focus();} }
3.26
framework_Form_setLayout_rdh
/** * Sets the layout of the form. * * <p> * If set to null then Form uses a FormLayout by default. * </p> * * @param layout * the layout of the form. */ public void setLayout(Layout layout) { // Use orderedlayout by default if (layout == null) {layout = new FormLayout(); } // reset cu...
3.26
framework_Form_removeAllActionHandlers_rdh
/** * Removes all action handlers. */ public void removeAllActionHandlers() { if (ownActionManager != null) { ownActionManager.removeAllActionHandlers(); } }
3.26
framework_Form_addField_rdh
/** * Registers the field with the form and adds the field to the form layout. * * <p> * The property id must not be already used in the form. * </p> * * <p> * This field is added to the layout using the * {@link #attachField(Object, Field)} method. * </p> * * @param propertyId * the Property id the the ...
3.26
framework_Form_setInvalidAllowed_rdh
/** * Should the validabtable object accept invalid values. * * @see Validatable#setInvalidAllowed(boolean) */ @Override public void setInvalidAllowed(boolean invalidValueAllowed) throws UnsupportedOperationException { throw new UnsupportedOperationException(); }
3.26
framework_Form_registerField_rdh
/** * Register the field with the form. All registered fields are validated * when the form is validated and also committed when the form is committed. * * <p> * The property id must not be already used in the form. * </p> * * @param propertyId * the Property id of the field. * @param field * the Field t...
3.26