bugGNU Octave - Bugs: bug #48742, methods(obj,'-full')

 
 

bug #48742: methods(obj,'-full')

Submitted by:  Ernst Reissner <ernstreissner>
Submitted on:  Tue 09 Aug 2016 11:14:57 PM UTC  
 
Category: Octave FunctionSeverity: 1 - Wish
Priority: 3 - LowItem Group: Matlab Compatibility
Status: ConfirmedAssigned to: None
Originator Name: Open/Closed: Open
Release: devOperating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Tue 16 Aug 2016 09:54:46 PM UTC, comment #4:

Now i implemented what i found.
For Java objects, now this bug is fixed.

(file #38236)

Ernst Reissner <ernstreissner>
Mon 15 Aug 2016 10:41:37 PM UTC, comment #3:

I found now in the attached document,
how Matlab displays inheritance information:

Have a look at page 5-35 and read:

Methods for class java.awt.Dimension:
Dimension()
Dimension(java.awt.Dimension)
Dimension(int,int)
java.lang.Class getClass() % Inherited from java.lang.Object
int hashCode() % Inherited from java.lang.Object
boolean equals(java.lang.Object)
...

ah ok.

Ernst Reissner <ernstreissner>
Fri 12 Aug 2016 02:36:40 PM UTC, comment #2:

The patch I provide does not fully fix the bug:
- the fix refers to Java objects and to java classnames only.
for all other input, the parameter -full is ignored.
- for java class names or methods
we provide almost a fix:
missing is only inheritance information.
Currently, i cannot provide this,
since I do not know how this information is represented.

So suggestion:

Split this bugreport in two:
- for java: for -full, inheritance information is missing
status is need information.
- for the rest: -full is fully ignored,
status is confirmed.

There is a third problem:
The two cases cannot be fully distinguished:
Matlab only allows classnames both java and matlab,
which would correspond with octave.
Matlab documentation
http://de.mathworks.com/help/matlab/ref/methods.html?searchHighlight=methods

does not clearly say what if one and the same name refers to both,
a java and a matlab classname.

The problem with the current implementation in this case is,
if the octave/ class has no methods:
Then a java class is tried which may not exist.

So this may be a third bug.

(file #38189)

Ernst Reissner <ernstreissner>
Wed 10 Aug 2016 11:36:19 AM UTC, comment #1:

Wish only? It breaks matlab compatibility.

Ernst Reissner <ernstreissner>
Tue 09 Aug 2016 11:14:57 PM UTC, original submission:

in matlab methods(obj,'-full') returns the full description
of the public methods of a java object obj,
including parameter types, return types, static or not.
No access modifiers, since only public is displayed.

On the other hand, methods(obj) just returns the NAMES of the public

This shall be the case also for octave.

Ernst Reissner <ernstreissner>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by mtmiller (Updated the item)
  • -unavailable- added by ernstreissner (Submitted the item)
  • -unavailable- added by ernstreissner
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 16 Aug 2016 09:54:46 PM UTCernstreissnerAttached File-=>Added patchBug48742_48740B.patch, #38236
    Fri 12 Aug 2016 02:36:40 PM UTCernstreissnerAttached File-=>Added patchBug48742_48740.patch, #38189
    Wed 10 Aug 2016 01:07:39 AM UTCmtmillerCategoryNone=>Octave Function
      Severity3 - Normal=>1 - Wish
      Priority5 - Normal=>3 - Low
      Item GroupNone=>Matlab Compatibility
      StatusNone=>Confirmed
    Tue 09 Aug 2016 11:14:57 PM UTCernstreissnerCarbon-Copy-=>Added -unavailable-

    Back to the top


    Powered by Savane 3.1-cleanup1