syntax = "proto3";
package my.great.package;
import "google/protobuf/timestamp.proto";
option java_outer_classname = "TimestampedThingMsg";
message TimestampedThing { string thing = 1; Timestamp date = 2; }
protobuf/timestamped_thing.proto: Import "google/protobuf/timestamp.proto" was not found or had errors.
protobuf/timestamped_thing.proto:15:5: "Timestamp" is not defined.
How can I import the new Timestamp message type (source file: https://github.com/google/protobuf/blob/master/src/google/protobuf/timestamp.proto) to use it in my own messages?
The only related example I could find in the docs was for the Any type where the import looks exactly like mine so not sure how to go about this. Docs link: https://developers.google.com/protocol-buffers/docs/proto3#any
Thanks!
Hi everyone,I have installed protobuf3.0.0-alpha-3 on my machine and have the following proto file:
syntax = "proto3";package my.great.package;import "google/protobuf/timestamp.proto";option java_outer_classname = "TimestampedThingMsg";message TimestampedThing {string thing = 1;Timestamp date = 2;}However when I run "protoc protobuf/timestamped_thing.proto" I get the following two errors:protobuf/timestamped_thing.proto: Import "google/protobuf/timestamp.proto" was not found or had errors.
protobuf/timestamped_thing.proto:15:5: "Timestamp" is not defined.