// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements.  See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership.  The ASF licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may not use this file except in compliance
// with the License.  You may obtain a copy of the License at
//
//   http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing,
// software distributed under the License is distributed on an
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
// KIND, either express or implied.  See the License for the
// specific language governing permissions and limitations
// under the License.

syntax="proto2";
message AddressNoMap {
    required string addr = 1;
}

message AddressIntMap {
    required string addr = 1;
    message MapFieldEntry {
        required string key = 1;
        required int32 value = 2;
    }
    repeated MapFieldEntry numbers = 2;
}

message AddressStringMap {
    required string addr = 1;
    message MapFieldEntry {
        required string key = 1;
        required string value = 2;
    }
    repeated MapFieldEntry contacts = 2;
}

message AddressComplex {
    required string addr = 1;
    
    message FriendEntry {
        required string key = 1;
        message Education {
            required string school = 1;
            required int32 year = 2;
        }
        repeated Education value = 2;
    }
    repeated FriendEntry friends = 2;
}

message AddressIntMapStd {
    required string addr = 1;
    map<string, int32> numbers = 2;
}

message AddressStringMapStd {
    required string addr = 1;
    map<string, string> contacts = 2;
}

message haha {
    repeated int32 a = 1;
}