[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Newbie question about the # symbol

Justin

3/14/2006 1:21:00 PM

I have just started learning Ruby and I am going through as much
documentation as I can find. The only question that I cannot seem to
find an answer to concerns the use of the # symbol when referring to
methods (I think I've seen it used to refer to both class and instance
methods).

Here is an example:
http://www.rubycentral.com/book/ref_c_io.html...

On the above page there is a link to "Kernel#select" which is a class
method.

and here:
http://www.rubycentral.com/book/ref_c_object.html#Obje...

There is a link to "Object#kind_of?" which is an instance method.
Clearly the purpose of the hash mark has another purpose. Anyone know
what document explains this?

Thanks!
Justin

--
Posted via http://www.ruby-....


15 Answers

Tim Hunter

3/14/2006 1:29:00 PM

0

# is not Ruby syntax, it's a documentation convention that denotes
"instance method," as in "kind_of? is an instance method of Object" as
opposed to "class method," which is distinguished by a period between
the class name and the method name.

Mike Fletcher

3/14/2006 1:36:00 PM

0

Justin wrote:

> There is a link to "Object#kind_of?" which is an instance method.
> Clearly the purpose of the hash mark has another purpose. Anyone know
> what document explains this?

The notation's explained in the preface:

http://www.rubycentral.com/book/prefac...

Basically it means "the instance method kind_of? implemented by the
Object class"; not really syntax, but convention for discussing Ruby.
The 'ri' utility uses something similar.

--
Posted via http://www.ruby-....


James Gray

3/14/2006 1:44:00 PM

0

On Mar 14, 2006, at 7:33 AM, rmagick@gmail.com wrote:

> # is not Ruby syntax, it's a documentation convention that denotes
> "instance method," as in "kind_of? is an instance method of Object" as
> opposed to "class method," which is distinguished by a period between
> the class name and the method name.

Class methods are also often shown as follows:

MyClass::class_method

ri even seems to favor this notation.

James Edward Gray II


James Gray

3/14/2006 1:45:00 PM

0

On Mar 14, 2006, at 7:20 AM, Justin wrote:

> Here is an example:
> http://www.rubycentral.com/book/ref_c_io.html...
>
> On the above page there is a link to "Kernel#select" which is a class
> method.

Actually, all the Kernel methods are instance methods, so they can be
mixed into Object.

James Edward Gray II


Justin

3/14/2006 1:47:00 PM

0

Mike Fletcher wrote:
> Basically it means "the instance method kind_of? implemented by the
> Object class"; not really syntax, but convention for discussing Ruby.
> The 'ri' utility uses something similar.

Ahh ok, excellent thank you that was confusing me quite a bit.

--
Posted via http://www.ruby-....


emf

10/10/2013 10:48:00 AM

0

On 2013-10-08 16:48 vjp2.at@at.BioStrategist.dot.dot.com wrote:
> WHO was borrowing? In 1981 the Greek debt:GDP was 35%, when Andreas took over
> until 1991; it was 100% and stayed that way until 2009 when Yoryaki took over
> and rose it to 145% in 2012. Go look it up, it's all over the internet.
>
> What galls most of the developed world is that most Greeks STILL think there
> is nothing wrong with having LIED about the debt. THey have no remorse
> whatsoever. Like any other schizoparanoid they believe it was natural
> behavior. That's why the it keeps blowing up like Dimitra Liani's boobs,
> slattering all over the face of Greece.
>
>
> - = -
> Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus, BioStrategist
> http://www.panix.com/~vjp2...
> ---{Nothing herein constitutes advice. Everything fully disclaimed.}---
> [Homeland Security means private firearms not lazy obstructive guards]
> [Urb sprawl confounds terror] [Phooey on GUI: Windows for subprime Bimbos]

Actually yesterday Costas Gavras addressed the issue. What he stressed,
however, was that the Germans and the French knew quite well that Greece
would not be able to pay back to the loans and still kept giving them
more. It was a marvelous evening, I really enjoyed it.

emf

--
???? ?????????????????? ?????? ????????????????????
https://files.nyu.edu/emf202/public/fr/lime...

Demetre

10/10/2013 11:05:00 AM

0

On 10/10/2013 6:47 AM, emf wrote:
> On 2013-10-08 16:48 vjp2.at@at.BioStrategist.dot.dot.com wrote:
>> WHO was borrowing? In 1981 the Greek debt:GDP was 35%, when Andreas
>> took over
>> until 1991; it was 100% and stayed that way until 2009 when Yoryaki
>> took over
>> and rose it to 145% in 2012. Go look it up, it's all over the internet.
>>
>> What galls most of the developed world is that most Greeks STILL think
>> there
>> is nothing wrong with having LIED about the debt. THey have no remorse
>> whatsoever. Like any other schizoparanoid they believe it was natural
>> behavior. That's why the it keeps blowing up like Dimitra Liani's boobs,
>> slattering all over the face of Greece.
>>
>>
>> - = -
>> Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus,
>> BioStrategist
>> http://www.panix.com/~vjp2...
>> ---{Nothing herein constitutes advice. Everything fully
>> disclaimed.}---
>> [Homeland Security means private firearms not lazy obstructive
>> guards]
>> [Urb sprawl confounds terror] [Phooey on GUI: Windows for subprime
>> Bimbos]
>
> Actually yesterday Costas Gavras addressed the issue. What he stressed,
> however, was that the Germans and the French knew quite well that Greece
> would not be able to pay back to the loans and still kept giving them
> more. It was a marvelous evening, I really enjoyed it.
>
> emf
>
Why didn't they say NO MAS,ohi alo,only a corrupt person accepts easy
money-Gavras is using the leftist theory that the people are never wrong
it is always the foreigners,Larisa has the highest per capita number of
Porche Cayennes($90,000 each) the poor distixismeni Ellines needed a
car,only a BMW (beba in Greek slang)or Mercedes will do, I don't have to
remind anybody where are those cars made. I wonder how many tons of
olives it will take to get a Mercedes, please don't listen to excuses
time to pick the olives!!!


--
(...?? ???????????????????? ???????????????????? ???? ?????????? ?????? ??????????????, ???????????????? ?????????? ??????
?????????? ?? ???????????????????? ?????? ?? ???????????????? Kondilis)

emf

10/11/2013 10:20:00 AM

0

On 2013-10-10 07:05 Diamond69 wrote:
> On 10/10/2013 6:47 AM, emf wrote:
>> On 2013-10-08 16:48 vjp2.at@at.BioStrategist.dot.dot.com wrote:
>>> WHO was borrowing? In 1981 the Greek debt:GDP was 35%, when Andreas
>>> took over
>>> until 1991; it was 100% and stayed that way until 2009 when Yoryaki
>>> took over
>>> and rose it to 145% in 2012. Go look it up, it's all over the internet.
>>>
>>> What galls most of the developed world is that most Greeks STILL think
>>> there
>>> is nothing wrong with having LIED about the debt. THey have no remorse
>>> whatsoever. Like any other schizoparanoid they believe it was natural
>>> behavior. That's why the it keeps blowing up like Dimitra Liani's boobs,
>>> slattering all over the face of Greece.
>>>
>>>
>>> - = -
>>> Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus,
>>> BioStrategist
>>> http://www.panix.com/~vjp2...
>>> ---{Nothing herein constitutes advice. Everything fully
>>> disclaimed.}---
>>> [Homeland Security means private firearms not lazy obstructive
>>> guards]
>>> [Urb sprawl confounds terror] [Phooey on GUI: Windows for subprime
>>> Bimbos]
>>
>> Actually yesterday Costas Gavras addressed the issue. What he stressed,
>> however, was that the Germans and the French knew quite well that Greece
>> would not be able to pay back to the loans and still kept giving them
>> more. It was a marvelous evening, I really enjoyed it.
>>
>> emf
>>
> Why didn't they say NO MAS,ohi alo,only a corrupt person accepts easy
> money-Gavras is using the leftist theory that the people are never wrong
> it is always the foreigners,

Dear Diamond69.

But I do not think that there is any doubt that many of our compatriots
are to be blamed for the economic catastrophe! The problem is, I am not
sure that these are the ones who suffer the consequences.

During the long conversation Costas Gavras, now 80, spoke of many and
interesting things. About his immigration to France, his movies, etc. I
went early enough to be on the third row, right behind the reserved
seats, and actually quite close to the mother of the young man who was
the /Missing/ in the film with the same name. It was certainly one of
the highlights of the year for me.

Cheers,

emf

--
It ain't THAT, babe! - A radical reinterpretation
https://files.nyu.edu/emf202/public/bd/itaintm...

emf

10/11/2013 10:58:00 AM

0

On 2013-10-08 16:48 vjp2.at@at.BioStrategist.dot.dot.com wrote:
> WHO was borrowing? In 1981 the Greek debt:GDP was 35%, when Andreas took over
> until 1991; it was 100% and stayed that way until 2009 when Yoryaki took over
> and rose it to 145% in 2012. Go look it up, it's all over the internet.
>
> What galls most of the developed world is that most Greeks STILL think there
> is nothing wrong with having LIED about the debt. THey have no remorse
> whatsoever. Like any other schizoparanoid they believe it was natural
> behavior. That's why the it keeps blowing up like Dimitra Liani's boobs,
> slattering all over the face of Greece.
>
>
> - = -
> Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus, BioStrategist
> http://www.panix.com/~vjp2...
> ---{Nothing herein constitutes advice. Everything fully disclaimed.}---
> [Homeland Security means private firearms not lazy obstructive guards]
> [Urb sprawl confounds terror] [Phooey on GUI: Windows for subprime Bimbos]

Dear Vaso.

Since you live in Long Island, I think you would find it interesting to
attend this event. The panel is excellent, and the current situation in
Greece critical!

Stathis

****************************

Astoria: Public Meeting on Greece, Oct. 12

You are invited to a public meeting on the Greek situation and future
this Saturday, Oct. 12, 5 pm at the Church of the Redeemer in Astoria.

(English leaflet & poster can be downloaded online at www.AKNY.org)


Politics and the Crisis in Greece
After the Crackdown on ???Golden Dawn???
WHAT IS THE LEFT ALTERNATIVE?


FOR IMMEDIATE RELEASE:

On September 18, Pavlos Fyssas, an internationally known hip-hop artist,
anti-fascist and left activist, was assassinated by members of the
neo-Nazi party Golden Dawn (G.D.). Fyssas and six friends were assaulted
by 30-40 members of a G.D. ???attack battalion.??? Fyssas was stabbed to
death in what the coroner attested was not an amateur hit. In response
to the assassination, hundreds of thousands of outraged people took to
the streets in Greece, with solidarity protests in a dozen European
cities as well as New York and Tokyo.

After years of failing to prosecute acts of violence attributed to
Golden Dawn, the Greek government of New Democracy and PASOK finally
struck against the neo-Nazis on Sept. 28. About 40 G.D. leaders,
parliamentarians and party members have been arrested. They are charged
with running a criminal organization responsible for 32 cases of
violence, including 10 alleged murders and attempted murders. This
forces us to ask: Why were the first nine cases not enough to prompt action?

For years, Greek authorities tolerated and even protected G.D.???s
violence against immigrants, gays, leftists, anarchists, artists and
others. In the week after Fyssas??? murder two top police officials with
alleged G.D. links resigned suddenly for ???personal reasons.??? Many
examples show G.D.???s violence worked in the service of avoiding change,
eliminating dissent, and defending dominant economic interests and
social structures. A week before the murder, the G.D. ???attack battalion???
assaulted and injured Communist Party (KKE) members, apparently because
they were organizing shipyard workers against wage
cuts.

G.D.???s violence, we submit, serves the same functions as the violence of
the Greek government.

In both cases, those who demand social change are seen as enemies. The
government suppresses peaceful protest with tear gas and mass arrests.
Central Athens is shut down by thousands of police troops whenever EU
officials visit to oversee the Greek austerity program. When transit
workers and then teachers tried to strike, the government declared
martial law, issuing conscription orders to strikers and threatening to
charge them with treason and imprison them. Thus, the austerity policies
have not only created social conditions that allowed anti-immigrant
sentiment and neo-Nazi sects to flourish. They have also gone
hand-in-hand with ever-more authoritarian attempts to eliminate
political challenges and social protest. To frighten voters into
accepting authoritarian measures, the government presents a ???narrative
of the two extremes,??? attempting to equate left opposition parties with
Nazis.

Two-thirds of people under 30 are unemployed, pensions and wages for
most have been cut by 30-50 percent or more. But the resulting popular
discontent and anger fails to register with the political machinery. Two
weeks ago, the University of Athens was forced to shut down altogether
due to budget cuts! Yet the government bizarrely declares success after
success, and expects everyone to play along with its charade. Even
during Prime Minister Samaras??? visit to New York, he presented a false
picture of unity behind his government???s policies.

On October 12, the Greek left of New York will present a radically
different picture.

We will discuss and debate alternatives the left in Greece offers for
moving past the country???s crises. We invite the Greek-American community
to take part and we also invite all New Yorkers. (The main language of
the meeting will be English, but people are also welcome to speak in
Greek; translations from Greek will be provided.) Developments in Greece
are part of a global crisis that also affects the United States. Greece
has become capitalism???s testing ground to see how much pain a people can
take. The lessons learned in Greece are already being applied in other
countries, including in parts of the U.S.

END THE POLITICS OF AUSTERITY. RESTORE DEMOCRACY NOW!

With:

KOSTIS KARPOZILOS
Historian, Columbia University
Writer of documentary ???Greek American Radicals???

DESPINA LALAKI
Sociologist, NYU/New School
AKNY-Greece Solidarity Movement

PETER BRATSIS
Asst. Professor of Political Science, CUNY
Member, SYRIZA NY

IANNIS DELATOLAS
Anti-fascist, activist
Member, Antarsya

Sponsored by:

??? AKNY-Greece Solidarity Movement (www.AKNY.org)
??? Syriza-New York (www.syriza-ny.org) ??? Antarsya NY
??? ANTARSYA NY
??? Campaign for Peace and Democracy (www.cpdweb.org)
??? Occupy Astoria LIC (www.OccupyAstoriaLIC.org)
??? Queens College Socialist Club

Location:

CHURCH OF THE REDEEMER
30-14 Crescent Street
Corner of Crescent & 30th Road
N/Q Train to 30th Avenue in Astoria
* Note: Church of the Redeemer is a venue, not an endorser.

Online:
http://www.akny.org/2013/10/astoria-politics-crisis-in-greece-after-the-crackdown-on-go...

Facebook:
https://www.facebook.com/events/450392...

****************************

--
???? ?????????????????? ?????? ????????????????????
https://files.nyu.edu/emf202/public/fr/lime...

The Peeler

10/18/2013 4:48:00 AM

0

On Sat, 12 Oct 2013 08:28:30 -0400, John Christou <simlem7@gmail.com>
wrote:

>On 10/11/2013 6:57 AM, emf wrote:
>> On 2013-10-08 16:48 vjp2.at@at.BioStrategist.dot.dot.com wrote:
>>> WHO was borrowing? In 1981 the Greek debt:GDP was 35%, when Andreas
>>> took over
>>> until 1991; it was 100% and stayed that way until 2009 when Yoryaki
>>> took over
>>> and rose it to 145% in 2012. Go look it up, it's all over the internet.
>>>
>>> What galls most of the developed world is that most Greeks STILL think
>>> there
>>> is nothing wrong with having LIED about the debt. THey have no remorse
>>> whatsoever. Like any other schizoparanoid they believe it was natural
>>> behavior. That's why the it keeps blowing up like Dimitra Liani's boobs,
>>> slattering all over the face of Greece.
>>>
>>>
>>> - = -
>>> Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus,
>>> BioStrategist
>>> http://www.panix.com/~vjp2...
>>> ---{Nothing herein constitutes advice. Everything fully
>>> disclaimed.}---
>>> [Homeland Security means private firearms not lazy obstructive
>>> guards]
>>> [Urb sprawl confounds terror] [Phooey on GUI: Windows for subprime
>>> Bimbos]
>>
>> Dear Vaso.
>>
>> Since you live in Long Island, I think you would find it interesting to
>> attend this event. The panel is excellent, and the current situation in
>> Greece critical!
>>
>> Stathis
>>
>> ****************************
>>
>> Astoria: Public Meeting on Greece, Oct. 12
>>
>> You are invited to a public meeting on the Greek situation and future
>> this Saturday, Oct. 12, 5 pm at the Church of the Redeemer in Astoria.
>>
>> (English leaflet & poster can be downloaded online at www.AKNY.org)
>>
>>
>> Politics and the Crisis in Greece
>> After the Crackdown on ?Golden Dawn?
>> WHAT IS THE LEFT ALTERNATIVE?
>>
>>
>> FOR IMMEDIATE RELEASE:
>>
>> On September 18, Pavlos Fyssas, an internationally known hip-hop artist,
>> anti-fascist and left activist, was assassinated by members of the
>> neo-Nazi party Golden Dawn (G.D.). Fyssas and six friends were assaulted
>> by 30-40 members of a G.D. ?attack battalion.? Fyssas was stabbed to
>> death in what the coroner attested was not an amateur hit. In response
>> to the assassination, hundreds of thousands of outraged people took to
>> the streets in Greece, with solidarity protests in a dozen European
>> cities as well as New York and Tokyo.
>>
>> After years of failing to prosecute acts of violence attributed to
>> Golden Dawn, the Greek government of New Democracy and PASOK finally
>> struck against the neo-Nazis on Sept. 28. About 40 G.D. leaders,
>> parliamentarians and party members have been arrested. They are charged
>> with running a criminal organization responsible for 32 cases of
>> violence, including 10 alleged murders and attempted murders. This
>> forces us to ask: Why were the first nine cases not enough to prompt
>> action?
>>
>> For years, Greek authorities tolerated and even protected G.D.?s
>> violence against immigrants, gays, leftists, anarchists, artists and
>> others. In the week after Fyssas? murder two top police officials with
>> alleged G.D. links resigned suddenly for ?personal reasons.? Many
>> examples show G.D.?s violence worked in the service of avoiding change,
>> eliminating dissent, and defending dominant economic interests and
>> social structures. A week before the murder, the G.D. ?attack battalion?
>> assaulted and injured Communist Party (KKE) members, apparently because
>> they were organizing shipyard workers against wage
>> cuts.
>>
>> G.D.?s violence, we submit, serves the same functions as the violence of
>> the Greek government.
>>
>> In both cases, those who demand social change are seen as enemies. The
>> government suppresses peaceful protest with tear gas and mass arrests.
>> Central Athens is shut down by thousands of police troops whenever EU
>> officials visit to oversee the Greek austerity program. When transit
>> workers and then teachers tried to strike, the government declared
>> martial law, issuing conscription orders to strikers and threatening to
>> charge them with treason and imprison them. Thus, the austerity policies
>> have not only created social conditions that allowed anti-immigrant
>> sentiment and neo-Nazi sects to flourish. They have also gone
>> hand-in-hand with ever-more authoritarian attempts to eliminate
>> political challenges and social protest. To frighten voters into
>> accepting authoritarian measures, the government presents a ?narrative
>> of the two extremes,? attempting to equate left opposition parties with
>> Nazis.
>>
>> Two-thirds of people under 30 are unemployed, pensions and wages for
>> most have been cut by 30-50 percent or more. But the resulting popular
>> discontent and anger fails to register with the political machinery. Two
>> weeks ago, the University of Athens was forced to shut down altogether
>> due to budget cuts! Yet the government bizarrely declares success after
>> success, and expects everyone to play along with its charade. Even
>> during Prime Minister Samaras? visit to New York, he presented a false
>> picture of unity behind his government?s policies.
>>
>> On October 12, the Greek left of New York will present a radically
>> different picture.
>>
>> We will discuss and debate alternatives the left in Greece offers for
>> moving past the country?s crises. We invite the Greek-American community
>> to take part and we also invite all New Yorkers. (The main language of
>> the meeting will be English, but people are also welcome to speak in
>> Greek; translations from Greek will be provided.) Developments in Greece
>> are part of a global crisis that also affects the United States. Greece
>> has become capitalism?s testing ground to see how much pain a people can
>> take. The lessons learned in Greece are already being applied in other
>> countries, including in parts of the U.S.
>>
>> END THE POLITICS OF AUSTERITY. RESTORE DEMOCRACY NOW!
>>
>> With:
>>
>> KOSTIS KARPOZILOS
>> Historian, Columbia University
>> Writer of documentary ?Greek American Radicals?
>>
>> DESPINA LALAKI
>> Sociologist, NYU/New School
>> AKNY-Greece Solidarity Movement
>>
>> PETER BRATSIS
>> Asst. Professor of Political Science, CUNY
>> Member, SYRIZA NY
>>
>> IANNIS DELATOLAS
>> Anti-fascist, activist
>> Member, Antarsya
>>
>> Sponsored by:
>>
>> ? AKNY-Greece Solidarity Movement (www.AKNY.org)
>> ? Syriza-New York (www.syriza-ny.org) ? Antarsya NY
>> ? ANTARSYA NY
>> ? Campaign for Peace and Democracy (www.cpdweb.org)
>> ? Occupy Astoria LIC (www.OccupyAstoriaLIC.org)
>> ? Queens College Socialist Club
>>
>> Location:
>>
>> CHURCH OF THE REDEEMER
>> 30-14 Crescent Street
>> Corner of Crescent & 30th Road
>> N/Q Train to 30th Avenue in Astoria
>> * Note: Church of the Redeemer is a venue, not an endorser.
>>
>> Online:
>> http://www.akny.org/2013/10/astoria-politics-crisis-in-greece-after-the-crackdown-on-go...
>>
>>
>> Facebook:
>> https://www.facebook.com/events/450392...
>>
>> ****************************
>>
>The Golden Dawn Murder Case
>http://www.truth-out.org/news/item/19213-the-golden-dawn-murder-case-larry-summers-and-the-n...

Astoria, NY is infested with Griks innit!
<tsk>

--
The Illiterate Foreskin Peeling Grik anus admits he got
no life AT ALL outside stalking on THE Usenet!
"Frankly, if he were gone, I wouldn't know what to do here."
Message-ID: <FCOQt.107901$hp7.96925@fx13.fr7>

The Illiterate Foreskin Peeling Grik anus, defending his fellow Grik sodomite
the Grikboxer? and under the delusion that he's been able to grow a pair:
"You'd have to get past me first,"
Message-ID: <LOOQt.337647$Qr2.32934@fx08.fr7>