• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Anyone else ever delve into classes to find out how they work?

Or is this a waste of time? :awe:

Im figuring out RESTful stuff in java and I got sidetracked looking at this line of code:

Code:
return Response.status(200).entity(response).build();

Response.status returns a ResponseBuilder object, then entity() is called on that ResponseBuilder object... however looking at the code the entity() method is abstract and has no code... So how does that work? :\
 
most likely the object that you are actually using is being derived from the ResponseBuilder class, and the class has been compiled into a JAR somewhere. it's just abstract in the base class.

i don't dig into classes just to do it, i only dig into them when i need more information.

sometimes getting to the abstract class level can be very helpful though if they have comments in there to let you know what their intention is supposed to be.
 
Back
Top