APML in C#


APML stands for Attention Profiling Markup Language. If you've never heard of it, I'm not that shocked. It's one of those formats that is a fantastic concept but hasn't caught on 100% at this point. At the same time though, it's gaining some steam. So if that doesn't interest you, lets talk about what it actually does...

The concept behind APML is this, you have preferences when it comes to what you read (some that you realize and some that you don't). Going to websites should allow you to easily find this information but at present it's not that great. I mean even searching on Google takes a bit of work sometimes. So what if you could share a small bit of information with websites and let them sort their information so that what you want is what you see? That's what APML does (well sort of anyway). Really it's just a XML format that ranks phrases/words on a percentage basis (based on personal preferences), some of the info is defined by the user and some is defined by other items (RSS feeds, applications that you use, etc.).

Now that you've read about the format (by the way, definitely go to the APML website that I linked to above as they explain it better than myself), I'm sure that you've come up with a few ways to use the format. And most likely you want some code to create APML files of your own (and since you're here you most likely want it in C#). However I'm going to link to copy in my utility library on this one: APML.cs, Application.cs, Applications.cs, Author.cs, Body.cs, Concept.cs, Concepts.cs, Data.cs, Head.cs, Profile.cs, Source.cs, and  Sources.cs.

This one is similar to my OPML and RSS helpers. You can either load an APML file by stating the location of the file, loading an XML document, or doing so by hand and simply call ToString and it will give you a properly formatted APML file. It's commented and shouldn't be too difficult to use but definitely look at the format itself as items are named the same as in the format itself. Anyway, download the code, try it out, leave feedback, and happy coding.