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


Java Location类代码示例

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


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

示例1: convertTag

import javax.faces.view.Location; //导入依赖的package包/类
protected Tag convertTag(Tag tag, Namespace namespace, String localName) {
	Location location = tag.getLocation();
	String ns = namespace.uri;
	String qName = namespace.name() + ":" + localName;

	TagAttributes attributes = convertAttributes(tag.getAttributes(), tag);

	Tag converted = new Tag(location, ns, localName, qName, attributes);

	for (TagAttribute tagAttribute : attributes.getAll()) {
		// set the correct tag
		tagAttribute.setTag(converted);
	}

	return converted;
}
 
开发者ID:TheCoder4eu,项目名称:BootsFaces-OSP,代码行数:17,代码来源:RelaxedTagDecorator.java

示例2: createElementName

import javax.faces.view.Location; //导入依赖的package包/类
private TagAttribute createElementName(Tag tag) {
	Location location = tag.getLocation();
	String ns = Namespace.p.uri;
	String myLocalName = Renderer.PASSTHROUGH_RENDERER_LOCALNAME_KEY;
	String qName = "p:" + myLocalName;
	String value = tag.getLocalName();

	return TagAttributeUtilities.createTagAttribute(location, ns, myLocalName, qName, value);
}
 
开发者ID:TheCoder4eu,项目名称:BootsFaces-OSP,代码行数:10,代码来源:RelaxedTagDecorator.java

示例3: convertTagAttribute

import javax.faces.view.Location; //导入依赖的package包/类
protected TagAttribute convertTagAttribute(TagAttribute attribute) {
	Location location = attribute.getLocation();
	String ns = attribute.getNamespace();
	String myLocalName = attribute.getLocalName();
	String qName;
	String value = attribute.getValue();

	if (Namespace.jsf.uri.equals(attribute.getNamespace())) {
		// make this a component attribute
		qName = myLocalName;
		ns = "";
	} else {
		if (ns.length() != 0 && !ns.equals(attribute.getTag().getNamespace())) {
			// the attribute has a different namespace than the tag.
			// preserve it.
			return attribute;
		}
		if (attribute.getLocalName().equals(otherHtmlIdAttribute)) {
			// special case for input name
			qName = "id";
			myLocalName = "id";
		} else {
			// make this a pass through attribute
			qName = "h:" + myLocalName;
			ns = Namespace.h.uri;
		}
	}
	return TagAttributeUtilities.createTagAttribute(location, ns, myLocalName, qName, value);
}
 
开发者ID:TheCoder4eu,项目名称:BootsFaces-OSP,代码行数:30,代码来源:RelaxedTagDecorator.java

示例4: getLocation

import javax.faces.view.Location; //导入依赖的package包/类
@Override
public Location getLocation() {
	throw new UnsupportedOperationException(NOT_SUPPORTED_YET);
}
 
开发者ID:joinfaces,项目名称:joinfaces,代码行数:5,代码来源:MockTagAttribute.java

示例5: addAttribute

import javax.faces.view.Location; //导入依赖的package包/类
public void addAttribute(Location location, String ns, String myLocalName, String qName, String value) {
	TagAttribute[] newAttrs = Arrays.copyOf(attrs, attrs.length+1);
	newAttrs[attrs.length] = TagAttributeUtilities.createTagAttribute(location, ns, myLocalName, qName, value);
	init(newAttrs);
}
 
开发者ID:TheCoder4eu,项目名称:BootsFaces-OSP,代码行数:6,代码来源:AFTagAttributes.java

示例6: getLocation

import javax.faces.view.Location; //导入依赖的package包/类
/**
 * Gets the location.
 *
 * @return the location
 */
public Location getLocation() {
	return this.location;
}
 
开发者ID:kiswanij,项目名称:jk-faces,代码行数:9,代码来源:JKTagAttributeWrapper.java

示例7: setLocation

import javax.faces.view.Location; //导入依赖的package包/类
/**
 * Sets the location.
 *
 * @param location
 *            the new location
 */
public void setLocation(final Location location) {
	this.location = location;
}
 
开发者ID:kiswanij,项目名称:jk-faces,代码行数:10,代码来源:JKTagAttributeWrapper.java


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