I'm not in Melbourne (give me a few years), but I thought I'd put in my €0.02.<div><br></div><div>You might also want to look into Moose and/or MooseX::Declare. Mx::D gives you some nice syntax for defining methods and the parameters passed, while Moose gives you a nicer OO interface. </div>
<div><br></div><div>Regarding source filtering, Just Don't Do It. Ricardo Signes' review of Filter::Simple says it all: "<span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: 14px; line-height: 21px; ">Don't write source filters. They will make your momma cry." </span>Moose (or perhaps Devel::Declare if you want to go really low-level) is a much better way to achieve the same effect and keep you sane. :-)</div>
<div><br></div><div>Drew</div><div><br><div class="gmail_quote">On Tue, Feb 9, 2010 at 4:25 AM, Sam Watkins <span dir="ltr"><<a href="mailto:sam@nipl.net">sam@nipl.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
hi,<br>
<br>
I'm writing a program in Perl to incrementally "slurp" data from<br>
facebook, to nice YAML and TSV files (like wget -c). It's not finished<br>
yet but it is working for profile info and streams (your wall, others'<br>
walls, status updates feed). I haven't got it to slurp comments yet.<br>
<br>
The streams are presented as simple readable TSV files, for use with<br>
grep, etc, having lines like this:<br>
<br>
2010/02/06 01:03:54 Sam Watkins uploaded my first video to youtube, it's a funny thing I did with a flash game "Cargo Bridge" (armor games edition): <a href="http://www.youtube.com/watch?v=uguxuuAn4qo" target="_blank">http://www.youtube.com/watch?v=uguxuuAn4qo</a><br>
<br>
The date comes first and is sortable! (unlike apache logs) so it's a<br>
simple matter to merge several streams for example.<br>
<br>
Thanks to PJF for his facebook example script which was very helpful<br>
with getting started. I'll post again when I've finished it.<br>
<br>
<br>
I also wrote Filter::Self last night, it uses Damien's Filter::Simple to<br>
add some nicer OO / function call syntax to perl. This has I suppose<br>
been done before, anyway you can do things like this:<br>
<br>
this code: becomes:<br>
---------- --------<br>
print .name; print $self->{name};<br>
.recalc($alpha); $self->recalc($alpha);<br>
sub say($str) { sub say {<br>
my ($str) = @_;<br>
sub .recalc($alpha) { sub recalc {<br>
my ($self, $alpha) = @_; shift;<br>
print .foo.bar.baz; print $self->{foo}{bar}{baz};<br>
<br>
I think that makes it a lot easier / briefer to do OO in perl, it's more<br>
like java, actually sort of inspired by visual basic! I like this<br>
syntax anyway. This is pretty much finished, and there is a tgz here:<br>
<br>
<a href="http://sam.nipl.net/code/filter-self/" target="_blank">http://sam.nipl.net/code/filter-self/</a><br><br>
</blockquote></div><br></div>