com.squareup.javapoet.ClassName.emit()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(2.3k)|赞(0)|评价(0)|浏览(127)

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

ClassName.emit介绍

暂无

代码示例

代码示例来源:origin: square/javapoet

deferredTypeName.emit(this);
deferredTypeName = null;

代码示例来源:origin: io.virtdata/virtdata-lib-realer

@Override CodeWriter emit(CodeWriter out) throws IOException {
 if (enclosingType != null) {
  enclosingType.emitAnnotations(out);
  enclosingType.emit(out);
  out.emit("." + rawType.simpleName());
 } else {
  rawType.emitAnnotations(out);
  rawType.emit(out);
 }
 if (!typeArguments.isEmpty()) {
  out.emitAndIndent("<");
  boolean firstParameter = true;
  for (TypeName parameter : typeArguments) {
   if (!firstParameter) out.emitAndIndent(", ");
   parameter.emitAnnotations(out);
   parameter.emit(out);
   firstParameter = false;
  }
  out.emitAndIndent(">");
 }
 return out;
}

代码示例来源:origin: xiaoxiangyeyuHeaven/JD-shopping-mall

@Override CodeWriter emit(CodeWriter out) throws IOException {
 if (enclosingType != null) {
  enclosingType.emitAnnotations(out);
  enclosingType.emit(out);
  out.emit("." + rawType.simpleName());
 } else {
  rawType.emitAnnotations(out);
  rawType.emit(out);
 }
 if (!typeArguments.isEmpty()) {
  out.emitAndIndent("<");
  boolean firstParameter = true;
  for (TypeName parameter : typeArguments) {
   if (!firstParameter) out.emitAndIndent(", ");
   parameter.emitAnnotations(out);
   parameter.emit(out);
   firstParameter = false;
  }
  out.emitAndIndent(">");
 }
 return out;
}

代码示例来源:origin: square/javapoet

@Override CodeWriter emit(CodeWriter out) throws IOException {
 if (enclosingType != null) {
  enclosingType.emit(out);
  out.emit(".");
  if (isAnnotated()) {
   out.emit(" ");
   emitAnnotations(out);
  }
  out.emit(rawType.simpleName());
 } else {
  rawType.emit(out);
 }
 if (!typeArguments.isEmpty()) {
  out.emitAndIndent("<");
  boolean firstParameter = true;
  for (TypeName parameter : typeArguments) {
   if (!firstParameter) out.emitAndIndent(", ");
   parameter.emit(out);
   firstParameter = false;
  }
  out.emitAndIndent(">");
 }
 return out;
}

代码示例来源:origin: io.virtdata/virtdata-lib-realer

deferredTypeName.emit(this);
deferredTypeName = null;

代码示例来源:origin: xiaoxiangyeyuHeaven/JD-shopping-mall

deferredTypeName.emit(this);
deferredTypeName = null;

相关文章