Archive for January, 2008

ActiveRecord: Overwriting attribute=

I always forget the command for doing this so I’m posting it here so I can find it easily.

If you want to overwrite accessors in rails (ActiveRecord), you will run into problems if you try to do it the same way you would with a regular Ruby object. For example, say you want to apply a transformation to an attribute as you assign it:

@person.name = 'ralph'

You always want name to be capitalized, so you would like to modify the name= method. With plain Ruby you would just do:

def name=(value)
@name = value.capitalize
end

You can’t do this with ActiveRecord, you will need to use a method named write_attribute so the method will look like:

def name=(value)
write_attribute(:name, value.capitalize)
end

There is also a read_attribute method to help with overwriting the read method on your attributes in ActiveRecord

Tagged with: ,

Utah Recording Studios

noisebox-studios.png

My brother Dave runs Noisebox Studios which offers the best value recording services of any Utah recording studio. Located in Orem, Utah, Noisebox Studios is a great choice for any band or music artist who is looking to get a top quality recording at an affordable price. If you are a musician in Utah Valley, definitely check out his studio. Dave’s use of state-of-the-art software, equipment, and deep music knowledge and talent make recording at Noisebox Studios the best choice for Utah artists.

State-of-the-art Software and Equipment

recording-equipment.jpgNoisebox Studios uses a variety of state-of-the-art software including Pro Tools 7.3 HD2, Sonar 6.2, and Melodyne 3 for pitch correction. The studio has a whole array of incredible equipment that I’m not going to even attempt to talk about since I don’t know what most of it actually does, but check out the studio pictures.

Deep Music Knowledge and Talent

Dave holds a Bachelor of Arts in Media Music from BYU which has given him a solid foundation in music composition, song writing, and instrumental performance. He is a very good drummer and pianist. He has 18 years of drumming experience and 22 years of piano experience. He studied percussion under Jay Lawrence and Dr. Ron Brough, and studied Jazz Piano under Jim Kirchner. During his time at BYU he played in various Jazz Combos, Panoramic Steel, Percussion Ensemble, and was the drum set player for the BYU Men’s Basketball pep band. While finishing school, Dave taught drum lessons at the Crescent School of Music in American Fork, Utah.

After graduation, he accepted a position as a sound engineer at Utah’s famous Tuacahn Amphitheater in St. George. There he met the band Kennedy, and he recorded their first album together. He now enjoys recording, mixing, and mastering music full-time at Noisebox Studios.

Bands and Artists Recorded

Artists that Noisebox Studios has recorded, mixed, and/or mastered include Truman, BYU’s 2007 Battle of the Bands winner; Kennedy, a popular local band of St. George; Mark “Fingermix” Smith, who is a past Pearl award winner. Check out the Noisebox demos page to hear some of the songs and see some of the other artists that have been recorded, mixed, and/or mastered at the studio.

Services Offered

* Recording - vocal, instrumental, audio books, and podcasts
* Mixing - even if you’ve recorded your own music
* Mastering
* Composition - full orchestrated compositions to accompany video, games, etc.

Tagged with: , ,

How To Innovate

light_bulb.jpg

I believe that most innovation comes from the question “How would I rather do this?” It seems pretty simple and obvious, but I can’t imagine a scenario where that question wouldn’t have been asked before something great had been created.

Just a thought to keep in mind.

Tagged with:

Blog posting to Google result in 20 minutes

Today I was looking for some xml matchers for RSpec so I googled ‘xml matchers rspec’, clicked on the first result, which happened to be exactly what I was looking for, and I posted a comment. After posting the comment, I realized that the post had only been up for 22 minutes! That is the fastest turnaround I’ve ever seen from blog post to Google results. Wow.

I was so amazed that I took some screenshots:

google_search.png

wolfman_blog_post.png

Anyways, if you’re into RSpec and doing much with XML document creation, his matchers seem to be a great way to verify that your documents are being created correctly. Thank you.

Tagged with: , ,