How whitebeardit/next-cnpj works
next-CNPJ is a .NET library for validating traditional numeric and NTC 2025.001 alphanumeric CNPJ identifiers. A caller submits an identifier to the validator, which normalizes it, checks length and structure, identifies its format, applies configurable excluded-letter rules, and verifies check digits; it returns a detailed result or a boolean. The library also exposes format identification and CNPJ mask formatting as separate utilities. The graph reflects the sampled implementation and README; unsampled modules are not assumed to have additional runtime connections.
Main entry points: CnpjValidator.cs CNPJ validator · CnpjFormatIdentifier.cs Format identifier · CnpjNormalizer.cs CNPJ normalizer · CnpjValidationResult.cs Validation result
Components 12
Validation API
- CNPJ validator
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - Validator contract
next-CNPJ/next-CNPJ/Core/Services/ICnpjValidator.cs - Format identifier
next-CNPJ/next-CNPJ/Core/Services/CnpjFormatIdentifier.cs - Identifier contract
next-CNPJ/next-CNPJ/Core/Services/ICnpjFormatIdentifier.cs
Validation Domain
- Validation configuration
next-CNPJ/next-CNPJ/Core/Domain/CnpjConfiguration.cs - Validation result
next-CNPJ/next-CNPJ/Core/Domain/CnpjValidationResult.cs - CNPJ format enum
next-CNPJ/next-CNPJ/Core/Domain/CnpjFormat.cs
CNPJ Utilities
- CNPJ normalizer
next-CNPJ/next-CNPJ/Core/Utilities/CnpjNormalizer.cs - Mask formatter
next-CNPJ/next-CNPJ/Core/Utilities/CnpjFormatter.cs - Check-digit calculator
next-CNPJ/next-CNPJ/Core/Utilities/DigitVerifierCalculator.cs - ASCII converter
next-CNPJ/next-CNPJ/Core/Utilities/AsciiConverter.cs
Other components
- Library caller
Connections 13
- Library caller → CNPJ validator: submits CNPJ
README.md - CNPJ validator → CNPJ normalizer: normalizes input
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - CNPJ validator → Format identifier: identifies format
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - CNPJ validator → Validation configuration: checks letter rules
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - CNPJ validator → Check-digit calculator: validates digits
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - CNPJ validator → Validation result: returns details
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - CNPJ validator → Validator contract: implements contract
next-CNPJ/next-CNPJ/Core/Services/CnpjValidator.cs - Format identifier → CNPJ normalizer: normalizes input
next-CNPJ/next-CNPJ/Core/Services/CnpjFormatIdentifier.cs - Format identifier → Identifier contract: implements contract
next-CNPJ/next-CNPJ/Core/Services/CnpjFormatIdentifier.cs - Format identifier → CNPJ format enum: returns format
next-CNPJ/next-CNPJ/Core/Services/CnpjFormatIdentifier.cs - Validation result → CNPJ format enum: stores format
next-CNPJ/next-CNPJ/Core/Domain/CnpjValidationResult.cs - Mask formatter → CNPJ normalizer: normalizes input
next-CNPJ/next-CNPJ/Core/Utilities/CnpjFormatter.cs - Check-digit calculator → ASCII converter: converts characters
next-CNPJ/next-CNPJ/Core/Utilities/DigitVerifierCalculator.cs