Programming pattern: Temporary data

Temporary data is a simple pattern that I use while I’m trying to get some code working. The inverse of Temporary data is that you get the data, for example, from a database. The code you have to write to get the data from the database is often many times as long as the code you need to specify the data structure. my $languages = [ { code => 'nl', name => 'Nederlands' }, { code => 'en', name => 'English' }, ]; If you would like to get this same data structure from your database you have to do a lot of work before this works....

August 4, 2009