<div dir="ltr"><div class="gmail_default" style="font-family:monospace">Hello <a class="gmail_plusreply" id="plusReplyChip-1" href="mailto:core-libs-dev@openjdk.org" tabindex="-1">@core-libs-dev</a>,</div><div class="gmail_default" style="font-family:monospace"><br></div><div class="gmail_default" style="font-family:monospace">Let's say I have a record User(String first, String last) {}. That code grants me User::first and User::last as accessor methods. Very cool.</div><div class="gmail_default" style="font-family:monospace"><br></div><div class="gmail_default" style="font-family:monospace">I can access those accessor methods if I am given the class. It is a trivial call from User.class ---> Class.getRecordComponents() ---> RecordComponent.getAccessor() ---> Method.invoke() ---> User::first/last. It is very powerful.</div><div class="gmail_default" style="font-family:monospace"><br></div><div class="gmail_default" style="font-family:monospace">But this only lets me go top-down. If I want to take a record accessor like User::first and turn that into a record component, then that is not something I can see how to do.</div><div class="gmail_default" style="font-family:monospace"><br></div><div class="gmail_default" style="font-family:monospace">Is it impossible? There is a lot of value in being able to look at a method reference and be able to see that class that that method being referenced is contained within. For example, I would like to be able to look at User::first, and be able to get the accompanying RecordComponent. And if not that, then at least the accompanying java.lang.reflect.Method. Is that possible?</div><div class="gmail_default" style="font-family:monospace"><br></div><div class="gmail_default" style="font-family:monospace">Thank you for your time and consideration.</div><div class="gmail_default" style="font-family:monospace">David Alayachew</div></div>