Hmm... Ambitious.

Have you considered using XML? It's a standard, and there are classes that let you work with it efficiently enough to meet your needs.