Interface ModelSettings<RawDocType, TModelType, TInstanceMethods, TQueryHelpers, TVirtuals, TStaticMethods, TSchemaOptions>

interface ModelSettings<RawDocType, TModelType, TInstanceMethods, TQueryHelpers, TVirtuals, TStaticMethods, TSchemaOptions> {
    collection?: string;
    name: string;
    schema: Schema<RawDocType, TModelType, TInstanceMethods, TQueryHelpers, TVirtuals, TStaticMethods, TSchemaOptions, ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>, IfAny<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>, any, (TVirtuals & TInstanceMethods) extends Record<string, never>
        ? Document<unknown, {}, FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>> & Require_id<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>>
        : IfAny<TVirtuals & TInstanceMethods, Document<unknown, {}, FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>> & Require_id<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>>, Document<unknown, {}, FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>> & Omit<Require_id<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<(...)>>, ResolveSchemaOptions<TSchemaOptions>>>>, keyof TInstanceMethods | keyof TVirtuals> & TVirtuals & TInstanceMethods>>>;
}

Type Parameters

  • RawDocType = NonNullable<unknown>
  • TModelType = Model<RawDocType, NonNullable<unknown>, NonNullable<unknown>, NonNullable<unknown>>
  • TInstanceMethods = NonNullable<unknown>
  • TQueryHelpers = NonNullable<unknown>
  • TVirtuals = NonNullable<unknown>
  • TStaticMethods = NonNullable<unknown>
  • TSchemaOptions = DefaultSchemaOptions

Properties

collection?: string
name: string
schema: Schema<RawDocType, TModelType, TInstanceMethods, TQueryHelpers, TVirtuals, TStaticMethods, TSchemaOptions, ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>, IfAny<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>, any, (TVirtuals & TInstanceMethods) extends Record<string, never>
    ? Document<unknown, {}, FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>> & Require_id<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>>
    : IfAny<TVirtuals & TInstanceMethods, Document<unknown, {}, FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>> & Require_id<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>>, Document<unknown, {}, FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<TSchemaOptions>>, ResolveSchemaOptions<TSchemaOptions>>>> & Omit<Require_id<FlatRecord<ResolveTimestamps<ObtainDocumentType<any, RawDocType, ResolveSchemaOptions<(...)>>, ResolveSchemaOptions<TSchemaOptions>>>>, keyof TInstanceMethods | keyof TVirtuals> & TVirtuals & TInstanceMethods>>>