gpt4 book ai didi

org.onosproject.yang.compiler.utils.io.impl.YangIoUtils.getCapitalCase()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-13 22:00:03 26 4
gpt4 key购买 nike

本文整理了Java中org.onosproject.yang.compiler.utils.io.impl.YangIoUtils.getCapitalCase()方法的一些代码示例,展示了YangIoUtils.getCapitalCase()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YangIoUtils.getCapitalCase()方法的具体详情如下:
包路径:org.onosproject.yang.compiler.utils.io.impl.YangIoUtils
类名称:YangIoUtils
方法名:getCapitalCase

YangIoUtils.getCapitalCase介绍

[英]Returns the YANG identifier name as java identifier with first letter in capital.
[中]返回首字母大写的java标识符名称。

代码示例

代码示例来源:origin: org.onosproject/onos-yang-compiler-utils

if (compilerAnnotation != null) {
  compilerAnnotation = compilerAnnotation.toLowerCase();
  compilerAnnotation = getCapitalCase(compilerAnnotation);
  switch (compilerAnnotation) {
    case QUEUE: {

代码示例来源:origin: org.onosproject/onos-yang-runtime-uils

/**
 * Returns schema node's generated interface class name.
 *
 * @param schemaNode schema node
 * @return schema node's generated interface class name
 */
public static String getInterfaceClassName(YangSchemaNode schemaNode) {
  return schemaNode.getJavaPackage() + PERIOD +
      getCapitalCase(schemaNode.getJavaClassNameOrBuiltInType());
}

代码示例来源:origin: org.onosproject/onos-yang-compiler-utils

/**
 * Returns javaDocs for add to list method.
 *
 * @param attribute  attribute
 * @param annotation compile annotation
 * @return javaDocs
 */
private static String generateForAddToList(String attribute, String annotation) {
  StringBuilder javadoc = new StringBuilder();
  javadoc.append(getJavaDocStartLine(attribute, JAVA_DOC_ADD_TO_LIST))
      .append(getJavaDocEmptyAsteriskLine());
  if (annotation != null) {
    annotation = annotation.toLowerCase();
    annotation = getCapitalCase(annotation);
    switch (annotation) {
      case MAP:
        javadoc.append(getJavaDocParamLine(
            attribute, attribute + KEYS)).append(getJavaDocParamLine(
            attribute, attribute + VALUE_CAPS));
        break;
      default:
        javadoc.append(getJavaDocParamLine(
            attribute, ADD_STRING + TO_CAPS));
        break;
    }
  }
  javadoc.append(getJavaDocParamLine(attribute, ADD_STRING + TO_CAPS))
      .append(getJavaDocEndLine());
  return javadoc.toString();
}

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com