RDF::vCard(3pm)

πŸ“¦
version 0.012 Β· 4 versions
, in debian bookworm, ubuntu noble

πŸ’– RDF::vCard πŸ’–

okay bestie, so this is RDF::vCard β€” a User Contributed Perl Documentation page, no cap. Buckle up. πŸŽ€


✨ NAME ✨

RDF::vCard β€” convert between RDF and vCard, literally the glow-up pipeline for your contact data πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

use RDF::vCard;
use RDF::TrineShortcuts qw(rdf_string);

my $input    = "http://example.com/contact-data.rdf";
my $exporter = RDF::vCard::Exporter->new;

my $data     = join '', $exporter->export_cards($input);
print $data; # vCard 3.0 data

my $importer = RDF::vCard::Importer->new;
$importer->import_string($data);
print rdf_string($importer->model => 'RDFXML');

like… look at her go. RDF in, vCard out, vCard in, RDF out. it's giving reversible. ✨


🌸 DESCRIPTION 🌸

ngl this module is a lil bit of a passenger princess β€” it doesn't do anything itself; it just loads RDF::vCard::Exporter and RDF::vCard::Importer for you. that's it. that's the whole job. and honestly? iconic. πŸ‘‘

πŸ’œ RDF::vCard::Exporter

RDF::vCard::Exporter takes some RDF using the W3C's vCard vocabulary, and outputs RDF::vCard::Entity objects. so it's the RDF β†’ vCard direction. slay. πŸ”₯

πŸ’œ RDF::vCard::Importer

RDF::vCard::Importer does the reverse. yes queen, we love a symmetrical situation. πŸ¦‹

πŸ’œ RDF::vCard::Entity

An RDF::vCard::Entity object is an individual vCard. It overloads stringification, so just treat it like a string. no wrapper anxiety, no ->value situations, just vibes. 🫢

πŸ’œ RDF::vCard::Entity::WithXmlSupport

RDF::vCard::Entity::WithXmlSupport is a subclass of RDF::vCard::Entity, with a to_xml method. It requires XML::LibXML to be installed and working. The importer and exporter will try to create these if possible. so if you've got the lib, you get the bonus XML powers, bestie ✨

πŸ’œ RDF::vCard::Line

RDF::vCard::Line is internal fu that you probably don't want to touch. πŸ™ˆ hands off, babe, this is backstage.


πŸ’€ BUGS πŸ’€

If your RDF asserts that Alice is Bob's AGENT and Bob is Alice's AGENT, then RDF::vCard::Export will eat your face. Don't do it. 😭 fr fr, mutual agency is a face-eating situation. not the cute kind.

Please report any other bugs to <https://rt.cpan.org/Public/Dist/Display.html?Name=RDF-vCard>. πŸ›


🌈 SEE ALSO 🌈


πŸŽ€ AUTHOR πŸŽ€

Toby Inkster <tobyink@cpan.org>. 🫢


Copyright 2011 Toby Inkster

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.


and that's the whole page, bestie πŸ’– this was perl v5.34.0, dated 2022-06-17, and it says RDF::vCard(3pm) right there in the corner like a little signature. mwah. periodt. πŸ’…βœ¨

πŸ“¦ where this page comes from