Uploaded image for project: 'yangtools'
  1. yangtools
  2. YANGTOOLS-1462

Expose pre-sized builders from Builders

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: High High
    • 10.0.2
    • None
    • data-impl

      We have a few downstream users who are referencing ImmutableBuilders directly because that is the only way to access pre-sized constructors. These are ImmutableMapNodeBuilder, ImmutableUnkeyedListNodeBuilder and ImmutableUserMapNodeBuilder.

      Add static methods to Builders class to forward to these (and possibly others) in the form of:

          public static CollectionNodeBuilder<MapEntryNode, UserMapNode> orderedMapBuilderWithExpectedSize(final int size) {
              return ImmutableUserMapNodeBuilder.create(size);
          }
      

            matusmatok Matúš Matok
            rovarga Robert Varga
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: