# bariskisir/fluent-validation-usage architecture

> Architecture diagram of the GitHub repository bariskisir/fluent-validation-usage, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bariskisir/fluent-validation-usage
- Repository: https://github.com/bariskisir/fluent-validation-usage

## Overview

This is a small ASP.NET Web Forms example demonstrating employee validation with FluentValidation. A user submits the employee form; the click handler builds an Employee, invokes EmployeeValidator, then displays validation messages or a success message. The validator defines age, name, and email rules. Source excerpts show this flow, but the README does not document additional capabilities.

Main entry points: [`src/fluentValidation-test/default.aspx.cs`](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx.cs) (Submit handler), [`src/fluentValidation-test/EmployeeValidator.cs`](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/EmployeeValidator.cs) (Employee validator), [`src/fluentValidation-test/default.aspx`](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx) (Employee form), [`src/fluentValidation-test/Employee.cs`](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/Employee.cs) (Employee)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web interaction"]
  node_form["Employee form<br/>[default.aspx]"]
  node_handler["Submit handler<br/>[default.aspx.cs]"]
  node_feedback["Validation feedback<br/>[default.aspx.cs]"]
end

subgraph group_validation["Validation domain"]
  node_employee["Employee<br/>[Employee.cs]"]
  node_validator["Employee validator"]
end

node_user(("User"))
node_fluentvalidation["FluentValidation"]
node_result["Validation result"]

node_user -->|"enters details"| node_form
node_form -->|"dispatches submit"| node_handler
node_handler -->|"populates fields"| node_employee
node_handler -->|"invokes validation"| node_validator
node_validator -->|"validates"| node_employee
node_validator -->|"uses rules API"| node_fluentvalidation
node_validator -->|"returns result"| node_result
node_handler -->|"renders outcome"| node_feedback

click node_form "https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx"
click node_handler "https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx.cs"
click node_feedback "https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx.cs"
click node_employee "https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/Employee.cs"
click node_validator "https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/EmployeeValidator.cs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_form,node_handler,node_feedback,node_user toneBlue
class node_employee,node_validator toneAmber
class node_fluentvalidation,node_result toneIndigo
```

## Components

### Web interaction

- [Employee form](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx): `src/fluentValidation-test/default.aspx`
- [Submit handler](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx.cs): `src/fluentValidation-test/default.aspx.cs`
- [Validation feedback](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/default.aspx.cs): `src/fluentValidation-test/default.aspx.cs`

### Validation domain

- [Employee](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/Employee.cs): `src/fluentValidation-test/Employee.cs`
- [Employee validator](https://github.com/bariskisir/fluent-validation-usage/blob/master/src/fluentValidation-test/EmployeeValidator.cs): `src/fluentValidation-test/EmployeeValidator.cs`

### Other components

- **User**
- **FluentValidation**
- **Validation result**

## Connections

- User → Employee form: enters details
- Employee form → Submit handler: dispatches submit
- Submit handler → Employee: populates fields
- Submit handler → Employee validator: invokes validation
- Employee validator → Employee: validates
- Employee validator → FluentValidation: uses rules API
- Employee validator → Validation result: returns result
- Submit handler → Validation feedback: renders outcome
