Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Migrate FormObjectToJSON to use visitor pattern #44

Open
Labels
enhancementNew feature or request

Description

Once Delphi.Forms.Visitor (#41) ships, evaluate migrating the JSON
serialization in Delphi.Forms.JSON to use the visitor for traversal.

This migration is less straightforward than NormalizeForm or Statistics
because JSON serialization builds a nested TJSONObject tree that mirrors
the AST hierarchy -- the visitor's flat callback model does not naturally
produce nested output. A stack-based approach in the visitor (push/pop
JSON objects on enter/leave) can work but adds complexity.

Scope

  • Evaluate whether the visitor pattern simplifies or complicates the
    JSON serialization code
  • If beneficial: implement a TJsonVisitor with a JSON object stack
  • If not beneficial: document the decision and close as won't-fix
  • If migrated: all existing JSON tests pass with identical output
  • FormFileToJSON and FormObjectToJSON public API unchanged

Acceptance criteria

  • Decision documented (migrate or skip with rationale)
  • If migrated: all JSON tests pass, public API unchanged
  • If skipped: ticket closed with explanation

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /