github.com/kaptinlin/jsonschema@v0.4.6/examples/multiple-input-types/README.md (about)

     1  # Multiple Input Types Example
     2  
     3  Shows how to validate different input types with the same schema.
     4  
     5  ## What it shows
     6  
     7  - Validate JSON bytes, structs, and maps
     8  - Auto-detection with `Validate()` method
     9  - Type-specific methods: `ValidateJSON()`, `ValidateStruct()`, `ValidateMap()`
    10  
    11  ## Run
    12  
    13  ```bash
    14  go run main.go
    15  ```
    16  
    17  ## Output
    18  
    19  ```
    20  Multiple Input Types Demo
    21  ========================
    22  JSON bytes: ✅ Valid
    23  Go struct: ✅ Valid
    24  Map data: ✅ Valid
    25  
    26  Type-specific methods:
    27  ValidateJSON: ✅ Valid
    28  ValidateStruct: ✅ Valid
    29  ValidateMap: ✅ Valid
    30  ```