logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Interface ISerenityRecipeSectionImporter

    A handler responsible for one recipe section. Section importers validate their own data, resolve references, and create or update the assets for that section. New sections are added by implementing this interface and registering the importer with the engine — no existing importer changes.

    Namespace: Serenity.ProjectRecipe.Infrastructure.Editor.Importers
    Assembly: Serenity.UnityProjectRecipe.Infrastructure.Editor.dll
    Syntax
    public interface ISerenityRecipeSectionImporter

    Properties

    IsSupported

    Declaration
    bool IsSupported { get; }
    Property Value
    Type Description
    bool

    True when this section produces real assets; false for deferred/reported-only sections.

    Order

    Declaration
    int Order { get; }
    Property Value
    Type Description
    int

    Execution order (ascending). Typed sections run first, the generic assets section after them so its references to generated assets resolve, and the deferred reporter last. Importers are discovered by reflection and sorted by this value, so a new section just picks an order without touching the engine.

    SectionName

    Declaration
    string SectionName { get; }
    Property Value
    Type Description
    string

    The recipe section this importer handles (used for reporting), e.g. audioClips.

    Methods

    Import(SerenityRecipeImportContext)

    Creates or updates this section's assets. In a dry run the context suppresses writes, so this only resolves and records the would-be outcomes. Not called when the report has blockers.

    Declaration
    void Import(SerenityRecipeImportContext context)
    Parameters
    Type Name Description
    SerenityRecipeImportContext context

    The shared import context.

    Validate(SerenityRecipeImportContext)

    Validates this section against the recipe and project, reporting errors/warnings/info. Must not modify any asset. Called for every run mode.

    Declaration
    void Validate(SerenityRecipeImportContext context)
    Parameters
    Type Name Description
    SerenityRecipeImportContext context

    The shared import context.

    In this article
    © 2026 Serenity. All Rights Reserved