This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use Catmandu; | |
| my $var = ''; | |
| my $exporter = Catmandu->exporter('JSON', file => \$var); | |
| $exporter->add({ 'aaargh' => 'doedoedoe' }); | |
| $exporter->commit; | |
| print $var; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use Catmandu; | |
| use Data::Dumper; | |
| my $importer = Catmandu->importer('Mock'); | |
| # Create a store with a vey strict schema that always produces errors ... | |
| my $store = Catmandu->store('ElasticSearch', | |
| index_name => 'test2', | |
| bags => { data => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Hello Gwen | |
| How are you!! d sfkhushf s fksuhf ksuhfsalkufhusfkuhkhweuh fkudhauhf ahsdkufs f | |
| slfsdif jslfijsfi jslfijsfijosjfs;ifsij s |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use Catmandu::Importer::MARC; | |
| my $importer = Catmandu::Importer::MARC->new(file => "/foo/bar.marc", type=> "USMARC"); | |
| my $store = Catmandu::Store::MongoDB->new(database_name => 'test'); | |
| $store->bag->add_many($importer); |
NewerOlder