in reply to Re: Trying to decode JSON streaming from a website
in thread Trying to decode JSON streaming from a website
Should it not be using "sequenceNumber" as the reference and "1402012831" as the data? The line it fails on is print "$obj->{Value}{flowStartSeconds}: $obj->{Value}{senderCallsign}\n"; If I use Data::Dumper the first element looks like below, could it be I've got my JSON pointer wrong so it's not looking at the whole line?JSON Stream parser test Received: {"sequenceNumber":1402012831,"frequency":7077409,"mode":"JT65","sNR":- +21,"flowStartSeconds":1492208570,"senderCallsign":"EB5JRL","senderLoc +ator":"IM99SL","receiverCallsign":"ON3HPI","receiverLocator":"JO20et" +,"receiverDecoderSoftware":"JTDX v17.7"}, Can't use string ("1402012831") as a HASH ref while "strict refs" in u +se at client.pl line 38.
I'm not overly strong in OO Perl, I know I should how to use it more. Thanks$VAR1 = { 'Value' => 1402024539, 'Path' => '/sequenceNumber', 'JSONPointer' => '/^' };
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Trying to decode JSON streaming from a website
by Corion (Patriarch) on Apr 15, 2017 at 07:35 UTC |