I get:

    // optional .KmObject kmobject = 1;
    public static final int KMOBJECT_FIELD_NUMBER = 1;
    private boolean hasKmobject;
    private KmObjectProtos.KmObject kmobject_ =
KmObjectProtos.KmObject.getDefaultInstance();
    public boolean hasKmobject() { return hasKmobject; }
    public KmObjectProtos.KmObject getKmobject() { return kmobject_; }

On Wed, Jan 12, 2011 at 3:23 AM, Meghana <meghana.vishwan...@gmail.com>wrote:

> Thanks for the reply Kenton.
>
> Here's the example -
> proto files :
>
> option java_outer_classname = "KmObjectProtos";
>
> message KmObject {
>        optional string id = 1;
>        optional string eTag = 2;
>        optional string eTagContents = 3;
>        optional string cDate = 4;
>        optional string uDate = 5;
>        optional bool sysInternal = 6;
> }
>
>
> option java_outer_classname = "ArtifactProtos";
>
> import "KmObject.proto";
>
> message Artifact {
>        optional KmObject kmobject = 1;
>        optional string artifactType = 2;
>        optional string contentHash = 3;
> }
>
> Generated Java -
>
>  // optional .KmObject kmobject = 1;
>    public static final int KMOBJECT_FIELD_NUMBER = 1;
>    private boolean hasKmobject;
>    private KmObject.KmObject kmobject_;
>    public boolean hasKmobject() { return hasKmobject; }
>    public KmObject.KmObject getKmobject() { return kmobject_; }
>
>
> I was expecting it to be KmObjectProtos.KmObject.
>
>
> On Jan 12, 2:26 am, Kenton Varda <ken...@google.com> wrote:
> > Can you provide a small, self-contained example?
> >
> > On Mon, Jan 10, 2011 at 7:13 AM, Meghana <meghana.vishwan...@gmail.com
> >wrote:
> >
> > > Hi,
> >
> > > I am using imports in my proto files. So, B has an import of A. When I
> > > generate the java code for B, all references to A are specified as A.A
> > > i.e. A(dot)A. It does not seem to be picking up the
> > > java_outer_classname from A.
> >
> > > Any idea what's going wrong?
> >
> > > Thanks.
> >
> > > --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Protocol Buffers" group.
> > > To post to this group, send email to proto...@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > protobuf+unsubscr...@googlegroups.com<protobuf%2bunsubscr...@googlegroups.com>
> <protobuf%2bunsubscr...@googlegroups.com<protobuf%252bunsubscr...@googlegroups.com>
> >
> > > .
> > > For more options, visit this group at
> > >http://groups.google.com/group/protobuf?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en.

Reply via email to