1// copyright (C) 2018 The Android Open Source Project 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15// A proto definition used to parse METADATA file in third party projects. 16 17// This proto will only contain fields and values the updater cares about. 18// It is not intended to be the formal definition of METADATA file. 19 20syntax = "proto3"; 21 22package external_updater; 23 24message MetaData { 25 string name = 1; 26 string description = 3; 27 ThirdPartyMetaData third_party = 13; 28} 29 30enum LicenseType { 31 UNKNOWN = 0; 32 BY_EXCEPTION_ONLY = 1; 33 NOTICE = 2; 34 PERMISSIVE = 3; 35 RECIPROCAL = 4; 36 RESTRICTED_IF_STATICALLY_LINKED = 5; 37 RESTRICTED = 6; 38 UNENCUMBERED = 7; 39} 40 41message ThirdPartyMetaData { 42 repeated URL url = 1; 43 string version = 2; 44 LicenseType license_type = 4; 45 string license_note = 5; 46 Date last_upgrade_date = 10; 47} 48 49message URL { 50 enum Type { 51 UNKNOWN = 0; 52 HOMEPAGE = 1; 53 ARCHIVE = 2; 54 GIT = 3; 55 SVN = 7; 56 HG = 8; 57 DARCS = 9; 58 OTHER = 11; 59 } 60 61 Type type = 1; 62 63 string value = 2; 64} 65 66message Date { 67 int32 year = 1; 68 int32 month = 2; 69 int32 day = 3; 70} 71