Home / Class/ Builder Class — netty Architecture

Builder Class — netty Architecture

Architecture documentation for the Builder class in WorldClockProtocol.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed["Builder"]
  4270a70c_1373_1599_2ff1_865646eab29d["WorldClockProtocol.java"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|defined in| 4270a70c_1373_1599_2ff1_865646eab29d
  2fc934d0_afec_21e5_b1d6_da0bdff738e0["getDescriptor()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 2fc934d0_afec_21e5_b1d6_da0bdff738e0
  5d6828e3_5476_da24_f1c3_b746be57e015["internalGetFieldAccessorTable()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 5d6828e3_5476_da24_f1c3_b746be57e015
  a776de43_3d12_a869_9e1b_f3001fa85805["Builder()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| a776de43_3d12_a869_9e1b_f3001fa85805
  fa63e42d_385e_febe_1ebd_adc51ecda1e1["maybeForceBuilderInitialization()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| fa63e42d_385e_febe_1ebd_adc51ecda1e1
  6444075f_522f_a82d_207b_ddce8186d4e6["getDescriptorForType()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 6444075f_522f_a82d_207b_ddce8186d4e6
  22460cd3_c338_5b1c_e882_8b45ee255aac["getDefaultInstanceForType()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 22460cd3_c338_5b1c_e882_8b45ee255aac
  f0b74967_70ce_a5a5_1ed7_d1b4c43a4c5c["build()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| f0b74967_70ce_a5a5_1ed7_d1b4c43a4c5c
  3bd01aed_0259_ac52_5417_873d70b96ba8["buildPartial()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 3bd01aed_0259_ac52_5417_873d70b96ba8
  757e351b_3742_b77d_d4a5_d40f24c165c8["isInitialized()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 757e351b_3742_b77d_d4a5_d40f24c165c8
  dee6cd4b_c79f_b14d_3cc6_15938e3614ae["hasContinent()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| dee6cd4b_c79f_b14d_3cc6_15938e3614ae
  46467ae4_18b6_15c6_ae08_526f5df3ddeb["getContinent()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 46467ae4_18b6_15c6_ae08_526f5df3ddeb
  229dfdd9_ce4c_d273_4263_ced734919c2d["hasCity()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 229dfdd9_ce4c_d273_4263_ced734919c2d
  20386d92_a7d6_1513_4c03_dc533ea17dce["getCity()"]
  d14d3f3f_ddf6_f864_b1be_5eccb64e18ed -->|method| 20386d92_a7d6_1513_4c03_dc533ea17dce

Relationship Graph

Source Code

example/src/main/java/io/netty/example/worldclock/WorldClockProtocol.java lines 663–917

    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements io.netty.example.worldclock.WorldClockProtocol.LocationOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return io.netty.example.worldclock.WorldClockProtocol.internal_static_io_netty_example_worldclock_Location_descriptor;
      }

      @Override
      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return io.netty.example.worldclock.WorldClockProtocol.internal_static_io_netty_example_worldclock_Location_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                io.netty.example.worldclock.WorldClockProtocol.Location.class, io.netty.example.worldclock.WorldClockProtocol.Location.Builder.class);
      }

      // Construct using io.netty.example.worldclock.WorldClockProtocol.Location.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      @Override
      public Builder clear() {
        super.clear();
        continent_ = io.netty.example.worldclock.WorldClockProtocol.Continent.AFRICA;
        bitField0_ = (bitField0_ & ~0x00000001);
        city_ = "";
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }

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

      @Override
      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return io.netty.example.worldclock.WorldClockProtocol.internal_static_io_netty_example_worldclock_Location_descriptor;
      }

      @Override
      public io.netty.example.worldclock.WorldClockProtocol.Location getDefaultInstanceForType() {
        return io.netty.example.worldclock.WorldClockProtocol.Location.getDefaultInstance();
      }

      @Override
      public io.netty.example.worldclock.WorldClockProtocol.Location build() {
        io.netty.example.worldclock.WorldClockProtocol.Location result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      @Override
      public io.netty.example.worldclock.WorldClockProtocol.Location buildPartial() {
        io.netty.example.worldclock.WorldClockProtocol.Location result = new io.netty.example.worldclock.WorldClockProtocol.Location(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.continent_ = continent_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }

Frequently Asked Questions

What is the Builder class?
Builder is a class in the netty codebase, defined in example/src/main/java/io/netty/example/worldclock/WorldClockProtocol.java.
Where is Builder defined?
Builder is defined in example/src/main/java/io/netty/example/worldclock/WorldClockProtocol.java at line 663.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free