Exemplo n.º 1
0
    @Override
    public Void visitConstructorDescriptor(
        ConstructorDescriptor constructorDescriptor, StringBuilder builder) {
      renderVisibility(constructorDescriptor.getVisibility(), builder);

      builder.append(renderKeyword("ctor")).append(" ");

      ClassDescriptor classDescriptor = constructorDescriptor.getContainingDeclaration();
      builder.append(classDescriptor.getName());

      renderTypeParameters(classDescriptor.getTypeConstructor().getParameters(), builder);
      renderValueParameters(constructorDescriptor, builder);
      return null;
    }
Exemplo n.º 2
0
  private void renderConstructor(
      @NotNull ConstructorDescriptor constructor, @NotNull StringBuilder builder) {
    renderAnnotations(constructor, builder);
    renderVisibility(constructor.getVisibility(), builder);
    renderMemberKind(constructor, builder);

    builder.append(renderKeyword("constructor")).append(" ");

    ClassDescriptor classDescriptor = constructor.getContainingDeclaration();
    renderName(classDescriptor, builder);

    renderTypeParameters(classDescriptor.getTypeConstructor().getParameters(), builder, false);
    renderValueParameters(constructor, builder);
    renderWhereSuffix(constructor.getTypeParameters(), builder);
  }