Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #11792

Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO.

Path csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!npeer03.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!postnews.google.com!b18g2000vbz.googlegroups.com!not-for-mail
From Paka Small <paka-en@tumia.org>
Newsgroups comp.lang.java.programmer
Subject Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO.
Date Mon, 6 Feb 2012 11:57:35 -0800 (PST)
Organization http://groups.google.com
Lines 65
Message-ID <6cef9e71-ae9d-4f90-aa90-06467cdf896f@b18g2000vbz.googlegroups.com> (permalink)
References <7747b7da-e579-4514-bdff-a9eb8842cc51@l16g2000vbl.googlegroups.com> <23822119.1928.1328470685151.JavaMail.geo-discussion-forums@prak33> <15201988-a174-4359-9f40-3fb04b6178bd@18g2000yqe.googlegroups.com> <5572576.2320.1328522100332.JavaMail.geo-discussion-forums@prie27>
NNTP-Posting-Host 178.117.42.244
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1
X-Trace posting.google.com 1328558255 17964 127.0.0.1 (6 Feb 2012 19:57:35 GMT)
X-Complaints-To groups-abuse@google.com
NNTP-Posting-Date Mon, 6 Feb 2012 19:57:35 +0000 (UTC)
Complaints-To groups-abuse@google.com
Injection-Info b18g2000vbz.googlegroups.com; posting-host=178.117.42.244; posting-account=ODpnawoAAADj7WPfKrOQf0t47LNCiq2A
User-Agent G2/1.0
X-Google-Web-Client true
X-Google-Header-Order HUALESNKRC
X-HTTP-UserAgent Mozilla/5.0 (X11; U; Linux i686; nl; rv:1.9.2.3) Gecko/20100403 Fedora/3.6.3-4.fc13 Firefox/3.6.3,gzip(gfe)
Xref x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:11792

Show key headers only | View raw


On 6 feb, 10:55, Lew <lewbl...@gmail.com> wrote:
> Paka Small wrote:
> > Nowhere and never I have stated that methods are classes. Again please have
> > the decency not to put words in my mouth! Or show me where I have claimed
> > that methods and classes are the same.
>
> I answered that in the other thread, quoting you precisely saying exactly that.
>
> > What I have put forward here in this poll and in an earlier discussion
> > is that a Java Method is an Instance of the Java Class
> > java.lang.reflect.Method. I'm glad you finally admit to this truth.
>
> A Java method is not an instance of the Java class java.lang.reflect.Method. A
> method is not an instance of anything in Java. You saying that I "finally admit
> to this truth" doesn't change what I am saying, nor the truth.
>
> You are mistaken. I have pointed you to the correct documentation.
>
> Quite frankly I am mystified by your obstinance. The truth is the truth. Why is
> it unpleasant to learn the truth? You seem to have so much invested in
> promulgating this canard that a method is an instance of a class, or that it is
> a class, or that a method is an instance of 'Method'. None of those statements
> are true.
>
> --
> Lew

Hi,

Example code proving beyond any doubt that a method is an instance of
the class java.lang.reflect.Method in Java:

  public final void setValue(BaseObject baseObject, Object value) {
    java.lang.reflect.Method setMethod = null;
    try {
      setMethod =
baseObjectClass.getJavaClass().getMethod(this.getSetMethodName(), new
Class[]{this.type});
      } catch (NoSuchMethodException ex) {
 
Logger.getLogger(BaseObjectAttribute.class.getName()).log(Level.SEVERE,
null, ex);
      } catch (SecurityException ex) {
 
Logger.getLogger(BaseObjectAttribute.class.getName()).log(Level.SEVERE,
null, ex);
      }
    try {
      setMethod.invoke(baseObject, new Object[]{value});
    } catch (IllegalAccessException ex) {
 
Logger.getLogger(BaseObjectAttribute.class.getName()).log(Level.SEVERE,
null, ex);
    } catch (IllegalArgumentException ex) {
 
Logger.getLogger(BaseObjectAttribute.class.getName()).log(Level.SEVERE,
null, ex);
    } catch (InvocationTargetException ex) {
 
Logger.getLogger(BaseObjectAttribute.class.getName()).log(Level.SEVERE,
null, ex);
    }
  }

Kind regards, Paka

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Paka Small <paka-en@tumia.org> - 2012-02-05 08:56 -0800
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Lew <lewbloch@gmail.com> - 2012-02-05 11:38 -0800
    Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Paka Small <paka-en@tumia.org> - 2012-02-05 14:53 -0800
      Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Lew <lewbloch@gmail.com> - 2012-02-06 01:55 -0800
        Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Paka Small <paka-en@tumia.org> - 2012-02-06 11:57 -0800
          Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Lew <lewbloch@gmail.com> - 2012-02-06 17:14 -0800
          Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Daniel Pitts <newsgroup.nospam@virtualinfinity.net> - 2012-02-07 09:52 -0800
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Joshua Cranmer <Pidgeot18@verizon.invalid> - 2012-02-06 23:54 -0600
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Patricia Shanahan <pats@acm.org> - 2012-02-06 21:58 -0800
    Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Paul Cager <paul.cager@googlemail.com> - 2012-02-07 02:41 -0800
      Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Patricia Shanahan <pats@acm.org> - 2012-02-07 09:35 -0800
      Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Lew <lewbloch@gmail.com> - 2012-02-07 10:59 -0800
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Leif Roar Moldskred <leifm@dimnakorr.com> - 2012-02-07 01:09 -0600
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Paul Cager <paul.cager@googlemail.com> - 2012-02-07 03:01 -0800
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Mayeul <mayeul.marguet@free.fr> - 2012-02-07 12:13 +0100
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Lew <lewbloch@gmail.com> - 2012-02-07 11:04 -0800
  Re: Poll: Is a Java Method an Instance of the Java Class java.lang.reflect.Method? Please reply with YES or NO. Wanja Gayk <brixomatic@yahoo.com> - 2012-02-08 16:05 +0100

csiph-web