- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中org.onosproject.yangutils.datamodel.YangLeafRef
类的一些代码示例,展示了YangLeafRef
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YangLeafRef
类的具体详情如下:
包路径:org.onosproject.yangutils.datamodel.YangLeafRef
类名称:YangLeafRef
[英]Represents the leafref information.
[中]表示leafref信息。
代码示例来源:origin: org.onosproject/onos-yang-datamodel
/**
* Converts the prefixes in all the nodes of the leafref with respect to the uses node.
*
* @param leafrefForCloning leafref that is to be cloned
* @param yangUses instance of YANG uses where cloning is done
* @throws DataModelException data model error
*/
private static void convertThePrefixesDuringChange(YangLeafRef leafrefForCloning, YangUses yangUses)
throws DataModelException {
List<YangAtomicPath> atomicPathList = leafrefForCloning.getAtomicPath();
if (atomicPathList != null && !atomicPathList.isEmpty()) {
Iterator<YangAtomicPath> atomicPathIterator = atomicPathList.listIterator();
while (atomicPathIterator.hasNext()) {
YangAtomicPath atomicPath = atomicPathIterator.next();
Map<String, String> prefixesAndItsImportNameNode = leafrefForCloning.getPrefixAndNode();
String prefixInPath = atomicPath.getNodeIdentifier().getPrefix();
String importedNodeName = prefixesAndItsImportNameNode.get(prefixInPath);
assignCurrentLeafedWithNewPrefixes(importedNodeName, atomicPath, yangUses);
}
}
}
代码示例来源:origin: org.onosproject/onos-yang-datamodel
@Override
public Object resolve()
throws DataModelException {
if (getReferredLeafOrLeafList() == null) {
throw new DataModelException("Linker Error: The leafref does not refer to any leaf/leaf-list." +
" in " +
getLineNumber() + " at " +
getCharPosition() +
" in " + getFileName() + "\"");
}
// Initiate the resolution
try {
setResolvableStatus(getResolution());
} catch (DataModelException e) {
throw new DataModelException(e.getMessage());
}
return null;
}
代码示例来源:origin: org.onosproject/onos-yang-datamodel
if (getReferredLeafOrLeafList() instanceof YangLeaf) {
YangLeaf yangLeaf = ((YangLeaf) getReferredLeafOrLeafList());
YangType baseType = yangLeaf.getDataType();
if (referredLeafRefInfo.getResolvableStatus() != INTRA_FILE_RESOLVED
&& referredLeafRefInfo.getResolvableStatus() != RESOLVED) {
throw new DataModelException("Linker Error: Referred typedef is not resolved for type." +
" in " +
getLineNumber() + " at " +
getCharPosition() +
" in " + getFileName() + "\"");
if ((referredLeafRefInfo.getResolvableStatus() == INTRA_FILE_RESOLVED)) {
return INTRA_FILE_RESOLVED;
List<YangIfFeature> referredLeafIfFeatureListFromLeafref = referredLeafRefInfo.getIfFeatureList();
if (referredLeafIfFeatureListFromLeafref != null && !referredLeafIfFeatureListFromLeafref.isEmpty()) {
Iterator<YangIfFeature> referredLeafIfFeature = referredLeafIfFeatureListFromLeafref.iterator();
while (referredLeafIfFeature.hasNext()) {
YangIfFeature ifFeature = referredLeafIfFeature.next();
addIfFeatureList(ifFeature);
setEffectiveDataType(referredLeafRefInfo.getEffectiveDataType());
} else if (baseType.getDataType() == YangDataTypes.DERIVED) {
throw new DataModelException("Linker Error: Referred typedef is not resolved for type." +
" in " +
getLineNumber() + " at " +
getCharPosition() +
代码示例来源:origin: org.onosproject/onos-yang-utils-parser
YangLeafRef<?> leafRef = new YangLeafRef<>();
leafRef.setLineNumber(errorLine);
leafRef.setCharPosition(errorPosition);
leafRef.setFileName(listener.getFileName());
Parsable typeData = listener.getParsedDataStack().pop();
leafRef.setRequireInstance(true);
Parsable tmpData = listener.getParsedDataStack().peek();
leafRef.setResolvableStatus(UNRESOLVED);
leafRef.setParentNode((YangNode) parentNodeOfLeaf);
if (listener.getGroupingDepth() == 0) {
addToResolutionList(resolutionInfo);
} else {
leafRef.setInGrouping(true);
leafRef.setResolvableStatus(UNRESOLVED);
leafRef.setParentNode((YangNode) parentNodeOfLeafList);
addToResolutionList(resolutionInfoImpl);
} else {
leafRef.setInGrouping(true);
leafRef.setParentNode((YangNode) parentNodeOfLeafref);
if (listener.getGroupingDepth() != 0) {
leafRef.setInGrouping(true);
代码示例来源:origin: org.onosproject/onos-yang-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-utils-parser
YangLeafRef<?> leafRef) {
Map<String, String> prefixMap = leafRef.getPrefixAndNode();
if (prefixMap == null) {
prefixMap = new HashMap<>();
leafRef.setPrefixAndNode(prefixMap);
代码示例来源:origin: org.onosproject/onos-yang-datamodel
YangType type = ((YangLeafRef) dataType
.getDataTypeExtendedInfo())
.getEffectiveDataType();
if (type.getDataType() == YangDataTypes.DERIVED) {
return ((YangDerivedInfo) type.getDataTypeExtendedInfo())
.getEffectiveDataType().getDataType().equals(EMPTY);
本文整理了Java中org.batfish.datamodel.Zone类的一些代码示例,展示了Zone类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,
我似乎无法将文本数据(例如 CSV、JSON 或 XML 文件)添加到 Roblox DataModel 、Workspace、ServerStorage 还是任何地方? 关于如何高效执行此操作的任何
我有一个用位置更新创建的数据库,数据库中有一堆位置 x 和 y。在第二种方法中,readFirestore() 读取位置数据并比较来自 sqlite 数据库的最喜欢的位置,如果最喜欢的位置靠近来自 f
本文整理了Java中org.onosproject.yangutils.datamodel.YangReferenceResolver类的一些代码示例,展示了YangReferenceResolver
本文整理了Java中org.onosproject.yangutils.datamodel.YangNode类的一些代码示例,展示了YangNode类的具体用法。这些代码示例主要来源于Github/S
本文整理了Java中org.onosproject.yangutils.datamodel.YangUnion类的一些代码示例,展示了YangUnion类的具体用法。这些代码示例主要来源于Github
本文整理了Java中org.onosproject.yangutils.datamodel.YangTypeDef类的一些代码示例,展示了YangTypeDef类的具体用法。这些代码示例主要来源于Gi
本文整理了Java中org.onosproject.yangutils.datamodel.YangType类的一些代码示例,展示了YangType类的具体用法。这些代码示例主要来源于Github/S
本文整理了Java中org.onosproject.yangutils.datamodel.YangSubModule类的一些代码示例,展示了YangSubModule类的具体用法。这些代码示例主要来
本文整理了Java中org.onosproject.yangutils.datamodel.YangRevision类的一些代码示例,展示了YangRevision类的具体用法。这些代码示例主要来源于
本文整理了Java中org.onosproject.yangutils.datamodel.YangRpc类的一些代码示例,展示了YangRpc类的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中org.onosproject.yangutils.datamodel.YangPatternRestriction类的一些代码示例,展示了YangPatternRestricti
本文整理了Java中org.onosproject.yangutils.datamodel.YangStringRestriction类的一些代码示例,展示了YangStringRestriction
本文整理了Java中org.onosproject.yangutils.datamodel.YangFeature类的一些代码示例,展示了YangFeature类的具体用法。这些代码示例主要来源于Gi
本文整理了Java中org.onosproject.yangutils.datamodel.YangLeafRef类的一些代码示例,展示了YangLeafRef类的具体用法。这些代码示例主要来源于Gi
本文整理了Java中org.onosproject.yangutils.datamodel.YangLeafList类的一些代码示例,展示了YangLeafList类的具体用法。这些代码示例主要来源于
本文整理了Java中org.onosproject.yangutils.datamodel.YangLeaf类的一些代码示例,展示了YangLeaf类的具体用法。这些代码示例主要来源于Github/S
本文整理了Java中org.onosproject.yangutils.datamodel.YangList类的一些代码示例,展示了YangList类的具体用法。这些代码示例主要来源于Github/S
本文整理了Java中org.onosproject.yangutils.datamodel.YangNodeIdentifier类的一些代码示例,展示了YangNodeIdentifier类的具体用法
本文整理了Java中org.onosproject.yangutils.datamodel.YangAugment类的一些代码示例,展示了YangAugment类的具体用法。这些代码示例主要来源于Gi
我是一名优秀的程序员,十分优秀!