/* !!! This is code generated by Prisma. Do not edit directly. !!! */ /* eslint-disable */ // biome-ignore-all lint: generated file // @ts-nocheck /* * This file exports the `Drawing` model and its related types. * * 🟢 You can import this file directly. */ import type * as runtime from "@prisma/client/runtime/client" import type * as $Enums from "../enums" import type * as Prisma from "../internal/prismaNamespace" /** * Model Drawing * */ export type DrawingModel = runtime.Types.Result.DefaultSelection export type AggregateDrawing = { _count: DrawingCountAggregateOutputType | null _avg: DrawingAvgAggregateOutputType | null _sum: DrawingSumAggregateOutputType | null _min: DrawingMinAggregateOutputType | null _max: DrawingMaxAggregateOutputType | null } export type DrawingAvgAggregateOutputType = { version: number | null } export type DrawingSumAggregateOutputType = { version: number | null } export type DrawingMinAggregateOutputType = { id: string | null name: string | null elements: string | null appState: string | null version: number | null collectionId: string | null createdAt: Date | null updatedAt: Date | null } export type DrawingMaxAggregateOutputType = { id: string | null name: string | null elements: string | null appState: string | null version: number | null collectionId: string | null createdAt: Date | null updatedAt: Date | null } export type DrawingCountAggregateOutputType = { id: number name: number elements: number appState: number version: number collectionId: number createdAt: number updatedAt: number _all: number } export type DrawingAvgAggregateInputType = { version?: true } export type DrawingSumAggregateInputType = { version?: true } export type DrawingMinAggregateInputType = { id?: true name?: true elements?: true appState?: true version?: true collectionId?: true createdAt?: true updatedAt?: true } export type DrawingMaxAggregateInputType = { id?: true name?: true elements?: true appState?: true version?: true collectionId?: true createdAt?: true updatedAt?: true } export type DrawingCountAggregateInputType = { id?: true name?: true elements?: true appState?: true version?: true collectionId?: true createdAt?: true updatedAt?: true _all?: true } export type DrawingAggregateArgs = { /** * Filter which Drawing to aggregate. */ where?: Prisma.DrawingWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Drawings to fetch. */ orderBy?: Prisma.DrawingOrderByWithRelationInput | Prisma.DrawingOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: Prisma.DrawingWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Drawings from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Drawings. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Drawings **/ _count?: true | DrawingCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: DrawingAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: DrawingSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: DrawingMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: DrawingMaxAggregateInputType } export type GetDrawingAggregateType = { [P in keyof T & keyof AggregateDrawing]: P extends '_count' | 'count' ? T[P] extends true ? number : Prisma.GetScalarType : Prisma.GetScalarType } export type DrawingGroupByArgs = { where?: Prisma.DrawingWhereInput orderBy?: Prisma.DrawingOrderByWithAggregationInput | Prisma.DrawingOrderByWithAggregationInput[] by: Prisma.DrawingScalarFieldEnum[] | Prisma.DrawingScalarFieldEnum having?: Prisma.DrawingScalarWhereWithAggregatesInput take?: number skip?: number _count?: DrawingCountAggregateInputType | true _avg?: DrawingAvgAggregateInputType _sum?: DrawingSumAggregateInputType _min?: DrawingMinAggregateInputType _max?: DrawingMaxAggregateInputType } export type DrawingGroupByOutputType = { id: string name: string elements: string appState: string version: number collectionId: string | null createdAt: Date updatedAt: Date _count: DrawingCountAggregateOutputType | null _avg: DrawingAvgAggregateOutputType | null _sum: DrawingSumAggregateOutputType | null _min: DrawingMinAggregateOutputType | null _max: DrawingMaxAggregateOutputType | null } type GetDrawingGroupByPayload = Prisma.PrismaPromise< Array< Prisma.PickEnumerable & { [P in ((keyof T) & (keyof DrawingGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : Prisma.GetScalarType : Prisma.GetScalarType } > > export type DrawingWhereInput = { AND?: Prisma.DrawingWhereInput | Prisma.DrawingWhereInput[] OR?: Prisma.DrawingWhereInput[] NOT?: Prisma.DrawingWhereInput | Prisma.DrawingWhereInput[] id?: Prisma.StringFilter<"Drawing"> | string name?: Prisma.StringFilter<"Drawing"> | string elements?: Prisma.StringFilter<"Drawing"> | string appState?: Prisma.StringFilter<"Drawing"> | string version?: Prisma.IntFilter<"Drawing"> | number collectionId?: Prisma.StringNullableFilter<"Drawing"> | string | null createdAt?: Prisma.DateTimeFilter<"Drawing"> | Date | string updatedAt?: Prisma.DateTimeFilter<"Drawing"> | Date | string collection?: Prisma.XOR | null } export type DrawingOrderByWithRelationInput = { id?: Prisma.SortOrder name?: Prisma.SortOrder elements?: Prisma.SortOrder appState?: Prisma.SortOrder version?: Prisma.SortOrder collectionId?: Prisma.SortOrderInput | Prisma.SortOrder createdAt?: Prisma.SortOrder updatedAt?: Prisma.SortOrder collection?: Prisma.CollectionOrderByWithRelationInput } export type DrawingWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: Prisma.DrawingWhereInput | Prisma.DrawingWhereInput[] OR?: Prisma.DrawingWhereInput[] NOT?: Prisma.DrawingWhereInput | Prisma.DrawingWhereInput[] name?: Prisma.StringFilter<"Drawing"> | string elements?: Prisma.StringFilter<"Drawing"> | string appState?: Prisma.StringFilter<"Drawing"> | string version?: Prisma.IntFilter<"Drawing"> | number collectionId?: Prisma.StringNullableFilter<"Drawing"> | string | null createdAt?: Prisma.DateTimeFilter<"Drawing"> | Date | string updatedAt?: Prisma.DateTimeFilter<"Drawing"> | Date | string collection?: Prisma.XOR | null }, "id"> export type DrawingOrderByWithAggregationInput = { id?: Prisma.SortOrder name?: Prisma.SortOrder elements?: Prisma.SortOrder appState?: Prisma.SortOrder version?: Prisma.SortOrder collectionId?: Prisma.SortOrderInput | Prisma.SortOrder createdAt?: Prisma.SortOrder updatedAt?: Prisma.SortOrder _count?: Prisma.DrawingCountOrderByAggregateInput _avg?: Prisma.DrawingAvgOrderByAggregateInput _max?: Prisma.DrawingMaxOrderByAggregateInput _min?: Prisma.DrawingMinOrderByAggregateInput _sum?: Prisma.DrawingSumOrderByAggregateInput } export type DrawingScalarWhereWithAggregatesInput = { AND?: Prisma.DrawingScalarWhereWithAggregatesInput | Prisma.DrawingScalarWhereWithAggregatesInput[] OR?: Prisma.DrawingScalarWhereWithAggregatesInput[] NOT?: Prisma.DrawingScalarWhereWithAggregatesInput | Prisma.DrawingScalarWhereWithAggregatesInput[] id?: Prisma.StringWithAggregatesFilter<"Drawing"> | string name?: Prisma.StringWithAggregatesFilter<"Drawing"> | string elements?: Prisma.StringWithAggregatesFilter<"Drawing"> | string appState?: Prisma.StringWithAggregatesFilter<"Drawing"> | string version?: Prisma.IntWithAggregatesFilter<"Drawing"> | number collectionId?: Prisma.StringNullableWithAggregatesFilter<"Drawing"> | string | null createdAt?: Prisma.DateTimeWithAggregatesFilter<"Drawing"> | Date | string updatedAt?: Prisma.DateTimeWithAggregatesFilter<"Drawing"> | Date | string } export type DrawingCreateInput = { id?: string name: string elements: string appState: string version?: number createdAt?: Date | string updatedAt?: Date | string collection?: Prisma.CollectionCreateNestedOneWithoutDrawingsInput } export type DrawingUncheckedCreateInput = { id?: string name: string elements: string appState: string version?: number collectionId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type DrawingUpdateInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string collection?: Prisma.CollectionUpdateOneWithoutDrawingsNestedInput } export type DrawingUncheckedUpdateInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number collectionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string } export type DrawingCreateManyInput = { id?: string name: string elements: string appState: string version?: number collectionId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type DrawingUpdateManyMutationInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string } export type DrawingUncheckedUpdateManyInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number collectionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string } export type DrawingListRelationFilter = { every?: Prisma.DrawingWhereInput some?: Prisma.DrawingWhereInput none?: Prisma.DrawingWhereInput } export type DrawingOrderByRelationAggregateInput = { _count?: Prisma.SortOrder } export type DrawingCountOrderByAggregateInput = { id?: Prisma.SortOrder name?: Prisma.SortOrder elements?: Prisma.SortOrder appState?: Prisma.SortOrder version?: Prisma.SortOrder collectionId?: Prisma.SortOrder createdAt?: Prisma.SortOrder updatedAt?: Prisma.SortOrder } export type DrawingAvgOrderByAggregateInput = { version?: Prisma.SortOrder } export type DrawingMaxOrderByAggregateInput = { id?: Prisma.SortOrder name?: Prisma.SortOrder elements?: Prisma.SortOrder appState?: Prisma.SortOrder version?: Prisma.SortOrder collectionId?: Prisma.SortOrder createdAt?: Prisma.SortOrder updatedAt?: Prisma.SortOrder } export type DrawingMinOrderByAggregateInput = { id?: Prisma.SortOrder name?: Prisma.SortOrder elements?: Prisma.SortOrder appState?: Prisma.SortOrder version?: Prisma.SortOrder collectionId?: Prisma.SortOrder createdAt?: Prisma.SortOrder updatedAt?: Prisma.SortOrder } export type DrawingSumOrderByAggregateInput = { version?: Prisma.SortOrder } export type DrawingCreateNestedManyWithoutCollectionInput = { create?: Prisma.XOR | Prisma.DrawingCreateWithoutCollectionInput[] | Prisma.DrawingUncheckedCreateWithoutCollectionInput[] connectOrCreate?: Prisma.DrawingCreateOrConnectWithoutCollectionInput | Prisma.DrawingCreateOrConnectWithoutCollectionInput[] createMany?: Prisma.DrawingCreateManyCollectionInputEnvelope connect?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] } export type DrawingUncheckedCreateNestedManyWithoutCollectionInput = { create?: Prisma.XOR | Prisma.DrawingCreateWithoutCollectionInput[] | Prisma.DrawingUncheckedCreateWithoutCollectionInput[] connectOrCreate?: Prisma.DrawingCreateOrConnectWithoutCollectionInput | Prisma.DrawingCreateOrConnectWithoutCollectionInput[] createMany?: Prisma.DrawingCreateManyCollectionInputEnvelope connect?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] } export type DrawingUpdateManyWithoutCollectionNestedInput = { create?: Prisma.XOR | Prisma.DrawingCreateWithoutCollectionInput[] | Prisma.DrawingUncheckedCreateWithoutCollectionInput[] connectOrCreate?: Prisma.DrawingCreateOrConnectWithoutCollectionInput | Prisma.DrawingCreateOrConnectWithoutCollectionInput[] upsert?: Prisma.DrawingUpsertWithWhereUniqueWithoutCollectionInput | Prisma.DrawingUpsertWithWhereUniqueWithoutCollectionInput[] createMany?: Prisma.DrawingCreateManyCollectionInputEnvelope set?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] disconnect?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] delete?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] connect?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] update?: Prisma.DrawingUpdateWithWhereUniqueWithoutCollectionInput | Prisma.DrawingUpdateWithWhereUniqueWithoutCollectionInput[] updateMany?: Prisma.DrawingUpdateManyWithWhereWithoutCollectionInput | Prisma.DrawingUpdateManyWithWhereWithoutCollectionInput[] deleteMany?: Prisma.DrawingScalarWhereInput | Prisma.DrawingScalarWhereInput[] } export type DrawingUncheckedUpdateManyWithoutCollectionNestedInput = { create?: Prisma.XOR | Prisma.DrawingCreateWithoutCollectionInput[] | Prisma.DrawingUncheckedCreateWithoutCollectionInput[] connectOrCreate?: Prisma.DrawingCreateOrConnectWithoutCollectionInput | Prisma.DrawingCreateOrConnectWithoutCollectionInput[] upsert?: Prisma.DrawingUpsertWithWhereUniqueWithoutCollectionInput | Prisma.DrawingUpsertWithWhereUniqueWithoutCollectionInput[] createMany?: Prisma.DrawingCreateManyCollectionInputEnvelope set?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] disconnect?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] delete?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] connect?: Prisma.DrawingWhereUniqueInput | Prisma.DrawingWhereUniqueInput[] update?: Prisma.DrawingUpdateWithWhereUniqueWithoutCollectionInput | Prisma.DrawingUpdateWithWhereUniqueWithoutCollectionInput[] updateMany?: Prisma.DrawingUpdateManyWithWhereWithoutCollectionInput | Prisma.DrawingUpdateManyWithWhereWithoutCollectionInput[] deleteMany?: Prisma.DrawingScalarWhereInput | Prisma.DrawingScalarWhereInput[] } export type IntFieldUpdateOperationsInput = { set?: number increment?: number decrement?: number multiply?: number divide?: number } export type NullableStringFieldUpdateOperationsInput = { set?: string | null } export type DrawingCreateWithoutCollectionInput = { id?: string name: string elements: string appState: string version?: number createdAt?: Date | string updatedAt?: Date | string } export type DrawingUncheckedCreateWithoutCollectionInput = { id?: string name: string elements: string appState: string version?: number createdAt?: Date | string updatedAt?: Date | string } export type DrawingCreateOrConnectWithoutCollectionInput = { where: Prisma.DrawingWhereUniqueInput create: Prisma.XOR } export type DrawingCreateManyCollectionInputEnvelope = { data: Prisma.DrawingCreateManyCollectionInput | Prisma.DrawingCreateManyCollectionInput[] } export type DrawingUpsertWithWhereUniqueWithoutCollectionInput = { where: Prisma.DrawingWhereUniqueInput update: Prisma.XOR create: Prisma.XOR } export type DrawingUpdateWithWhereUniqueWithoutCollectionInput = { where: Prisma.DrawingWhereUniqueInput data: Prisma.XOR } export type DrawingUpdateManyWithWhereWithoutCollectionInput = { where: Prisma.DrawingScalarWhereInput data: Prisma.XOR } export type DrawingScalarWhereInput = { AND?: Prisma.DrawingScalarWhereInput | Prisma.DrawingScalarWhereInput[] OR?: Prisma.DrawingScalarWhereInput[] NOT?: Prisma.DrawingScalarWhereInput | Prisma.DrawingScalarWhereInput[] id?: Prisma.StringFilter<"Drawing"> | string name?: Prisma.StringFilter<"Drawing"> | string elements?: Prisma.StringFilter<"Drawing"> | string appState?: Prisma.StringFilter<"Drawing"> | string version?: Prisma.IntFilter<"Drawing"> | number collectionId?: Prisma.StringNullableFilter<"Drawing"> | string | null createdAt?: Prisma.DateTimeFilter<"Drawing"> | Date | string updatedAt?: Prisma.DateTimeFilter<"Drawing"> | Date | string } export type DrawingCreateManyCollectionInput = { id?: string name: string elements: string appState: string version?: number createdAt?: Date | string updatedAt?: Date | string } export type DrawingUpdateWithoutCollectionInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string } export type DrawingUncheckedUpdateWithoutCollectionInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string } export type DrawingUncheckedUpdateManyWithoutCollectionInput = { id?: Prisma.StringFieldUpdateOperationsInput | string name?: Prisma.StringFieldUpdateOperationsInput | string elements?: Prisma.StringFieldUpdateOperationsInput | string appState?: Prisma.StringFieldUpdateOperationsInput | string version?: Prisma.IntFieldUpdateOperationsInput | number createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string } export type DrawingSelect = runtime.Types.Extensions.GetSelect<{ id?: boolean name?: boolean elements?: boolean appState?: boolean version?: boolean collectionId?: boolean createdAt?: boolean updatedAt?: boolean collection?: boolean | Prisma.Drawing$collectionArgs }, ExtArgs["result"]["drawing"]> export type DrawingSelectCreateManyAndReturn = runtime.Types.Extensions.GetSelect<{ id?: boolean name?: boolean elements?: boolean appState?: boolean version?: boolean collectionId?: boolean createdAt?: boolean updatedAt?: boolean collection?: boolean | Prisma.Drawing$collectionArgs }, ExtArgs["result"]["drawing"]> export type DrawingSelectUpdateManyAndReturn = runtime.Types.Extensions.GetSelect<{ id?: boolean name?: boolean elements?: boolean appState?: boolean version?: boolean collectionId?: boolean createdAt?: boolean updatedAt?: boolean collection?: boolean | Prisma.Drawing$collectionArgs }, ExtArgs["result"]["drawing"]> export type DrawingSelectScalar = { id?: boolean name?: boolean elements?: boolean appState?: boolean version?: boolean collectionId?: boolean createdAt?: boolean updatedAt?: boolean } export type DrawingOmit = runtime.Types.Extensions.GetOmit<"id" | "name" | "elements" | "appState" | "version" | "collectionId" | "createdAt" | "updatedAt", ExtArgs["result"]["drawing"]> export type DrawingInclude = { collection?: boolean | Prisma.Drawing$collectionArgs } export type DrawingIncludeCreateManyAndReturn = { collection?: boolean | Prisma.Drawing$collectionArgs } export type DrawingIncludeUpdateManyAndReturn = { collection?: boolean | Prisma.Drawing$collectionArgs } export type $DrawingPayload = { name: "Drawing" objects: { collection: Prisma.$CollectionPayload | null } scalars: runtime.Types.Extensions.GetPayloadResult<{ id: string name: string elements: string appState: string version: number collectionId: string | null createdAt: Date updatedAt: Date }, ExtArgs["result"]["drawing"]> composites: {} } export type DrawingGetPayload = runtime.Types.Result.GetResult export type DrawingCountArgs = Omit & { select?: DrawingCountAggregateInputType | true } export interface DrawingDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Drawing'], meta: { name: 'Drawing' } } /** * Find zero or one Drawing that matches the filter. * @param {DrawingFindUniqueArgs} args - Arguments to find a Drawing * @example * // Get one Drawing * const drawing = await prisma.drawing.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> /** * Find one Drawing that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {DrawingFindUniqueOrThrowArgs} args - Arguments to find a Drawing * @example * // Get one Drawing * const drawing = await prisma.drawing.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions> /** * Find the first Drawing that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingFindFirstArgs} args - Arguments to find a Drawing * @example * // Get one Drawing * const drawing = await prisma.drawing.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> /** * Find the first Drawing that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingFindFirstOrThrowArgs} args - Arguments to find a Drawing * @example * // Get one Drawing * const drawing = await prisma.drawing.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions> /** * Find zero or more Drawings that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Drawings * const drawings = await prisma.drawing.findMany() * * // Get first 10 Drawings * const drawings = await prisma.drawing.findMany({ take: 10 }) * * // Only select the `id` * const drawingWithIdOnly = await prisma.drawing.findMany({ select: { id: true } }) * */ findMany(args?: Prisma.SelectSubset>): Prisma.PrismaPromise, T, "findMany", GlobalOmitOptions>> /** * Create a Drawing. * @param {DrawingCreateArgs} args - Arguments to create a Drawing. * @example * // Create one Drawing * const Drawing = await prisma.drawing.create({ * data: { * // ... data to create a Drawing * } * }) * */ create(args: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions> /** * Create many Drawings. * @param {DrawingCreateManyArgs} args - Arguments to create many Drawings. * @example * // Create many Drawings * const drawing = await prisma.drawing.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: Prisma.SelectSubset>): Prisma.PrismaPromise /** * Create many Drawings and returns the data saved in the database. * @param {DrawingCreateManyAndReturnArgs} args - Arguments to create many Drawings. * @example * // Create many Drawings * const drawing = await prisma.drawing.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Drawings and only return the `id` * const drawingWithIdOnly = await prisma.drawing.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: Prisma.SelectSubset>): Prisma.PrismaPromise, T, "createManyAndReturn", GlobalOmitOptions>> /** * Delete a Drawing. * @param {DrawingDeleteArgs} args - Arguments to delete one Drawing. * @example * // Delete one Drawing * const Drawing = await prisma.drawing.delete({ * where: { * // ... filter to delete one Drawing * } * }) * */ delete(args: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions> /** * Update one Drawing. * @param {DrawingUpdateArgs} args - Arguments to update one Drawing. * @example * // Update one Drawing * const drawing = await prisma.drawing.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions> /** * Delete zero or more Drawings. * @param {DrawingDeleteManyArgs} args - Arguments to filter Drawings to delete. * @example * // Delete a few Drawings * const { count } = await prisma.drawing.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: Prisma.SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Drawings. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Drawings * const drawing = await prisma.drawing.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: Prisma.SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Drawings and returns the data updated in the database. * @param {DrawingUpdateManyAndReturnArgs} args - Arguments to update many Drawings. * @example * // Update many Drawings * const drawing = await prisma.drawing.updateManyAndReturn({ * where: { * // ... provide filter here * }, * data: [ * // ... provide data here * ] * }) * * // Update zero or more Drawings and only return the `id` * const drawingWithIdOnly = await prisma.drawing.updateManyAndReturn({ * select: { id: true }, * where: { * // ... provide filter here * }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ updateManyAndReturn(args: Prisma.SelectSubset>): Prisma.PrismaPromise, T, "updateManyAndReturn", GlobalOmitOptions>> /** * Create or update one Drawing. * @param {DrawingUpsertArgs} args - Arguments to update or create a Drawing. * @example * // Update or create a Drawing * const drawing = await prisma.drawing.upsert({ * create: { * // ... data to create a Drawing * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Drawing we want to update * } * }) */ upsert(args: Prisma.SelectSubset>): Prisma.Prisma__DrawingClient, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions> /** * Count the number of Drawings. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingCountArgs} args - Arguments to filter Drawings to count. * @example * // Count the number of Drawings * const count = await prisma.drawing.count({ * where: { * // ... the filter for the Drawings we want to count * } * }) **/ count( args?: Prisma.Subset, ): Prisma.PrismaPromise< T extends runtime.Types.Utils.Record<'select', any> ? T['select'] extends true ? number : Prisma.GetScalarType : number > /** * Allows you to perform aggregations operations on a Drawing. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Prisma.Subset): Prisma.PrismaPromise> /** * Group by Drawing. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {DrawingGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends DrawingGroupByArgs, HasSelectOrTake extends Prisma.Or< Prisma.Extends<'skip', Prisma.Keys>, Prisma.Extends<'take', Prisma.Keys> >, OrderByArg extends Prisma.True extends HasSelectOrTake ? { orderBy: DrawingGroupByArgs['orderBy'] } : { orderBy?: DrawingGroupByArgs['orderBy'] }, OrderFields extends Prisma.ExcludeUnderscoreKeys>>, ByFields extends Prisma.MaybeTupleToUnion, ByValid extends Prisma.Has, HavingFields extends Prisma.GetHavingFields, HavingValid extends Prisma.Has, ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False, InputErrors extends ByEmpty extends Prisma.True ? `Error: "by" must not be empty.` : HavingValid extends Prisma.False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Prisma.Keys ? 'orderBy' extends Prisma.Keys ? ByValid extends Prisma.True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Prisma.Keys ? 'orderBy' extends Prisma.Keys ? ByValid extends Prisma.True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends Prisma.True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: Prisma.SubsetIntersection & InputErrors): {} extends InputErrors ? GetDrawingGroupByPayload : Prisma.PrismaPromise /** * Fields of the Drawing model */ readonly fields: DrawingFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Drawing. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__DrawingClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" collection = {}>(args?: Prisma.Subset>): Prisma.Prisma__CollectionClient, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): runtime.Types.Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): runtime.Types.Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise } /** * Fields of the Drawing model */ export interface DrawingFieldRefs { readonly id: Prisma.FieldRef<"Drawing", 'String'> readonly name: Prisma.FieldRef<"Drawing", 'String'> readonly elements: Prisma.FieldRef<"Drawing", 'String'> readonly appState: Prisma.FieldRef<"Drawing", 'String'> readonly version: Prisma.FieldRef<"Drawing", 'Int'> readonly collectionId: Prisma.FieldRef<"Drawing", 'String'> readonly createdAt: Prisma.FieldRef<"Drawing", 'DateTime'> readonly updatedAt: Prisma.FieldRef<"Drawing", 'DateTime'> } // Custom InputTypes /** * Drawing findUnique */ export type DrawingFindUniqueArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * Filter, which Drawing to fetch. */ where: Prisma.DrawingWhereUniqueInput } /** * Drawing findUniqueOrThrow */ export type DrawingFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * Filter, which Drawing to fetch. */ where: Prisma.DrawingWhereUniqueInput } /** * Drawing findFirst */ export type DrawingFindFirstArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * Filter, which Drawing to fetch. */ where?: Prisma.DrawingWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Drawings to fetch. */ orderBy?: Prisma.DrawingOrderByWithRelationInput | Prisma.DrawingOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Drawings. */ cursor?: Prisma.DrawingWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Drawings from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Drawings. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Drawings. */ distinct?: Prisma.DrawingScalarFieldEnum | Prisma.DrawingScalarFieldEnum[] } /** * Drawing findFirstOrThrow */ export type DrawingFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * Filter, which Drawing to fetch. */ where?: Prisma.DrawingWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Drawings to fetch. */ orderBy?: Prisma.DrawingOrderByWithRelationInput | Prisma.DrawingOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Drawings. */ cursor?: Prisma.DrawingWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Drawings from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Drawings. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Drawings. */ distinct?: Prisma.DrawingScalarFieldEnum | Prisma.DrawingScalarFieldEnum[] } /** * Drawing findMany */ export type DrawingFindManyArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * Filter, which Drawings to fetch. */ where?: Prisma.DrawingWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Drawings to fetch. */ orderBy?: Prisma.DrawingOrderByWithRelationInput | Prisma.DrawingOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Drawings. */ cursor?: Prisma.DrawingWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Drawings from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Drawings. */ skip?: number distinct?: Prisma.DrawingScalarFieldEnum | Prisma.DrawingScalarFieldEnum[] } /** * Drawing create */ export type DrawingCreateArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * The data needed to create a Drawing. */ data: Prisma.XOR } /** * Drawing createMany */ export type DrawingCreateManyArgs = { /** * The data used to create many Drawings. */ data: Prisma.DrawingCreateManyInput | Prisma.DrawingCreateManyInput[] } /** * Drawing createManyAndReturn */ export type DrawingCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelectCreateManyAndReturn | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * The data used to create many Drawings. */ data: Prisma.DrawingCreateManyInput | Prisma.DrawingCreateManyInput[] /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingIncludeCreateManyAndReturn | null } /** * Drawing update */ export type DrawingUpdateArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * The data needed to update a Drawing. */ data: Prisma.XOR /** * Choose, which Drawing to update. */ where: Prisma.DrawingWhereUniqueInput } /** * Drawing updateMany */ export type DrawingUpdateManyArgs = { /** * The data used to update Drawings. */ data: Prisma.XOR /** * Filter which Drawings to update */ where?: Prisma.DrawingWhereInput /** * Limit how many Drawings to update. */ limit?: number } /** * Drawing updateManyAndReturn */ export type DrawingUpdateManyAndReturnArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelectUpdateManyAndReturn | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * The data used to update Drawings. */ data: Prisma.XOR /** * Filter which Drawings to update */ where?: Prisma.DrawingWhereInput /** * Limit how many Drawings to update. */ limit?: number /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingIncludeUpdateManyAndReturn | null } /** * Drawing upsert */ export type DrawingUpsertArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * The filter to search for the Drawing to update in case it exists. */ where: Prisma.DrawingWhereUniqueInput /** * In case the Drawing found by the `where` argument doesn't exist, create a new Drawing with this data. */ create: Prisma.XOR /** * In case the Drawing was found with the provided `where` argument, update it with this data. */ update: Prisma.XOR } /** * Drawing delete */ export type DrawingDeleteArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null /** * Filter which Drawing to delete. */ where: Prisma.DrawingWhereUniqueInput } /** * Drawing deleteMany */ export type DrawingDeleteManyArgs = { /** * Filter which Drawings to delete */ where?: Prisma.DrawingWhereInput /** * Limit how many Drawings to delete. */ limit?: number } /** * Drawing.collection */ export type Drawing$collectionArgs = { /** * Select specific fields to fetch from the Collection */ select?: Prisma.CollectionSelect | null /** * Omit specific fields from the Collection */ omit?: Prisma.CollectionOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.CollectionInclude | null where?: Prisma.CollectionWhereInput } /** * Drawing without action */ export type DrawingDefaultArgs = { /** * Select specific fields to fetch from the Drawing */ select?: Prisma.DrawingSelect | null /** * Omit specific fields from the Drawing */ omit?: Prisma.DrawingOmit | null /** * Choose, which related nodes to fetch as well */ include?: Prisma.DrawingInclude | null }