tracker issue : CF-4203263

select a category, or use search below
(searches all categories and all time range)

Improve cfdump of a java class to include more information

| View in Tracker

Status/Resolution/Reason: To Fix//BugVerified

Reporter/Name(from Bugbase): Bradley Wood / ()

Created: 08/10/2018

Components: Language

Versions: 2018

Failure Type: Usability Issue

Found In Build/Fixed In Build: /

Priority/Frequency: Normal /

Locale/System: / Platforms All

Vote Count: 1

When you cfdump a class in Lucee Server

writedump( createOBject('java', '' ) );

You get the following additional items that Adobe does not provide:

- Fields includes the pattern along with the name and value.  Ex:
name: separatorChar
Pattern: public static final char
Value: /

- Constructors, which lists all the constructors for the class showing the method and the declared exceptions that can be thrown.  Ex:
Method: <init>(java.lang.String, java.lang.String)
Exceptions: (none) 

- "Methods inherited from <parent object>".  Ex:
wait, wait, wait, getClass, notify, notifyAll

- The list of methods includes the exceptions that can be thrown.  Ex:
Method:  toURL()
Return Type:

And additionally, I'm including this in the ticket because it's all part of how CFDump handles classes, when I run this code:

  myStr = 'myString';
  writedump( myStr.getClass() );

The resulting dump in Lucee shows the details of the "java.lang.String" class.  However, when I run that same code in Adobe CF, the dump shows me the details of the "java.lang.Class" class.  This isn't very helpful and I don't know how to dump the actual class instance since dumping myStr directly wouldn't obviously just output the string!  I think what Lucee does here is much more useful when dealing with Java objects.



Crap, I copy pasted the wrong URLs and now I can't edit the description. Can an Adobe team member please update those? The first try CF URL should have been: And the second trycf URL should have been:
Comment by Bradley W.
29473 | August 10, 2018 06:52:41 PM GMT
+1 - CF always dumping "java.lang.Class" is especially irritating. Useful info please and thanks!
Vote by Aaron N.
29493 | August 15, 2018 04:41:58 AM GMT