コード例 #1
0
 /**
  * <code>required .dossier.Index index = 3;</code>
  *
  * <pre>
  * Navigation index.
  * </pre>
  */
 public Builder mergeIndex(com.github.jsdossier.proto.Index value) {
   if (indexBuilder_ == null) {
     if (((bitField0_ & 0x00000004) == 0x00000004)
         && index_ != com.github.jsdossier.proto.Index.getDefaultInstance()) {
       index_ =
           com.github.jsdossier.proto.Index.newBuilder(index_).mergeFrom(value).buildPartial();
     } else {
       index_ = value;
     }
     onChanged();
   } else {
     indexBuilder_.mergeFrom(value);
   }
   bitField0_ |= 0x00000004;
   return this;
 }
コード例 #2
0
 /**
  * <code>required .dossier.Index index = 3;</code>
  *
  * <pre>
  * Navigation index.
  * </pre>
  */
 public Builder clearIndex() {
   if (indexBuilder_ == null) {
     index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
     onChanged();
   } else {
     indexBuilder_.clear();
   }
   bitField0_ = (bitField0_ & ~0x00000004);
   return this;
 }
コード例 #3
0
 public Builder clear() {
   super.clear();
   if (typeBuilder_ == null) {
     type_ = java.util.Collections.emptyList();
     bitField0_ = (bitField0_ & ~0x00000001);
   } else {
     typeBuilder_.clear();
   }
   if (resourcesBuilder_ == null) {
     resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
   } else {
     resourcesBuilder_.clear();
   }
   bitField0_ = (bitField0_ & ~0x00000002);
   if (indexBuilder_ == null) {
     index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
   } else {
     indexBuilder_.clear();
   }
   bitField0_ = (bitField0_ & ~0x00000004);
   return this;
 }
コード例 #4
0
 public Builder clear() {
   super.clear();
   if (resourcesBuilder_ == null) {
     resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
   } else {
     resourcesBuilder_.clear();
   }
   bitField0_ = (bitField0_ & ~0x00000001);
   title_ = "";
   bitField0_ = (bitField0_ & ~0x00000002);
   if (contentBuilder_ == null) {
     content_ = com.github.jsdossier.proto.Comment.getDefaultInstance();
   } else {
     contentBuilder_.clear();
   }
   bitField0_ = (bitField0_ & ~0x00000004);
   if (indexBuilder_ == null) {
     index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
   } else {
     indexBuilder_.clear();
   }
   bitField0_ = (bitField0_ & ~0x00000008);
   return this;
 }
コード例 #5
0
  /**
   * Protobuf type {@code dossier.JsTypeRenderSpec}
   *
   * <pre>
   * Describes how to render documentation for a JavaScript type.
   * </pre>
   */
  public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder<Builder>
      implements
      // @@protoc_insertion_point(builder_implements:dossier.JsTypeRenderSpec)
      com.github.jsdossier.proto.JsTypeRenderSpecOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
      return com.github.jsdossier.proto.Dossier.internal_static_dossier_JsTypeRenderSpec_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.github.jsdossier.proto.Dossier
          .internal_static_dossier_JsTypeRenderSpec_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.github.jsdossier.proto.JsTypeRenderSpec.class,
              com.github.jsdossier.proto.JsTypeRenderSpec.Builder.class);
    }

    // Construct using com.github.jsdossier.proto.JsTypeRenderSpec.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }

    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        getTypeFieldBuilder();
        getResourcesFieldBuilder();
        getIndexFieldBuilder();
      }
    }

    private static Builder create() {
      return new Builder();
    }

    public Builder clear() {
      super.clear();
      if (typeBuilder_ == null) {
        type_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000001);
      } else {
        typeBuilder_.clear();
      }
      if (resourcesBuilder_ == null) {
        resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
      } else {
        resourcesBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000002);
      if (indexBuilder_ == null) {
        index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
      } else {
        indexBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000004);
      return this;
    }

    public Builder clone() {
      return create().mergeFrom(buildPartial());
    }

    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
      return com.github.jsdossier.proto.Dossier.internal_static_dossier_JsTypeRenderSpec_descriptor;
    }

    public com.github.jsdossier.proto.JsTypeRenderSpec getDefaultInstanceForType() {
      return com.github.jsdossier.proto.JsTypeRenderSpec.getDefaultInstance();
    }

    public com.github.jsdossier.proto.JsTypeRenderSpec build() {
      com.github.jsdossier.proto.JsTypeRenderSpec result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    public com.github.jsdossier.proto.JsTypeRenderSpec buildPartial() {
      com.github.jsdossier.proto.JsTypeRenderSpec result =
          new com.github.jsdossier.proto.JsTypeRenderSpec(this);
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      if (typeBuilder_ == null) {
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          type_ = java.util.Collections.unmodifiableList(type_);
          bitField0_ = (bitField0_ & ~0x00000001);
        }
        result.type_ = type_;
      } else {
        result.type_ = typeBuilder_.build();
      }
      if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
        to_bitField0_ |= 0x00000001;
      }
      if (resourcesBuilder_ == null) {
        result.resources_ = resources_;
      } else {
        result.resources_ = resourcesBuilder_.build();
      }
      if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
        to_bitField0_ |= 0x00000002;
      }
      if (indexBuilder_ == null) {
        result.index_ = index_;
      } else {
        result.index_ = indexBuilder_.build();
      }
      result.bitField0_ = to_bitField0_;
      onBuilt();
      return result;
    }

    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.github.jsdossier.proto.JsTypeRenderSpec) {
        return mergeFrom((com.github.jsdossier.proto.JsTypeRenderSpec) other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.github.jsdossier.proto.JsTypeRenderSpec other) {
      if (other == com.github.jsdossier.proto.JsTypeRenderSpec.getDefaultInstance()) return this;
      if (typeBuilder_ == null) {
        if (!other.type_.isEmpty()) {
          if (type_.isEmpty()) {
            type_ = other.type_;
            bitField0_ = (bitField0_ & ~0x00000001);
          } else {
            ensureTypeIsMutable();
            type_.addAll(other.type_);
          }
          onChanged();
        }
      } else {
        if (!other.type_.isEmpty()) {
          if (typeBuilder_.isEmpty()) {
            typeBuilder_.dispose();
            typeBuilder_ = null;
            type_ = other.type_;
            bitField0_ = (bitField0_ & ~0x00000001);
            typeBuilder_ =
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders
                    ? getTypeFieldBuilder()
                    : null;
          } else {
            typeBuilder_.addAllMessages(other.type_);
          }
        }
      }
      if (other.hasResources()) {
        mergeResources(other.getResources());
      }
      if (other.hasIndex()) {
        mergeIndex(other.getIndex());
      }
      this.mergeUnknownFields(other.getUnknownFields());
      return this;
    }

    public final boolean isInitialized() {
      if (!hasResources()) {

        return false;
      }
      if (!hasIndex()) {

        return false;
      }
      for (int i = 0; i < getTypeCount(); i++) {
        if (!getType(i).isInitialized()) {

          return false;
        }
      }
      if (!getIndex().isInitialized()) {

        return false;
      }
      return true;
    }

    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      com.github.jsdossier.proto.JsTypeRenderSpec parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.github.jsdossier.proto.JsTypeRenderSpec) e.getUnfinishedMessage();
        throw e;
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }

    private int bitField0_;

    private java.util.List<com.github.jsdossier.proto.JsType> type_ =
        java.util.Collections.emptyList();

    private void ensureTypeIsMutable() {
      if (!((bitField0_ & 0x00000001) == 0x00000001)) {
        type_ = new java.util.ArrayList<com.github.jsdossier.proto.JsType>(type_);
        bitField0_ |= 0x00000001;
      }
    }

    private com.google.protobuf.RepeatedFieldBuilder<
            com.github.jsdossier.proto.JsType,
            com.github.jsdossier.proto.JsType.Builder,
            com.github.jsdossier.proto.JsTypeOrBuilder>
        typeBuilder_;

    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public java.util.List<com.github.jsdossier.proto.JsType> getTypeList() {
      if (typeBuilder_ == null) {
        return java.util.Collections.unmodifiableList(type_);
      } else {
        return typeBuilder_.getMessageList();
      }
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public int getTypeCount() {
      if (typeBuilder_ == null) {
        return type_.size();
      } else {
        return typeBuilder_.getCount();
      }
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public com.github.jsdossier.proto.JsType getType(int index) {
      if (typeBuilder_ == null) {
        return type_.get(index);
      } else {
        return typeBuilder_.getMessage(index);
      }
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder setType(int index, com.github.jsdossier.proto.JsType value) {
      if (typeBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureTypeIsMutable();
        type_.set(index, value);
        onChanged();
      } else {
        typeBuilder_.setMessage(index, value);
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder setType(int index, com.github.jsdossier.proto.JsType.Builder builderForValue) {
      if (typeBuilder_ == null) {
        ensureTypeIsMutable();
        type_.set(index, builderForValue.build());
        onChanged();
      } else {
        typeBuilder_.setMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder addType(com.github.jsdossier.proto.JsType value) {
      if (typeBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureTypeIsMutable();
        type_.add(value);
        onChanged();
      } else {
        typeBuilder_.addMessage(value);
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder addType(int index, com.github.jsdossier.proto.JsType value) {
      if (typeBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureTypeIsMutable();
        type_.add(index, value);
        onChanged();
      } else {
        typeBuilder_.addMessage(index, value);
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder addType(com.github.jsdossier.proto.JsType.Builder builderForValue) {
      if (typeBuilder_ == null) {
        ensureTypeIsMutable();
        type_.add(builderForValue.build());
        onChanged();
      } else {
        typeBuilder_.addMessage(builderForValue.build());
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder addType(int index, com.github.jsdossier.proto.JsType.Builder builderForValue) {
      if (typeBuilder_ == null) {
        ensureTypeIsMutable();
        type_.add(index, builderForValue.build());
        onChanged();
      } else {
        typeBuilder_.addMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder addAllType(
        java.lang.Iterable<? extends com.github.jsdossier.proto.JsType> values) {
      if (typeBuilder_ == null) {
        ensureTypeIsMutable();
        com.google.protobuf.AbstractMessageLite.Builder.addAll(values, type_);
        onChanged();
      } else {
        typeBuilder_.addAllMessages(values);
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder clearType() {
      if (typeBuilder_ == null) {
        type_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000001);
        onChanged();
      } else {
        typeBuilder_.clear();
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public Builder removeType(int index) {
      if (typeBuilder_ == null) {
        ensureTypeIsMutable();
        type_.remove(index);
        onChanged();
      } else {
        typeBuilder_.remove(index);
      }
      return this;
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public com.github.jsdossier.proto.JsType.Builder getTypeBuilder(int index) {
      return getTypeFieldBuilder().getBuilder(index);
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public com.github.jsdossier.proto.JsTypeOrBuilder getTypeOrBuilder(int index) {
      if (typeBuilder_ == null) {
        return type_.get(index);
      } else {
        return typeBuilder_.getMessageOrBuilder(index);
      }
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public java.util.List<? extends com.github.jsdossier.proto.JsTypeOrBuilder>
        getTypeOrBuilderList() {
      if (typeBuilder_ != null) {
        return typeBuilder_.getMessageOrBuilderList();
      } else {
        return java.util.Collections.unmodifiableList(type_);
      }
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public com.github.jsdossier.proto.JsType.Builder addTypeBuilder() {
      return getTypeFieldBuilder()
          .addBuilder(com.github.jsdossier.proto.JsType.getDefaultInstance());
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public com.github.jsdossier.proto.JsType.Builder addTypeBuilder(int index) {
      return getTypeFieldBuilder()
          .addBuilder(index, com.github.jsdossier.proto.JsType.getDefaultInstance());
    }
    /**
     * <code>repeated .dossier.JsType type = 1;</code>
     *
     * <pre>
     * The types to generate documentation for.
     * </pre>
     */
    public java.util.List<com.github.jsdossier.proto.JsType.Builder> getTypeBuilderList() {
      return getTypeFieldBuilder().getBuilderList();
    }

    private com.google.protobuf.RepeatedFieldBuilder<
            com.github.jsdossier.proto.JsType,
            com.github.jsdossier.proto.JsType.Builder,
            com.github.jsdossier.proto.JsTypeOrBuilder>
        getTypeFieldBuilder() {
      if (typeBuilder_ == null) {
        typeBuilder_ =
            new com.google.protobuf.RepeatedFieldBuilder<
                com.github.jsdossier.proto.JsType,
                com.github.jsdossier.proto.JsType.Builder,
                com.github.jsdossier.proto.JsTypeOrBuilder>(
                type_,
                ((bitField0_ & 0x00000001) == 0x00000001),
                getParentForChildren(),
                isClean());
        type_ = null;
      }
      return typeBuilder_;
    }

    private com.github.jsdossier.proto.Resources resources_ =
        com.github.jsdossier.proto.Resources.getDefaultInstance();
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Resources,
            com.github.jsdossier.proto.Resources.Builder,
            com.github.jsdossier.proto.ResourcesOrBuilder>
        resourcesBuilder_;
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public boolean hasResources() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public com.github.jsdossier.proto.Resources getResources() {
      if (resourcesBuilder_ == null) {
        return resources_;
      } else {
        return resourcesBuilder_.getMessage();
      }
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder setResources(com.github.jsdossier.proto.Resources value) {
      if (resourcesBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        resources_ = value;
        onChanged();
      } else {
        resourcesBuilder_.setMessage(value);
      }
      bitField0_ |= 0x00000002;
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder setResources(com.github.jsdossier.proto.Resources.Builder builderForValue) {
      if (resourcesBuilder_ == null) {
        resources_ = builderForValue.build();
        onChanged();
      } else {
        resourcesBuilder_.setMessage(builderForValue.build());
      }
      bitField0_ |= 0x00000002;
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder mergeResources(com.github.jsdossier.proto.Resources value) {
      if (resourcesBuilder_ == null) {
        if (((bitField0_ & 0x00000002) == 0x00000002)
            && resources_ != com.github.jsdossier.proto.Resources.getDefaultInstance()) {
          resources_ =
              com.github.jsdossier.proto.Resources.newBuilder(resources_)
                  .mergeFrom(value)
                  .buildPartial();
        } else {
          resources_ = value;
        }
        onChanged();
      } else {
        resourcesBuilder_.mergeFrom(value);
      }
      bitField0_ |= 0x00000002;
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder clearResources() {
      if (resourcesBuilder_ == null) {
        resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
        onChanged();
      } else {
        resourcesBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000002);
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public com.github.jsdossier.proto.Resources.Builder getResourcesBuilder() {
      bitField0_ |= 0x00000002;
      onChanged();
      return getResourcesFieldBuilder().getBuilder();
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public com.github.jsdossier.proto.ResourcesOrBuilder getResourcesOrBuilder() {
      if (resourcesBuilder_ != null) {
        return resourcesBuilder_.getMessageOrBuilder();
      } else {
        return resources_;
      }
    }
    /**
     * <code>required .dossier.Resources resources = 2;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Resources,
            com.github.jsdossier.proto.Resources.Builder,
            com.github.jsdossier.proto.ResourcesOrBuilder>
        getResourcesFieldBuilder() {
      if (resourcesBuilder_ == null) {
        resourcesBuilder_ =
            new com.google.protobuf.SingleFieldBuilder<
                com.github.jsdossier.proto.Resources,
                com.github.jsdossier.proto.Resources.Builder,
                com.github.jsdossier.proto.ResourcesOrBuilder>(
                getResources(), getParentForChildren(), isClean());
        resources_ = null;
      }
      return resourcesBuilder_;
    }

    private com.github.jsdossier.proto.Index index_ =
        com.github.jsdossier.proto.Index.getDefaultInstance();
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Index,
            com.github.jsdossier.proto.Index.Builder,
            com.github.jsdossier.proto.IndexOrBuilder>
        indexBuilder_;
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public boolean hasIndex() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public com.github.jsdossier.proto.Index getIndex() {
      if (indexBuilder_ == null) {
        return index_;
      } else {
        return indexBuilder_.getMessage();
      }
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder setIndex(com.github.jsdossier.proto.Index value) {
      if (indexBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        index_ = value;
        onChanged();
      } else {
        indexBuilder_.setMessage(value);
      }
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder setIndex(com.github.jsdossier.proto.Index.Builder builderForValue) {
      if (indexBuilder_ == null) {
        index_ = builderForValue.build();
        onChanged();
      } else {
        indexBuilder_.setMessage(builderForValue.build());
      }
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder mergeIndex(com.github.jsdossier.proto.Index value) {
      if (indexBuilder_ == null) {
        if (((bitField0_ & 0x00000004) == 0x00000004)
            && index_ != com.github.jsdossier.proto.Index.getDefaultInstance()) {
          index_ =
              com.github.jsdossier.proto.Index.newBuilder(index_).mergeFrom(value).buildPartial();
        } else {
          index_ = value;
        }
        onChanged();
      } else {
        indexBuilder_.mergeFrom(value);
      }
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder clearIndex() {
      if (indexBuilder_ == null) {
        index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
        onChanged();
      } else {
        indexBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000004);
      return this;
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public com.github.jsdossier.proto.Index.Builder getIndexBuilder() {
      bitField0_ |= 0x00000004;
      onChanged();
      return getIndexFieldBuilder().getBuilder();
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public com.github.jsdossier.proto.IndexOrBuilder getIndexOrBuilder() {
      if (indexBuilder_ != null) {
        return indexBuilder_.getMessageOrBuilder();
      } else {
        return index_;
      }
    }
    /**
     * <code>required .dossier.Index index = 3;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Index,
            com.github.jsdossier.proto.Index.Builder,
            com.github.jsdossier.proto.IndexOrBuilder>
        getIndexFieldBuilder() {
      if (indexBuilder_ == null) {
        indexBuilder_ =
            new com.google.protobuf.SingleFieldBuilder<
                com.github.jsdossier.proto.Index,
                com.github.jsdossier.proto.Index.Builder,
                com.github.jsdossier.proto.IndexOrBuilder>(
                getIndex(), getParentForChildren(), isClean());
        index_ = null;
      }
      return indexBuilder_;
    }

    // @@protoc_insertion_point(builder_scope:dossier.JsTypeRenderSpec)
  }
コード例 #6
0
 private void initFields() {
   type_ = java.util.Collections.emptyList();
   resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
   index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
 }
コード例 #7
0
  /**
   * Protobuf type {@code dossier.HtmlRenderSpec}
   *
   * <pre>
   * Describes how to render a generic HTML page.
   * </pre>
   */
  public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder<Builder>
      implements
      // @@protoc_insertion_point(builder_implements:dossier.HtmlRenderSpec)
      com.github.jsdossier.proto.HtmlRenderSpecOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
      return com.github.jsdossier.proto.Dossier.internal_static_dossier_HtmlRenderSpec_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.github.jsdossier.proto.Dossier
          .internal_static_dossier_HtmlRenderSpec_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.github.jsdossier.proto.HtmlRenderSpec.class,
              com.github.jsdossier.proto.HtmlRenderSpec.Builder.class);
    }

    // Construct using com.github.jsdossier.proto.HtmlRenderSpec.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }

    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        getResourcesFieldBuilder();
        getContentFieldBuilder();
        getIndexFieldBuilder();
      }
    }

    private static Builder create() {
      return new Builder();
    }

    public Builder clear() {
      super.clear();
      if (resourcesBuilder_ == null) {
        resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
      } else {
        resourcesBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000001);
      title_ = "";
      bitField0_ = (bitField0_ & ~0x00000002);
      if (contentBuilder_ == null) {
        content_ = com.github.jsdossier.proto.Comment.getDefaultInstance();
      } else {
        contentBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000004);
      if (indexBuilder_ == null) {
        index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
      } else {
        indexBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000008);
      return this;
    }

    public Builder clone() {
      return create().mergeFrom(buildPartial());
    }

    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
      return com.github.jsdossier.proto.Dossier.internal_static_dossier_HtmlRenderSpec_descriptor;
    }

    public com.github.jsdossier.proto.HtmlRenderSpec getDefaultInstanceForType() {
      return com.github.jsdossier.proto.HtmlRenderSpec.getDefaultInstance();
    }

    public com.github.jsdossier.proto.HtmlRenderSpec build() {
      com.github.jsdossier.proto.HtmlRenderSpec result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    public com.github.jsdossier.proto.HtmlRenderSpec buildPartial() {
      com.github.jsdossier.proto.HtmlRenderSpec result =
          new com.github.jsdossier.proto.HtmlRenderSpec(this);
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
        to_bitField0_ |= 0x00000001;
      }
      if (resourcesBuilder_ == null) {
        result.resources_ = resources_;
      } else {
        result.resources_ = resourcesBuilder_.build();
      }
      if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
        to_bitField0_ |= 0x00000002;
      }
      result.title_ = title_;
      if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
        to_bitField0_ |= 0x00000004;
      }
      if (contentBuilder_ == null) {
        result.content_ = content_;
      } else {
        result.content_ = contentBuilder_.build();
      }
      if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
        to_bitField0_ |= 0x00000008;
      }
      if (indexBuilder_ == null) {
        result.index_ = index_;
      } else {
        result.index_ = indexBuilder_.build();
      }
      result.bitField0_ = to_bitField0_;
      onBuilt();
      return result;
    }

    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.github.jsdossier.proto.HtmlRenderSpec) {
        return mergeFrom((com.github.jsdossier.proto.HtmlRenderSpec) other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.github.jsdossier.proto.HtmlRenderSpec other) {
      if (other == com.github.jsdossier.proto.HtmlRenderSpec.getDefaultInstance()) return this;
      if (other.hasResources()) {
        mergeResources(other.getResources());
      }
      if (other.hasTitle()) {
        bitField0_ |= 0x00000002;
        title_ = other.title_;
        onChanged();
      }
      if (other.hasContent()) {
        mergeContent(other.getContent());
      }
      if (other.hasIndex()) {
        mergeIndex(other.getIndex());
      }
      this.mergeUnknownFields(other.getUnknownFields());
      return this;
    }

    public final boolean isInitialized() {
      if (!hasResources()) {

        return false;
      }
      if (!hasTitle()) {

        return false;
      }
      if (!hasIndex()) {

        return false;
      }
      if (!getIndex().isInitialized()) {

        return false;
      }
      return true;
    }

    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      com.github.jsdossier.proto.HtmlRenderSpec parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.github.jsdossier.proto.HtmlRenderSpec) e.getUnfinishedMessage();
        throw e;
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }

    private int bitField0_;

    private com.github.jsdossier.proto.Resources resources_ =
        com.github.jsdossier.proto.Resources.getDefaultInstance();
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Resources,
            com.github.jsdossier.proto.Resources.Builder,
            com.github.jsdossier.proto.ResourcesOrBuilder>
        resourcesBuilder_;
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public boolean hasResources() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public com.github.jsdossier.proto.Resources getResources() {
      if (resourcesBuilder_ == null) {
        return resources_;
      } else {
        return resourcesBuilder_.getMessage();
      }
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder setResources(com.github.jsdossier.proto.Resources value) {
      if (resourcesBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        resources_ = value;
        onChanged();
      } else {
        resourcesBuilder_.setMessage(value);
      }
      bitField0_ |= 0x00000001;
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder setResources(com.github.jsdossier.proto.Resources.Builder builderForValue) {
      if (resourcesBuilder_ == null) {
        resources_ = builderForValue.build();
        onChanged();
      } else {
        resourcesBuilder_.setMessage(builderForValue.build());
      }
      bitField0_ |= 0x00000001;
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder mergeResources(com.github.jsdossier.proto.Resources value) {
      if (resourcesBuilder_ == null) {
        if (((bitField0_ & 0x00000001) == 0x00000001)
            && resources_ != com.github.jsdossier.proto.Resources.getDefaultInstance()) {
          resources_ =
              com.github.jsdossier.proto.Resources.newBuilder(resources_)
                  .mergeFrom(value)
                  .buildPartial();
        } else {
          resources_ = value;
        }
        onChanged();
      } else {
        resourcesBuilder_.mergeFrom(value);
      }
      bitField0_ |= 0x00000001;
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public Builder clearResources() {
      if (resourcesBuilder_ == null) {
        resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
        onChanged();
      } else {
        resourcesBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000001);
      return this;
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public com.github.jsdossier.proto.Resources.Builder getResourcesBuilder() {
      bitField0_ |= 0x00000001;
      onChanged();
      return getResourcesFieldBuilder().getBuilder();
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    public com.github.jsdossier.proto.ResourcesOrBuilder getResourcesOrBuilder() {
      if (resourcesBuilder_ != null) {
        return resourcesBuilder_.getMessageOrBuilder();
      } else {
        return resources_;
      }
    }
    /**
     * <code>required .dossier.Resources resources = 1;</code>
     *
     * <pre>
     * The resources to include.
     * </pre>
     */
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Resources,
            com.github.jsdossier.proto.Resources.Builder,
            com.github.jsdossier.proto.ResourcesOrBuilder>
        getResourcesFieldBuilder() {
      if (resourcesBuilder_ == null) {
        resourcesBuilder_ =
            new com.google.protobuf.SingleFieldBuilder<
                com.github.jsdossier.proto.Resources,
                com.github.jsdossier.proto.Resources.Builder,
                com.github.jsdossier.proto.ResourcesOrBuilder>(
                getResources(), getParentForChildren(), isClean());
        resources_ = null;
      }
      return resourcesBuilder_;
    }

    private java.lang.Object title_ = "";
    /**
     * <code>required string title = 2;</code>
     *
     * <pre>
     * The page title.
     * </pre>
     */
    public boolean hasTitle() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required string title = 2;</code>
     *
     * <pre>
     * The page title.
     * </pre>
     */
    public java.lang.String getTitle() {
      java.lang.Object ref = title_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          title_ = s;
        }
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <code>required string title = 2;</code>
     *
     * <pre>
     * The page title.
     * </pre>
     */
    public com.google.protobuf.ByteString getTitleBytes() {
      java.lang.Object ref = title_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        title_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <code>required string title = 2;</code>
     *
     * <pre>
     * The page title.
     * </pre>
     */
    public Builder setTitle(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }
      bitField0_ |= 0x00000002;
      title_ = value;
      onChanged();
      return this;
    }
    /**
     * <code>required string title = 2;</code>
     *
     * <pre>
     * The page title.
     * </pre>
     */
    public Builder clearTitle() {
      bitField0_ = (bitField0_ & ~0x00000002);
      title_ = getDefaultInstance().getTitle();
      onChanged();
      return this;
    }
    /**
     * <code>required string title = 2;</code>
     *
     * <pre>
     * The page title.
     * </pre>
     */
    public Builder setTitleBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      bitField0_ |= 0x00000002;
      title_ = value;
      onChanged();
      return this;
    }

    private com.github.jsdossier.proto.Comment content_ =
        com.github.jsdossier.proto.Comment.getDefaultInstance();
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Comment,
            com.github.jsdossier.proto.Comment.Builder,
            com.github.jsdossier.proto.CommentOrBuilder>
        contentBuilder_;
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public boolean hasContent() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public com.github.jsdossier.proto.Comment getContent() {
      if (contentBuilder_ == null) {
        return content_;
      } else {
        return contentBuilder_.getMessage();
      }
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public Builder setContent(com.github.jsdossier.proto.Comment value) {
      if (contentBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        content_ = value;
        onChanged();
      } else {
        contentBuilder_.setMessage(value);
      }
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public Builder setContent(com.github.jsdossier.proto.Comment.Builder builderForValue) {
      if (contentBuilder_ == null) {
        content_ = builderForValue.build();
        onChanged();
      } else {
        contentBuilder_.setMessage(builderForValue.build());
      }
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public Builder mergeContent(com.github.jsdossier.proto.Comment value) {
      if (contentBuilder_ == null) {
        if (((bitField0_ & 0x00000004) == 0x00000004)
            && content_ != com.github.jsdossier.proto.Comment.getDefaultInstance()) {
          content_ =
              com.github.jsdossier.proto.Comment.newBuilder(content_)
                  .mergeFrom(value)
                  .buildPartial();
        } else {
          content_ = value;
        }
        onChanged();
      } else {
        contentBuilder_.mergeFrom(value);
      }
      bitField0_ |= 0x00000004;
      return this;
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public Builder clearContent() {
      if (contentBuilder_ == null) {
        content_ = com.github.jsdossier.proto.Comment.getDefaultInstance();
        onChanged();
      } else {
        contentBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000004);
      return this;
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public com.github.jsdossier.proto.Comment.Builder getContentBuilder() {
      bitField0_ |= 0x00000004;
      onChanged();
      return getContentFieldBuilder().getBuilder();
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    public com.github.jsdossier.proto.CommentOrBuilder getContentOrBuilder() {
      if (contentBuilder_ != null) {
        return contentBuilder_.getMessageOrBuilder();
      } else {
        return content_;
      }
    }
    /**
     * <code>optional .dossier.Comment content = 3;</code>
     *
     * <pre>
     * The page content, if any.
     * </pre>
     */
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Comment,
            com.github.jsdossier.proto.Comment.Builder,
            com.github.jsdossier.proto.CommentOrBuilder>
        getContentFieldBuilder() {
      if (contentBuilder_ == null) {
        contentBuilder_ =
            new com.google.protobuf.SingleFieldBuilder<
                com.github.jsdossier.proto.Comment,
                com.github.jsdossier.proto.Comment.Builder,
                com.github.jsdossier.proto.CommentOrBuilder>(
                getContent(), getParentForChildren(), isClean());
        content_ = null;
      }
      return contentBuilder_;
    }

    private com.github.jsdossier.proto.Index index_ =
        com.github.jsdossier.proto.Index.getDefaultInstance();
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Index,
            com.github.jsdossier.proto.Index.Builder,
            com.github.jsdossier.proto.IndexOrBuilder>
        indexBuilder_;
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public boolean hasIndex() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public com.github.jsdossier.proto.Index getIndex() {
      if (indexBuilder_ == null) {
        return index_;
      } else {
        return indexBuilder_.getMessage();
      }
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder setIndex(com.github.jsdossier.proto.Index value) {
      if (indexBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        index_ = value;
        onChanged();
      } else {
        indexBuilder_.setMessage(value);
      }
      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder setIndex(com.github.jsdossier.proto.Index.Builder builderForValue) {
      if (indexBuilder_ == null) {
        index_ = builderForValue.build();
        onChanged();
      } else {
        indexBuilder_.setMessage(builderForValue.build());
      }
      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder mergeIndex(com.github.jsdossier.proto.Index value) {
      if (indexBuilder_ == null) {
        if (((bitField0_ & 0x00000008) == 0x00000008)
            && index_ != com.github.jsdossier.proto.Index.getDefaultInstance()) {
          index_ =
              com.github.jsdossier.proto.Index.newBuilder(index_).mergeFrom(value).buildPartial();
        } else {
          index_ = value;
        }
        onChanged();
      } else {
        indexBuilder_.mergeFrom(value);
      }
      bitField0_ |= 0x00000008;
      return this;
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public Builder clearIndex() {
      if (indexBuilder_ == null) {
        index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
        onChanged();
      } else {
        indexBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000008);
      return this;
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public com.github.jsdossier.proto.Index.Builder getIndexBuilder() {
      bitField0_ |= 0x00000008;
      onChanged();
      return getIndexFieldBuilder().getBuilder();
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    public com.github.jsdossier.proto.IndexOrBuilder getIndexOrBuilder() {
      if (indexBuilder_ != null) {
        return indexBuilder_.getMessageOrBuilder();
      } else {
        return index_;
      }
    }
    /**
     * <code>required .dossier.Index index = 4;</code>
     *
     * <pre>
     * Navigation index.
     * </pre>
     */
    private com.google.protobuf.SingleFieldBuilder<
            com.github.jsdossier.proto.Index,
            com.github.jsdossier.proto.Index.Builder,
            com.github.jsdossier.proto.IndexOrBuilder>
        getIndexFieldBuilder() {
      if (indexBuilder_ == null) {
        indexBuilder_ =
            new com.google.protobuf.SingleFieldBuilder<
                com.github.jsdossier.proto.Index,
                com.github.jsdossier.proto.Index.Builder,
                com.github.jsdossier.proto.IndexOrBuilder>(
                getIndex(), getParentForChildren(), isClean());
        index_ = null;
      }
      return indexBuilder_;
    }

    // @@protoc_insertion_point(builder_scope:dossier.HtmlRenderSpec)
  }
コード例 #8
0
 private void initFields() {
   resources_ = com.github.jsdossier.proto.Resources.getDefaultInstance();
   title_ = "";
   content_ = com.github.jsdossier.proto.Comment.getDefaultInstance();
   index_ = com.github.jsdossier.proto.Index.getDefaultInstance();
 }