Skip to content

Commit 8e54700

Browse files
committed
deploy: 9b7f755
1 parent 5da3c38 commit 8e54700

File tree

35 files changed

+224
-216
lines changed

35 files changed

+224
-216
lines changed

editions/features/index.html

Lines changed: 4 additions & 4 deletions
Large diffs are not rendered by default.

editions/overview/index.html

Lines changed: 28 additions & 12 deletions
Large diffs are not rendered by default.

getting-started/gotutorial/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@
138138
</span></span><span style=display:flex><span> <span style=color:#000>Name</span><span style=color:#000;font-weight:700>:</span> <span style=color:#4e9a06>&#34;John Doe&#34;</span><span style=color:#000;font-weight:700>,</span>
139139
</span></span><span style=display:flex><span> <span style=color:#000>Email</span><span style=color:#000;font-weight:700>:</span> <span style=color:#4e9a06>&#34;[email protected]&#34;</span><span style=color:#000;font-weight:700>,</span>
140140
</span></span><span style=display:flex><span> <span style=color:#000>Phones</span><span style=color:#000;font-weight:700>:</span> <span style=color:#000;font-weight:700>[]</span><span style=color:#ce5c00;font-weight:700>*</span><span style=color:#000>pb</span><span style=color:#000;font-weight:700>.</span><span style=color:#000>Person_PhoneNumber</span><span style=color:#000;font-weight:700>{</span>
141-
</span></span><span style=display:flex><span> <span style=color:#000;font-weight:700>{</span><span style=color:#000>Number</span><span style=color:#000;font-weight:700>:</span> <span style=color:#4e9a06>&#34;555-4321&#34;</span><span style=color:#000;font-weight:700>,</span> <span style=color:#000>Type</span><span style=color:#000;font-weight:700>:</span> <span style=color:#000>pb</span><span style=color:#000;font-weight:700>.</span><span style=color:#000>Person_PHONE_TYPE_HOME</span><span style=color:#000;font-weight:700>},</span>
141+
</span></span><span style=display:flex><span> <span style=color:#000;font-weight:700>{</span><span style=color:#000>Number</span><span style=color:#000;font-weight:700>:</span> <span style=color:#4e9a06>&#34;555-4321&#34;</span><span style=color:#000;font-weight:700>,</span> <span style=color:#000>Type</span><span style=color:#000;font-weight:700>:</span> <span style=color:#000>pb</span><span style=color:#000;font-weight:700>.</span><span style=color:#000>PhoneType_PHONE_TYPE_HOME</span><span style=color:#000;font-weight:700>},</span>
142142
</span></span><span style=display:flex><span> <span style=color:#000;font-weight:700>},</span>
143143
</span></span><span style=display:flex><span><span style=color:#000;font-weight:700>}</span>
144144
</span></span></code></pre></div><h2 id=writing-a-message>Writing a Message</h2><p>The whole purpose of using protocol buffers is to serialize your data so that it

index.html

Lines changed: 11 additions & 11 deletions
Large diffs are not rendered by default.

overview/index.html

Lines changed: 2 additions & 2 deletions
Large diffs are not rendered by default.

programming-guides/dos-donts/index.html

Lines changed: 3 additions & 2 deletions
Large diffs are not rendered by default.

programming-guides/enum/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
Accessor will report the field as being <em>set</em> and will return something that
2828
represents <code>2</code>.</li><li><strong>Closed</strong> enums will parse the value <code>2</code> and store it in the message&rsquo;s
2929
unknown field set. Accessors will report the field as being <em>unset</em> and will
30-
return the enum&rsquo;s default value.</li></ul><h2 id=implications-of-closed-enums>Implications of <em>Closed</em> Enums</h2><p>The behavior of <em>closed</em> enums has unexpected consquences when parsing a
30+
return the enum&rsquo;s default value.</li></ul><h2 id=implications-of-closed-enums>Implications of <em>Closed</em> Enums</h2><p>The behavior of <em>closed</em> enums has unexpected consequences when parsing a
3131
repeated field. When a <code>repeated Enum</code> field is parsed all unknown values will
3232
be placed in the
3333
<a href=/programming-guides/proto3/#unknowns>unknown field</a>

programming-guides/field_presence/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
</span></span></span></code></pre></div><p>Depending on the target language, the generated API would generally include
7272
several methods:</p><ul><li>A hazzer for the oneof: <code>has_foo</code></li><li>A <em>oneof case</em> method: <code>foo</code></li><li>Hazzers for the members: <code>has_a</code>, <code>has_b</code></li><li>Getters for the members: <code>a</code>, <code>b</code></li></ul><p>Repeated fields and maps do not track presence: there is no distinction between
7373
an <em>empty</em> and a <em>not-present</em> repeated field.</p><h3 id=presence-in-proto3-apis>Presence in Proto3 APIs</h3><p>This table outlines whether presence is tracked for fields in proto3 APIs (both
74-
for generated APIs and using dynamic reflection):</p><table><thead><tr><th>Field type</th><th><code>optional</code></th><th>Explicit Presence</th></tr></thead><tbody><tr><td>Singular numeric (integer or floating point)</td><td>No</td><td></td></tr><tr><td>Singular enum</td><td>No</td><td></td></tr><tr><td>Singular string or bytes</td><td>No</td><td></td></tr><tr><td>Singular numeric (integer or floating point)</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular enum</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular string or bytes</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular message</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular message</td><td>No</td><td>✔️</td></tr><tr><td>Repeated</td><td>N/A</td><td></td></tr><tr><td>Oneofs</td><td>N/A</td><td>✔️</td></tr><tr><td>Maps</td><td>N/A</td><td></td></tr></tbody></table><p>Similar to proto2 APIs, proto3 does not track presence explicitly for repeated
74+
for generated APIs and using dynamic reflection):</p><table><thead><tr><th>Field type</th><th><code>optional</code></th><th>Explicit Presence</th></tr></thead><tbody><tr><td>Singular numeric (integer or floating point)</td><td>No</td><td></td></tr><tr><td>Singular numeric (integer or floating point)</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular enum</td><td>No</td><td></td></tr><tr><td>Singular enum</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular string or bytes</td><td>No</td><td></td></tr><tr><td>Singular string or bytes</td><td>Yes</td><td>✔️</td></tr><tr><td>Singular message</td><td>No</td><td>✔️</td></tr><tr><td>Singular message</td><td>Yes</td><td>✔️</td></tr><tr><td>Repeated</td><td>N/A</td><td></td></tr><tr><td>Oneofs</td><td>N/A</td><td>✔️</td></tr><tr><td>Maps</td><td>N/A</td><td></td></tr></tbody></table><p>Similar to proto2 APIs, proto3 does not track presence explicitly for repeated
7575
fields. Without the <code>optional</code> label, proto3 APIs do not track presence for
7676
basic types (numeric, string, bytes, and enums), either. Oneof fields
7777
affirmatively expose presence, although the same set of hazzer methods may not

programming-guides/proto2/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -944,8 +944,8 @@
944944
serializing, parsing, and performing other common operations on your
945945
message types. This code is highly optimized.</li><li><code>CODE_SIZE</code>: The protocol buffer compiler will generate minimal classes
946946
and will rely on shared, reflection-based code to implement
947-
serialialization, parsing, and various other operations. The generated
948-
code will thus be much smaller than with <code>SPEED</code>, but operations will be
947+
serialization, parsing, and various other operations. The generated code
948+
will thus be much smaller than with <code>SPEED</code>, but operations will be
949949
slower. Classes will still implement exactly the same public API as they
950950
do in <code>SPEED</code> mode. This mode is most useful in apps that contain a very
951951
large number of <code>.proto</code> files and do not need all of them to be

programming-guides/proto3/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -646,8 +646,8 @@
646646
serializing, parsing, and performing other common operations on your
647647
message types. This code is highly optimized.</li><li><code>CODE_SIZE</code>: The protocol buffer compiler will generate minimal classes
648648
and will rely on shared, reflection-based code to implement
649-
serialialization, parsing, and various other operations. The generated
650-
code will thus be much smaller than with <code>SPEED</code>, but operations will be
649+
serialization, parsing, and various other operations. The generated code
650+
will thus be much smaller than with <code>SPEED</code>, but operations will be
651651
slower. Classes will still implement exactly the same public API as they
652652
do in <code>SPEED</code> mode. This mode is most useful in apps that contain a very
653653
large number of <code>.proto</code> files and do not need all of them to be

0 commit comments

Comments
 (0)