ValidTXT
in package
Validation for TXT representation of NFe
Tags
Table of Contents
Constants
Methods
- isValid() : array<string|int, mixed>
- Verifies the validity of txt according to the rules of the code If is valid returns empty array Else return array with errors
- loadStructure() : mixed
- Loads structure of txt from json file in storage folder
Constants
LOCAL
public
mixed
LOCAL
= "LOCAL"
LOCAL_V12
public
mixed
LOCAL_V12
= "LOCAL_V12"
LOCAL_V13
public
mixed
LOCAL_V13
= "LOCAL_V13"
RTC
public
mixed
RTC
= "RTC"
SEBRAE
public
mixed
SEBRAE
= "SEBRAE"
Methods
isValid()
Verifies the validity of txt according to the rules of the code If is valid returns empty array Else return array with errors
public
static isValid(string $txt[, string $baselayout = self::LOCAL ]) : array<string|int, mixed>
Parameters
- $txt : string
- $baselayout : string = self::LOCAL
Return values
array<string|int, mixed>loadStructure()
Loads structure of txt from json file in storage folder
public
static loadStructure([float $version = 4.0 ][, string $baselayout = self::LOCAL ]) : mixed
Parameters
- $version : float = 4.0
- $baselayout : string = self::LOCAL