@grandlinex/swagger-mate
    Preparing search index...

    Class ESchemaEditor<T>

    Type Parameters

    • T extends CoreEntity
    Index
    • Generates a JSON schema representation from a CoreEntity instance.

      This method inspects the entity's metadata to construct a schema object describing the entity's shape. The resulting schema contains:

      • type: always "object".
      • description: a string indicating the entity name.
      • required: an array of property names that are defined on the entity.
      • properties: an object mapping each property name to an object that includes the resolved database type and its nullability.

      If no metadata is found for the provided entity, the method returns undefined.

      Type Parameters

      • T extends CoreEntity

      Parameters

      • entity: T

        The entity instance for which to create a schema.

      Returns SSchemaElObj | undefined

      The generated schema object, or undefined if the entity's metadata could not be retrieved.