• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (C) 2022 Huawei Device Co., Ltd.
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 */
15import {BaseStruct} from "../../../bean/BaseStruct.js";
16import {Rect} from "../timer-shaft/Rect.js";
17import {TraceRow} from "./TraceRow.js";
18
19export class TraceRowObject<T extends BaseStruct> {
20    public rowId: string | undefined;
21    public rowType: string | undefined;
22    public rowParentId: string | undefined;
23    public rowHidden: boolean = false;
24    public rowHeight: number = 40;
25    public name: string | undefined;
26    public must: boolean = true;
27    public folder: boolean = false;
28    public isLoading: boolean = false;
29    public children: boolean = false;
30    public expansion: boolean = false;
31    public dataList: Array<T> | undefined;
32    public dataListCache: Array<T> = [];
33    public color: string | undefined;
34    public frame: Rect | undefined;
35    public supplier: (() => Promise<Array<T>>) | undefined | null
36    public onThreadHandler: ((row: TraceRow<T>, ctx: ImageBitmapRenderingContext | CanvasRenderingContext2D | WebGLRenderingContext | WebGL2RenderingContext | null | undefined) => void) | undefined | null
37    public onDrawHandler: ((ctx: ImageBitmapRenderingContext | CanvasRenderingContext2D | WebGLRenderingContext | WebGL2RenderingContext | null | undefined) => void) | undefined | null
38    public top: number = 0;
39    public rowIndex: number = 0;
40    public preObject: TraceRowObject<T> | undefined | null;
41    public nextObject: TraceRowObject<T> | undefined | null;
42}
43