.\" Automatically generated by Pod::Man 2.28 (Pod::Simple 3.29) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{ . if \nF \{ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Swagger2::SchemaValidator 3pm" .TH Swagger2::SchemaValidator 3pm "2016-04-17" "perl v5.22.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Swagger2::SchemaValidator \- Sub class of JSON::Validator .SH "DESCRIPTION" .IX Header "DESCRIPTION" This class is used to validate Swagger specification. It is a sub class of JSON::Validator and adds some extra functionality specific for Swagger2. .SH "ATTRIBUTES" .IX Header "ATTRIBUTES" Swagger2::SchemaValidator inherits all attributes from JSON::Validator. .SS "formats" .IX Subsection "formats" Swagger support the same formats as Swagger2::SchemaValidator, but adds the following to the set: .IP "\(bu" 4 byte .Sp A padded, base64\-encoded string of bytes, encoded with a \s-1URL\s0 and filename safe alphabet. Defined by \s-1RFC4648.\s0 .IP "\(bu" 4 date .Sp An \s-1RFC3339\s0 date in the format YYYY-MM-DD .IP "\(bu" 4 double .Sp Cannot test double values with higher precision then what the \*(L"number\*(R" type already provides. .IP "\(bu" 4 float .Sp Will always be true if the input is a number, meaning there is no difference between \*(L"float\*(R" and \*(L"double\*(R". Patches are welcome. .IP "\(bu" 4 int32 .Sp A signed 32 bit integer. .IP "\(bu" 4 int64 .Sp A signed 64 bit integer. Note: This check is only available if Perl is compiled to use 64 bit integers. .SH "METHODS" .IX Header "METHODS" Swagger2::SchemaValidator inherits all attributes from JSON::Validator. .SS "validate_input" .IX Subsection "validate_input" This method will make sure \*(L"readOnly\*(R" is taken into account, when validating data sent to your \s-1API.\s0 .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" Copyright (C) 2014\-2015, Jan Henning Thorsen .PP This program is free software, you can redistribute it and/or modify it under the terms of the Artistic License version 2.0. .SH "AUTHOR" .IX Header "AUTHOR" Jan Henning Thorsen \- \f(CW\*(C`jhthorsen@cpan.org\*(C'\fR