blob: 92e4799717d059043e76bbe39c17c02a1a260226 [file] [log] [blame]
// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
syntax = "proto2";
option optimize_for = LITE_RUNTIME;
package web_app.proto;
// Proto represtenting a UrlPattern. This should be kept up to date with
// third_party/blink/public/common/url_pattern.h
message UrlPattern {
repeated UrlPatternPart pathname = 1;
}
message UrlPatternPart {
enum PartType {
PART_TYPE_UNSPECIFIED = 0;
PART_TYPE_FULL_WILDCARD = 1;
PART_TYPE_SEGMENT_WILDCARD = 2;
PART_TYPE_FIXED = 3;
}
optional PartType part_type = 1;
optional string name = 2;
optional string prefix = 3;
optional string value = 4;
optional string suffix = 5;
enum Modifier {
MODIFIER_UNSPECIFIED = 0;
MODIFIER_ZERO_OR_MORE = 1;
MODIFIER_OPTIONAL = 2;
MODIFIER_ONE_OR_MORE = 3;
MODIFIER_NONE = 4;
}
optional Modifier modifier = 6;
}