- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中org.onosproject.yang.compiler.datamodel.YangLeafRef.setParentNode()
方法的一些代码示例,展示了YangLeafRef.setParentNode()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YangLeafRef.setParentNode()
方法的具体详情如下:
包路径:org.onosproject.yang.compiler.datamodel.YangLeafRef
类名称:YangLeafRef
方法名:setParentNode
[英]Sets the parent node from the leafref's leaf.
[中]从leafref的叶设置父节点。
代码示例来源:origin: org.onosproject/onos-yang-compiler-datamodel
/**
* Returns resolvable entity when the type is leaf-ref. It changes the
* prefixes from grouping to uses, then changes the parent node to the
* cloned node, sets needed information to entity such as line number,
* position number and holder.
*
* @param type YANG type of leaf-ref
* @param yangUses YANG uses
* @param holder cloned holder
* @return entity to resolve for leaf-ref
* @throws DataModelException data model error
*/
private static YangEntityToResolveInfoImpl getLeafRefResolvableEntity(
YangType type, YangUses yangUses, YangNode holder)
throws DataModelException {
YangEntityToResolveInfoImpl<YangLeafRef> leafRefInfo =
new YangEntityToResolveInfoImpl<>();
YangLeafRef leafRef = (YangLeafRef) type.getDataTypeExtendedInfo();
// Conversion of prefixes in absolute path while cloning them.
convertThePrefixesDuringChange(leafRef, yangUses);
leafRef.setParentNode(holder);
leafRefInfo.setEntityToResolve(leafRef);
return setInformationInEntity(
leafRefInfo, holder, leafRef.getCharPosition(),
leafRef.getLineNumber());
}
代码示例来源:origin: org.onosproject/onos-yang-compiler-parser
leafRef.setParentNode((YangNode) parentNodeOfLeaf);
if (listener.getGroupingDepth() == 0) {
leafRef.setParentNode((YangNode) parentNodeOfLeafList);
leafRef.setParentNode((YangNode) parentNodeOfLeafref);
if (listener.getGroupingDepth() != 0) {
leafRef.setInGrouping(true);
代码示例来源:origin: org.onosproject/onos-yang-compiler-linker
/**
* Adds resolvable type (leaf-ref) info to resolution list.
*
* @param extType resolvable type
* @param type YANG type
* @param holder holder node
* @throws DataModelException if there is a data model error
*/
private void addRefTypeInfo(T extType, YangType<T> type, YangNode holder)
throws DataModelException {
type.resetYangType();
type.setResolvableStatus(RESOLVED);
type.setDataType(YangDataTypes.LEAFREF);
type.setDataTypeName(LEAFREF);
type.setDataTypeExtendedInfo(extType);
YangLeafRef leafRef = (YangLeafRef) extType;
(leafRef).setResolvableStatus(UNRESOLVED);
leafRef.setParentNode(holder);
YangResolutionInfoImpl info = new YangResolutionInfoImpl<>(
leafRef, holder, getLineNumber(), getCharPosition());
curRefResolver.addToResolutionList(info, YANG_LEAFREF);
curRefResolver.resolveSelfFileLinking(YANG_LEAFREF);
}
代码示例来源:origin: org.onosproject/onos-yang-compiler-linker
/**
* Adds the unresolved entities to the resolution list.
*
* @param entityToResolve entity to resolve
* @throws DataModelException a violation of data model rules
*/
private void addUnresolvedEntitiesToResolutionList(T entityToResolve)
throws DataModelException {
if (entityToResolve instanceof YangEntityToResolveInfoImpl) {
YangEntityToResolveInfoImpl entityToResolveInfo
= (YangEntityToResolveInfoImpl) entityToResolve;
if (entityToResolveInfo.getEntityToResolve() instanceof YangLeafRef) {
YangLeafRef leafref = (YangLeafRef) entityToResolveInfo
.getEntityToResolve();
YangNode parentNodeOfLeafref = entityToResolveInfo
.getHolderOfEntityToResolve();
leafref.setParentNode(parentNodeOfLeafref);
if (leafref.getResolvableStatus() == UNRESOLVED) {
leafref.setResolvableStatus(INTRA_FILE_RESOLVED);
}
}
// Add resolution information to the list.
YangResolutionInfoImpl resolutionInfoImpl = new YangResolutionInfoImpl<>(
entityToResolveInfo.getEntityToResolve(),
entityToResolveInfo.getHolderOfEntityToResolve(),
entityToResolveInfo.getLineNumber(),
entityToResolveInfo.getCharPosition());
addResolutionInfo(resolutionInfoImpl);
}
}
我在一个模型中有两个属性: 叶协议(protocol), 离开港口。 我想说明: 如果 protocol = 'ssh' 则默认端口值为 22, 如果 protocol = 'http' 则默认端口值
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.YangIde
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev100924.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.YangIde
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.YangIde
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev100924.ZeroBas
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
本文整理了Java中org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.restconf.rev131019.yang.patc
我是一名优秀的程序员,十分优秀!