Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
peczenyj committed Dec 17, 2023
1 parent 469d2fb commit b7f3001
Showing 1 changed file with 21 additions and 4 deletions.
25 changes: 21 additions & 4 deletions README.pod
Original file line number Diff line number Diff line change
Expand Up @@ -114,14 +114,33 @@ or
date_format => '%Y%m%d', # yyymmdd
},
strict => 1,
prefetch => 284,
);

Parse may receive an optional hash of parameters: C<strict> (boolean) and C<json> (hashref with the following properties):
Parse may receive an optional hash with the following parameters:

=over

=item *

On C<strict> mode we will validate if the version of the consent string is the version 2 (or die with an exception).

The C<strict> mode is disabled by default.

=item *

The C<prefetch> option receives one (as scalar) or more (as arrayref) vendor ids.

This is useful when parsing a range based consent string, since we need to visit all ranges to find a particular id.

=item *

C<json> is hashref with the following properties used to customize the json format:

=over

=item *

C<verbose> changes the json encoding. By default we omit some false values such as C<vendor_consents> to create
a compact json representation. With C<verbose> we will present everything. See L</TO_JSON> for more details.

Expand Down Expand Up @@ -150,9 +169,7 @@ except if the option C<use_epoch> is true.

=back

On C<strict> mode we will validate if the version of the consent string is the version 2 (or die with an exception).

The C<strict> mode is disabled by default.
=back

=head1 METHODS

Expand Down

0 comments on commit b7f3001

Please # to comment.