Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
P
protobuf
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
protobuf
Commits
69c14071
Commit
69c14071
authored
Jul 20, 2015
by
Jan Tattermusch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update addressbook.proto to proto3
parent
aba42edd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
addressbook.proto
examples/addressbook.proto
+8
-8
No files found.
examples/addressbook.proto
View file @
69c14071
// See README.txt for information and build instructions.
syntax
=
"proto
2
"
;
syntax
=
"proto
3
"
;
package
tutorial
;
...
...
@@ -9,9 +9,9 @@ option java_outer_classname = "AddressBookProtos";
option
csharp_namespace
=
"Google.ProtocolBuffers.Examples.AddressBook"
;
message
Person
{
required
string
name
=
1
;
required
int32
id
=
2
;
// Unique ID number for this person.
optional
string
email
=
3
;
string
name
=
1
;
int32
id
=
2
;
// Unique ID number for this person.
string
email
=
3
;
enum
PhoneType
{
MOBILE
=
0
;
...
...
@@ -20,14 +20,14 @@ message Person {
}
message
PhoneNumber
{
required
string
number
=
1
;
optional
PhoneType
type
=
2
[
default
=
HOME
]
;
string
number
=
1
;
PhoneType
type
=
2
;
}
repeated
PhoneNumber
phone
=
4
;
repeated
PhoneNumber
phone
s
=
4
;
}
// Our address book file is just one of these.
message
AddressBook
{
repeated
Person
person
=
1
;
repeated
Person
person
s
=
1
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment