当前位置: 首页>>代码示例>>Java>>正文


Java Registration类代码示例

本文整理汇总了Java中com.vaadin.shared.Registration的典型用法代码示例。如果您正苦于以下问题:Java Registration类的具体用法?Java Registration怎么用?Java Registration使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


Registration类属于com.vaadin.shared包,在下文中一共展示了Registration类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: addQueryConfigurationProvider

import com.vaadin.shared.Registration; //导入依赖的package包/类
public Registration addQueryConfigurationProvider(QueryConfigurationProvider queryConfigurationProvider) {
	ObjectUtils.argumentNotNull(queryConfigurationProvider, "QueryConfigurationProvider must be not null");
	if (queryConfigurationProviders == null) {
		queryConfigurationProviders = new LinkedList<>();
	}
	if (!queryConfigurationProviders.contains(queryConfigurationProvider)) {
		queryConfigurationProviders.add(queryConfigurationProvider);
		// reset store
		resetStorePreservingFreezeState();
	}
	return () -> {
		queryConfigurationProviders.remove(queryConfigurationProvider);
		// reset store
		resetStorePreservingFreezeState();
	};
}
 
开发者ID:holon-platform,项目名称:holon-vaadin,代码行数:17,代码来源:DefaultItemDataSource.java

示例2: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
@Override
public Registration addValueChangeListener(
		com.holonplatform.vaadin.components.Input.ValueChangeListener<T> listener) {
	ObjectUtils.argumentNotNull(listener, "ValueChangeListener must be not null");
	valueChangeListeners.add(listener);
	return () -> valueChangeListeners.remove(listener);
}
 
开发者ID:holon-platform,项目名称:holon-vaadin,代码行数:8,代码来源:AbstractViewComponent.java

示例3: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
@Override
public Registration addValueChangeListener(
		final com.holonplatform.vaadin.components.Input.ValueChangeListener<T> listener) {
	ObjectUtils.argumentNotNull(listener, "ValueChangeListener must be not null");
	return getInternalField().addValueChangeListener(e -> listener.valueChange(new DefaultValueChangeEvent<>(this,
			fromInternalValue(e.getOldValue()), fromInternalValue(e.getValue()), e.isUserOriginated())));
}
 
开发者ID:holon-platform,项目名称:holon-vaadin,代码行数:8,代码来源:AbstractCustomField.java

示例4: addPropertyResizeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
/**
 * Adds a {@link PropertyResizeListener} that gets notified when a property column is resized.
 * @param listener Listener to add (not null)
 * @return the listener registration
 */
public Registration addPropertyResizeListener(final PropertyResizeListener<P> listener) {
	ObjectUtils.argumentNotNull(listener, "Listener must be not null");
	return getGrid()
			.addColumnResizeListener(e -> listener.onPropertyResized(getColumnProperty(e.getColumn().getId()),
					(int) e.getColumn().getWidth(), e.isUserOriginated()));
}
 
开发者ID:holon-platform,项目名称:holon-vaadin,代码行数:12,代码来源:DefaultItemListing.java

示例5: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
@Override
public Registration addValueChangeListener(
		com.holonplatform.vaadin.components.ValueHolder.ValueChangeListener<V> listener) {
	ObjectUtils.argumentNotNull(listener, "ValueChangeListener must be not null");
	return input.addValueChangeListener(e -> listener.valueChange(new DefaultValueChangeEvent<>(this,
			convertToPresentation(e.getOldValue()), convertToPresentation(e.getValue()), e.isUserOriginated())));
}
 
开发者ID:holon-platform,项目名称:holon-vaadin,代码行数:8,代码来源:InputConverterAdapter.java

示例6: addLayoutClickListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
@Override
public Registration addLayoutClickListener(LayoutEvents.LayoutClickListener listener) {
    return addListener(EventId.LAYOUT_CLICK_EVENT_IDENTIFIER,
            LayoutEvents.LayoutClickEvent.class, listener,
            LayoutEvents.LayoutClickListener.clickMethod);
}
 
开发者ID:alump,项目名称:GridStack,代码行数:10,代码来源:GridStackLayout.java

示例7: syncLocale

import com.vaadin.shared.Registration; //导入依赖的package包/类
private void syncLocale() {
    startDateValueChangeRegistration.ifPresent(Registration::remove);
    endDateValueChangeRegistration.ifPresent(Registration::remove);
    try {
        start.setLocale(gantt.getLocale());
        start.setValue(gantt.getStartLocalDateTime());
        end.setLocale(gantt.getLocale());
        end.setValue(gantt.getEndLocalDateTime());
    } finally {
        startDateValueChangeRegistration = Optional.of(start.addValueChangeListener(startDateValueChangeListener));
        endDateValueChangeRegistration = Optional.of(end.addValueChangeListener(endDateValueChangeListener));
    }
    dateFormat = new SimpleDateFormat("MMM dd HH:mm:ss zzz yyyy", gantt.getLocale());
}
 
开发者ID:tltv,项目名称:gantt,代码行数:15,代码来源:DemoUI.java

示例8: setResolution

import com.vaadin.shared.Registration; //导入依赖的package包/类
private void setResolution(org.tltv.gantt.client.shared.Resolution resolution) {
    resolutionValueChangeRegistration.ifPresent(Registration::remove);
    try {
        reso.setValue(resolution);
    } finally {
        resolutionValueChangeRegistration = Optional.of(reso.addValueChangeListener(resolutionValueChangeListener));
    }
}
 
开发者ID:tltv,项目名称:gantt,代码行数:9,代码来源:DemoUI.java

示例9: addStatusChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
@Override
public Registration addStatusChangeListener(StatusChangeListener listener) {
	return binder.addStatusChangeListener(e -> listener.statusChange(new StatusChangeEvent(this, e.hasErrors())));
}
 
开发者ID:ljessendk,项目名称:easybinder,代码行数:5,代码来源:BinderAdapter.java

示例10: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
@Override
public Registration addValueChangeListener(ValueChangeListener<?> listener) {
	return binder.addValueChangeListener(listener);
}
 
开发者ID:ljessendk,项目名称:easybinder,代码行数:5,代码来源:BinderAdapter.java

示例11: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
public Registration addValueChangeListener(HasValue.ValueChangeListener<String> listener) {
    return field.addValueChangeListener(listener);
}
 
开发者ID:vaadin,项目名称:material-theme-fw8,代码行数:4,代码来源:MDTextField.java

示例12: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
public Registration addValueChangeListener(HasValue.ValueChangeListener<LocalDateTime> listener) {
    return field.addValueChangeListener(listener);
}
 
开发者ID:vaadin,项目名称:material-theme-fw8,代码行数:4,代码来源:MDDateTimeField.java

示例13: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
public Registration addValueChangeListener(HasValue.ValueChangeListener<LocalDate> listener) {
    return field.addValueChangeListener(listener);
}
 
开发者ID:vaadin,项目名称:material-theme-fw8,代码行数:4,代码来源:MDDateField.java

示例14: addValueChangeListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
public Registration addValueChangeListener(HasValue.ValueChangeListener<T> listener) {
    return field.addValueChangeListener(listener);
}
 
开发者ID:vaadin,项目名称:material-theme-fw8,代码行数:4,代码来源:MDComboBox.java

示例15: addLayoutClickListener

import com.vaadin.shared.Registration; //导入依赖的package包/类
@Override
public Registration addLayoutClickListener(LayoutEvents.LayoutClickListener listener) {
  Objects.requireNonNull(listener, "listener may not be null");
  return rootLayout.addLayoutClickListener(listener);
}
 
开发者ID:Juchar,项目名称:md-stepper,代码行数:6,代码来源:StepLabel.java


注:本文中的com.vaadin.shared.Registration类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。