Real Time Coding!


Back a few years ago, I would hang out with software engineers and developers and we would code with each other code while drinking beer and vodka.   We would make mistakes, laugh with each other, learn new things and have a good time writing software and exploring new ideas.  Many years have passed, extra kids, demanding job, and busy lives... but while watching a live stream on for game I was playing - I was thinking, "I wonder if I could code online, I could still hang out with people having fun coding with them?"  

And there was my  < light bulb > moment.

Today I will start inviting friends to come watch, and participate in my coding ventures.  Watch my coding precess, laugh at my mistakes, and cheer when things work.  Then it occured to me I had no idea how to broadcast.   I have done quite a bit of audio production, but video... not so much.   After some research I chose, and OBS to start.   It wasn't hard to set up and it seemed to work pretty good.  Not being a AV guy I ran into some issue with bit-rate, HD, and a few other odds and ends, but for a first rough pass it is in my opinion: "better than sucks".

Our new page is here:

You can click into Justin.Tv and chat in real time while we work or just watch, and drink beer.   Check it out and follow the page so you will be notified when we are online doing stuff to FrameWork Sites!

Arrays and Hash Methods

Tags: Developer

Someone asked me the other day, "Why do FWS array & hash methods have the word 'hash' and 'array' in them ( i.e. somethingHash() and somethingArray() )?"   What a great question!  So I figured I would write a little article about why that was done - because it wasn't the first time someone asked :)

Method names in FWS have a theme to help people that write in different languages or are new to programming, make it easier to get started.  There are a couple more conventions like this if your familiar with FWS, but the convention we will cover here are arrays & hashes.   When getting data from default methods of FWS you usually are getting arrays of hashes or a single hash.   Here is an example:

my @dataArray = $fws->dataArray( type=> 'this_type' );

This will give me back an array of hashes of anything that matches this type.  For a single hash that would have been returned you would retrieve it like:

my %dataHash = $fws->dataHash( guid => 'some_guid' );

And this theme is repeated pretty much anywhere that uses arrays of hashes.  There is one extra piece that is handy for advanced FWS coders, and that is the use of a reference.   The other convention is the ability to use the ref => 1 into the parameters, when used you will retrieve the array as an array reference.  This is great for larger arrays, and are more efficient in general because your pointing at the list, not copying it to a new array every time you ask for it.

my $dataArrayRef = $fws->dataArray( type=> 'this_type', ref => 1 );

The idea of references sometimes takes a few for new Perl programmers to pick up, but once you get the hang of them, you should use the ref => 1 all the time.



Host Your FrameWork Sites Website At iPage for $1.99 a Month!