FormCatalogEntry
Corex\Forms\Catalog\FormCatalogEntry · class · Forms layer
One form in the catalog, whatever kind of form it is. submissionCount is nullable on purpose: null means “nobody could tell us”, which is a different fact from zero and must not be flattened into one. Screens read {@see hasSubmissionCount()} rather than testing the integer, so an unmeasured form never renders as an empty one.
Public API
Section titled “Public API”create(string $slug, string $label, string $source, ?int $flowId, array $fields, ?int $declaredFieldCount, bool $active, bool $editableInBuilder, ?int $submissionCount, string $capability): self
Section titled “create(string $slug, string $label, string $source, ?int $flowId, array $fields, ?int $declaredFieldCount, bool $active, bool $editableInBuilder, ?int $submissionCount, string $capability): self”withSubmissionCount(?int $count): self
Section titled “withSubmissionCount(?int $count): self”fieldCount(): int
Section titled “fieldCount(): int”The number of fields, preferring real definitions over a declared total. A provider may know its count without being able to hand over the definitions; a code form always has the definitions themselves. Counting what we hold beats trusting what we were told.
hasSubmissionCount(): bool
Section titled “hasSubmissionCount(): bool”validationSummary(): string
Section titled “validationSummary(): string”A one-line “field: rule, rule” digest of the form’s validation, for the read-only view of a form nobody can open in the builder. Empty when no field declares a rule.