58;
use URI::Escape;
use Encode qw(decode_utf8);
use Readonly;
use DateTime::Format::ISO8601;
use JSON;
use Web::Microformats2::Parser;
use Web::Mention::Author;
our $VERSION = '0.721';
Readonly my
b as_json {
my $self = shift;
return JSON->new->convert_blessed->encode( $self );
}
sub new_from_json {
my ($class, $json) = @_;
return $class->FROM_JSON( JSON->new->decode( $json ) )
led by the JSON module during JSON encoding.
# Contrary to the (required) name, returns an unblessed reference, not JSON.
# See https://metacpan.org/pod/JSON#OBJECT-SERIALISATION
sub TO_JSON {
my