//
// Copyright (C) 2023 The Android Open Source Project
//
// 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.

// @generated by protoc-gen-es v2.2.2 with parameter "target=ts"
// @generated from file protos/perfetto/metrics/android/android_blocking_call.proto (package perfetto.protos, syntax proto2)
/* eslint-disable */

import type { GenFile, GenMessage } from "@bufbuild/protobuf/codegenv1";
import { fileDesc, messageDesc } from "@bufbuild/protobuf/codegenv1";
import type { Message } from "@bufbuild/protobuf";

/**
 * Describes the file protos/perfetto/metrics/android/android_blocking_call.proto.
 */
export const file_protos_perfetto_metrics_android_android_blocking_call: GenFile = /*@__PURE__*/
  fileDesc("Cjtwcm90b3MvcGVyZmV0dG8vbWV0cmljcy9hbmRyb2lkL2FuZHJvaWRfYmxvY2tpbmdfY2FsbC5wcm90bxIPcGVyZmV0dG8ucHJvdG9zItQBChNBbmRyb2lkQmxvY2tpbmdDYWxsEgwKBG5hbWUYASABKAkSCwoDY250GAIgASgDEhQKDHRvdGFsX2R1cl9tcxgDIAEoAxISCgptYXhfZHVyX21zGAQgASgDEhIKCm1pbl9kdXJfbXMYBSABKAMSFAoMdG90YWxfZHVyX25zGAYgASgDEhIKCm1heF9kdXJfbnMYByABKAMSEgoKbWluX2R1cl9ucxgIIAEoAxISCgphdmdfZHVyX21zGAkgASgDEhIKCmF2Z19kdXJfbnMYCiABKAM");

/**
 * Blocking call on the main thread.
 *
 * @generated from message perfetto.protos.AndroidBlockingCall
 */
export type AndroidBlockingCall = Message<"perfetto.protos.AndroidBlockingCall"> & {
  /**
   * Name of the blocking call
   *
   * @generated from field: optional string name = 1;
   */
  name: string;

  /**
   * Number of times it happened within the CUJ
   *
   * @generated from field: optional int64 cnt = 2;
   */
  cnt: bigint;

  /**
   * Total duration within the CUJ
   *
   * @generated from field: optional int64 total_dur_ms = 3;
   */
  totalDurMs: bigint;

  /**
   * Maximal duration within the CUJ
   *
   * @generated from field: optional int64 max_dur_ms = 4;
   */
  maxDurMs: bigint;

  /**
   * Minimal duration within the CUJ
   *
   * @generated from field: optional int64 min_dur_ms = 5;
   */
  minDurMs: bigint;

  /**
   * Total duration within the CUJ in nanoseconds
   *
   * @generated from field: optional int64 total_dur_ns = 6;
   */
  totalDurNs: bigint;

  /**
   * Maximal duration within the CUJ in nanoseconds
   *
   * @generated from field: optional int64 max_dur_ns = 7;
   */
  maxDurNs: bigint;

  /**
   * Minimal duration within the CUJ in nanoseconds
   *
   * @generated from field: optional int64 min_dur_ns = 8;
   */
  minDurNs: bigint;

  /**
   * Avg duration within the CUJ
   *
   * @generated from field: optional int64 avg_dur_ms = 9;
   */
  avgDurMs: bigint;

  /**
   * Avg duration within the CUJ in nanoseconds
   *
   * @generated from field: optional int64 avg_dur_ns = 10;
   */
  avgDurNs: bigint;
};

/**
 * Describes the message perfetto.protos.AndroidBlockingCall.
 * Use `create(AndroidBlockingCallSchema)` to create a new message.
 */
export const AndroidBlockingCallSchema: GenMessage<AndroidBlockingCall> = /*@__PURE__*/
  messageDesc(file_protos_perfetto_metrics_android_android_blocking_call, 0);

