本文整理了Java中org.jvnet.hk2.config.Dom.attribute()
方法的一些代码示例,展示了Dom.attribute()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Dom.attribute()
方法的具体详情如下:
包路径:org.jvnet.hk2.config.Dom
类名称:Dom
方法名:attribute
[英]Obtains the attribute value, after variable expansion.
[中]变量展开后获取属性值。
代码示例来源:origin: javaee/glassfish
/**
* Sets the value to {@link Dom}.
*/
public void set(Dom dom, Object arg) {
dom.attribute(xmlName, arg==null?null:arg.toString());
}
代码示例来源:origin: javaee/glassfish
public void attribute_setHref(Dom dom, GadgetContent target) {
String v1 = dom.attribute("href");
if (v1 == null) {
return ;
}
target.setHref(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setTitle(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("title");
if (v1 == null) {
return ;
}
target.setTitle(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setType(Dom dom, GadgetContent target) {
String v1 = dom.attribute("type");
if (v1 == null) {
return ;
}
target.setType(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setScreenshot(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("screenshot");
if (v1 == null) {
return ;
}
target.setScreenshot(v1);
}
代码示例来源:origin: javaee/glassfish
@Override
public void set(Dom dom, Object arg) {
Dom target = (Dom) arg;
dom.attribute(xmlName, arg==null?null:target.getKey());
}
}
代码示例来源:origin: javaee/glassfish
public void attribute_setDataType(Dom dom, GadgetUserPref target) {
String v1 = dom.attribute("datatype");
if (v1 == null) {
return ;
}
target.setDataType(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setParentId(Dom dom, IntegrationPoint target) {
String v1 = dom.attribute("parentId");
if (v1 == null) {
return ;
}
target.setParentId(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setDescription(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("description");
if (v1 == null) {
return ;
}
target.setDescription(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setAuthor(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("author");
if (v1 == null) {
return ;
}
target.setAuthor(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setAuthorEmail(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("author_email");
if (v1 == null) {
return ;
}
target.setAuthorEmail(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setContent(Dom dom, IntegrationPoint target) {
String v1 = dom.attribute("content");
if (v1 == null) {
return ;
}
target.setContent(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setTitleUrl(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("title_url");
if (v1 == null) {
return ;
}
target.setTitleUrl(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setThumbnail(Dom dom, GadgetModulePrefs target) {
String v1 = dom.attribute("thumbnail");
if (v1 == null) {
return ;
}
target.setThumbnail(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setDisplayName(Dom dom, GadgetUserPref target) {
String v1 = dom.attribute("display_name");
if (v1 == null) {
return ;
}
target.setDisplayName(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setDefaultValue(Dom dom, GadgetUserPref target) {
String v1 = dom.attribute("default_value");
if (v1 == null) {
return ;
}
target.setDefaultValue(v1);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setURLParam(Dom dom, GadgetUserPref target) {
String v1 = dom.attribute("urlparam");
if (v1 == null) {
return ;
}
target.setURLParam(v1);
}
代码示例来源:origin: javaee/glassfish
/**
* Gets the value from {@link Dom} in the specified type.
*
* @param dom The DOM instance to get the value from.
* @param returnType The expected type of the returned object.
* Valid types are (1) primitive and 'leaf' Java types, such as {@link String},
* (2) {@link ConfigBeanProxy}, (3) and its collections.
*/
public Object get(Dom dom, Type returnType) {
String v = dom.attribute(xmlName);
return convertLeafValue(dom, Types.erasure(returnType), v);
}
代码示例来源:origin: javaee/glassfish
public void attribute_setPriority(Dom dom, IntegrationPoint target) {
String v1 = dom.attribute("priority");
if (v1 == null) {
return ;
}
target.setPriority(asInt(v1));
}
代码示例来源:origin: javaee/glassfish
public void attribute_setRequired(Dom dom, GadgetUserPref target) {
String v1 = dom.attribute("required");
if (v1 == null) {
return ;
}
target.setRequired(asBoolean(v1));
}
内容来源于网络,如有侵权,请联系作者删除!