// Copyright (C) 2025 Rivos Inc.
//
// Licensed 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.

// Autogenerated by the ProtoZero Rust compiler plugin.
// Invoked by contrib/rust-sdk/tools/gen_rust_protos
// DO NOT EDIT.

use crate::pb_enum;
use crate::pb_msg;
use crate::protos::trace::track_event::chrome_process_descriptor::*;
use crate::protos::trace::track_event::chrome_thread_descriptor::*;
use crate::protos::trace::track_event::counter_descriptor::*;
use crate::protos::trace::track_event::process_descriptor::*;
use crate::protos::trace::track_event::thread_descriptor::*;

pb_enum!(TrackDescriptorChildTracksOrdering {
    UNKNOWN: 0,
    LEXICOGRAPHIC: 1,
    CHRONOLOGICAL: 2,
    EXPLICIT: 3,
});

pb_enum!(TrackDescriptorSiblingMergeBehavior {
    SIBLING_MERGE_BEHAVIOR_UNSPECIFIED: 0,
    SIBLING_MERGE_BEHAVIOR_BY_TRACK_NAME: 1,
    SIBLING_MERGE_BEHAVIOR_NONE: 2,
    SIBLING_MERGE_BEHAVIOR_BY_SIBLING_MERGE_KEY: 3,
});

pb_msg!(TrackDescriptor {
    uuid: u64, primitive, 1,
    parent_uuid: u64, primitive, 5,
    name: String, primitive, 2,
    static_name: String, primitive, 10,
    atrace_name: String, primitive, 13,
    description: String, primitive, 14,
    process: ProcessDescriptor, msg, 3,
    chrome_process: ChromeProcessDescriptor, msg, 6,
    thread: ThreadDescriptor, msg, 4,
    chrome_thread: ChromeThreadDescriptor, msg, 7,
    counter: CounterDescriptor, msg, 8,
    disallow_merging_with_system_tracks: bool, primitive, 9,
    child_ordering: TrackDescriptorChildTracksOrdering, enum, 11,
    sibling_order_rank: i32, primitive, 12,
    sibling_merge_behavior: TrackDescriptorSiblingMergeBehavior, enum, 15,
    sibling_merge_key: String, primitive, 16,
    sibling_merge_key_int: u64, primitive, 17,
});
