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


Java HasText.getText方法代码示例

本文整理汇总了Java中com.google.gwt.user.client.ui.HasText.getText方法的典型用法代码示例。如果您正苦于以下问题:Java HasText.getText方法的具体用法?Java HasText.getText怎么用?Java HasText.getText使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.google.gwt.user.client.ui.HasText的用法示例。


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

示例1: handleValueAttribute

import com.google.gwt.user.client.ui.HasText; //导入方法依赖的package包/类
private void handleValueAttribute(TextFieldGVO gvo, UIObject uiObject) {
	String value = gvo.getValue();
	if ((value != null) && (value.length() > 0)) {
		if (uiObject instanceof HasData) {
			HasData hasData = (HasData)uiObject;
			hasData.setData(value, SetValueGVO.ACTION_ADD, null);
		} else if (uiObject instanceof HasText) {
			HasText hasText = (HasText)uiObject;
			String oldValue = hasText.getText();
			hasText.setText(value);
			doDataChange(gvo, uiObject, oldValue, hasText.getText());
		}
	}
}
 
开发者ID:qafedev,项目名称:qafe-platform,代码行数:15,代码来源:TextFieldRenderer.java

示例2: copy

import com.google.gwt.user.client.ui.HasText; //导入方法依赖的package包/类
private void copy(CopyGVO copyGVO, UIObject sender, String appId, String windowId, String eventSessionId) {
	String toKey = generateId(copyGVO.getTo(), windowId, appId, eventSessionId);
	String fromKey = generateId(copyGVO.getFrom(), windowId, appId, eventSessionId);
	
	List<UIObject> uiObjectsFrom = getUIObjects(fromKey);
	if (uiObjectsFrom == null) {
		return;
	}
	
	List<UIObject> uiObjectsTo = getUIObjects(toKey);
	if (uiObjectsTo == null) {
		return;
	}
	if (uiObjectsTo.size()==uiObjectsFrom.size()){
		for (int i=0;i<uiObjectsTo.size();i++){
			UIObject uiObjectFrom = uiObjectsFrom.get(i);
			UIObject uiObjectTo = uiObjectsTo.get(i);
			
			if (uiObjectFrom instanceof HasText) {
				HasText hasTextFrom = (HasText) uiObjectFrom;
				String fromValue = hasTextFrom.getText();
				if (uiObjectTo instanceof HasText) {
					HasText hasTextTo = (HasText) uiObjectTo;
					hasTextTo.setText(fromValue);
				}
			}
		
		}
	}
}
 
开发者ID:qafedev,项目名称:qafe-platform,代码行数:31,代码来源:CopyHandler.java

示例3: getValue

import com.google.gwt.user.client.ui.HasText; //导入方法依赖的package包/类
private static String getValue(HasText hasText) {
       String value = hasText.getText();
       if (hasText instanceof UIObject) {
       	handleSimpleValue((UIObject) hasText, value);
       }
       return value;
}
 
开发者ID:qafedev,项目名称:qafe-platform,代码行数:8,代码来源:BuiltinHandlerHelper.java

示例4: execute

import com.google.gwt.user.client.ui.HasText; //导入方法依赖的package包/类
public void execute(BuiltInFunctionGVO builtInFunction) {
	if (builtInFunction instanceof CopyGVO) {
		CopyGVO copy = (CopyGVO) builtInFunction;

		List<UIObject> uiObjectsFrom = null;
		if (copy.getFromGVO().getComponentIdUUID() != null) {
			uiObjectsFrom = RendererHelper.getComponent(copy.getFromGVO().getComponentIdUUID());
		} else {
			uiObjectsFrom = RendererHelper.getNamedComponent(copy.getFromGVO().getComponentName());
		}

		List<UIObject> uiObjectsTo = null;
		if (copy.getToGVO().getComponentIdUUID() != null) {
			uiObjectsTo = RendererHelper.getComponent(copy.getToGVO().getComponentIdUUID());
		} else {
			uiObjectsTo = RendererHelper.getNamedComponent(copy.getToGVO().getComponentName());
		}

		if (uiObjectsTo != null && uiObjectsFrom != null) {
			if (uiObjectsTo.size()==uiObjectsFrom.size()){
				for (int i=0;i<uiObjectsTo.size();i++){
					UIObject uiObjectFrom = uiObjectsFrom.get(i);
					UIObject uiObjectTo = uiObjectsTo.get(i);
					
					if (uiObjectFrom instanceof HasText) {
						HasText hasTextFrom = (HasText) uiObjectFrom;
						String fromValue = hasTextFrom.getText();
						if (uiObjectTo instanceof HasText) {
							HasText hasTextTo = (HasText) uiObjectTo;
							hasTextTo.setText(fromValue);
						}
					}
				
				}
			}
		}
	}
	FunctionsExecutor.setProcessedBuiltIn(true);
}
 
开发者ID:qafedev,项目名称:qafe-platform,代码行数:40,代码来源:CopyExecute.java


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