File: Module.pm

package info (click to toggle)
libjson-validator-perl 3.06%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 616 kB
  • sloc: perl: 1,308; makefile: 6
file content (16 lines) | stat: -rw-r--r-- 388 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
package Some::Module;
use Mojo::Base 'Some';

sub validate_age0 { shift->j->schema('data:///age0.json')->validate(shift) }
sub validate_age1 { shift->j->schema('data://Some::Module/age1.json')->validate(shift) }

1;
__DATA__
@@ age1.json
{
  "title": "Some module",
  "type": "object",
  "properties": {
    "age": { "type": "integer", "minimum": 1, "description": "Age in years" }
  }
}