<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: &#8220;AkitaOnRails&#8221; On Ruby Symbols</title>
	<atom:link href="http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/feed/" rel="self" type="application/rss+xml" />
	<link>http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/</link>
	<description>Helping Ruby Programmers become Awesome</description>
	<lastBuildDate>Wed, 08 Feb 2012 15:25:03 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
	<item>
		<title>By: Abdul Basit</title>
		<link>http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/comment-page-1/#comment-133179</link>
		<dc:creator>Abdul Basit</dc:creator>
		<pubDate>Wed, 19 Oct 2011 10:48:54 +0000</pubDate>
		<guid isPermaLink="false">http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/#comment-133179</guid>
		<description>Hi Koti,
  the methods like before_filter accepts parameter in string format(as symbols are special type of string)

Using eval() method, it is possible to execute the methods, by giving the method name as a string.

eval() can also be used to execute ActiveRecord methods.

eg, 

model_name = &quot;user&quot;
method_name = &quot;find_by_name&quot;
eval(model_name.capitalize + &#039;.&#039; + method_name +&#039; India&#039;)  # this is same as Country.find_by_name(&#039;India&#039;)
---------------------------------------

The explanation is not for, how before_filter is doing this. But this is one way for doing the same.</description>
		<content:encoded><![CDATA[<p>Hi Koti,<br />
  the methods like before_filter accepts parameter in string format(as symbols are special type of string)</p>
<p>Using eval() method, it is possible to execute the methods, by giving the method name as a string.</p>
<p>eval() can also be used to execute ActiveRecord methods.</p>
<p>eg, </p>
<p>model_name = &#8220;user&#8221;<br />
method_name = &#8220;find_by_name&#8221;<br />
eval(model_name.capitalize + &#8216;.&#8217; + method_name +&#8217; India&#8217;)  # this is same as Country.find_by_name(&#8216;India&#8217;)<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</p>
<p>The explanation is not for, how before_filter is doing this. But this is one way for doing the same.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: koteswara rao</title>
		<link>http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/comment-page-1/#comment-132211</link>
		<dc:creator>koteswara rao</dc:creator>
		<pubDate>Sat, 13 Aug 2011 12:50:20 +0000</pubDate>
		<guid isPermaLink="false">http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/#comment-132211</guid>
		<description>Hi sir,i’m koti.i just came to know ruby.You explained well.But there is a little bit confusion to use symbols.You said that we can use symbols instead of strings.But i saw so many methods using symbol like this
before_filter :add_to_numbers
actually here add_to_numbers is a method but the method added with colon(:).so if we add colon to method,then what is meaning of that method included with colon?
could you clarify my doubt please</description>
		<content:encoded><![CDATA[<p>Hi sir,i’m koti.i just came to know ruby.You explained well.But there is a little bit confusion to use symbols.You said that we can use symbols instead of strings.But i saw so many methods using symbol like this<br />
before_filter :add_to_numbers<br />
actually here add_to_numbers is a method but the method added with colon(:).so if we add colon to method,then what is meaning of that method included with colon?<br />
could you clarify my doubt please</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nicholaus Hughes</title>
		<link>http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/comment-page-1/#comment-131109</link>
		<dc:creator>Nicholaus Hughes</dc:creator>
		<pubDate>Tue, 10 May 2011 00:13:00 +0000</pubDate>
		<guid isPermaLink="false">http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/#comment-131109</guid>
		<description>Awesome. Clear and Concise.

I appreciate a simple explanation about something that doesn&#039;t need to be complicated.</description>
		<content:encoded><![CDATA[<p>Awesome. Clear and Concise.</p>
<p>I appreciate a simple explanation about something that doesn&#8217;t need to be complicated.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rahul</title>
		<link>http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/comment-page-1/#comment-129576</link>
		<dc:creator>rahul</dc:creator>
		<pubDate>Wed, 22 Dec 2010 13:08:34 +0000</pubDate>
		<guid isPermaLink="false">http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/#comment-129576</guid>
		<description>The concept was presented in clear words and precise text.
I have a question here, in the rails world, there are many symbols that are being used. As a first time learner, how do i know which symbols are available?</description>
		<content:encoded><![CDATA[<p>The concept was presented in clear words and precise text.<br />
I have a question here, in the rails world, there are many symbols that are being used. As a first time learner, how do i know which symbols are available?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: emmanuel delgado</title>
		<link>http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/comment-page-1/#comment-126774</link>
		<dc:creator>emmanuel delgado</dc:creator>
		<pubDate>Wed, 20 Oct 2010 13:28:17 +0000</pubDate>
		<guid isPermaLink="false">http://rubylearning.com/blog/2007/11/26/akitaonrails-on-ruby-symbols/#comment-126774</guid>
		<description>&lt;span class=&quot;topsy_trackback_comment&quot;&gt;&lt;span class=&quot;topsy_twitter_username&quot;&gt;&lt;span class=&quot;topsy_trackback_content&quot;&gt;http://bit.ly/6zCTH is a great ruby symbols explanation,  reading and understanding it is a must for  every  ruby beginner&lt;/span&gt;&lt;/span&gt;</description>
		<content:encoded><![CDATA[<p><span class="topsy_trackback_comment"><span class="topsy_twitter_username"><span class="topsy_trackback_content"><a href="http://bit.ly/6zCTH" rel="nofollow">http://bit.ly/6zCTH</a> is a great ruby symbols explanation,  reading and understanding it is a must for  every  ruby beginner</span></span></span></p>
]]></content:encoded>
	</item>
</channel>
</rss>

