I think its worth noting that the object, Login, is internal to a sealed class, Features
Any ideas?
s
streetsofboston
10/01/2020, 5:57 PM
Try
com.mystuff.stylopoc.core.Features$Login
👆 1
n
nanodeath
10/01/2020, 6:06 PM
besides just knowing, or reading the spec, if you look in your jar file or wherever .class files are generated, you can see the name of the class from the .class filename
c
Cole K
10/01/2020, 6:08 PM
I tried looking at the decompiled kotlin file, but totally missed the dollar signs on the companion objects and that object lol
Cole K
10/01/2020, 6:09 PM
That worked!!
This might be left field relative to this questions, but I’m playing with annotations right now and I’m getting the class name by passing the class reference through an annotation. The only way I know how to get the reference back out is by doing janky stuff to convert the parameter of the annotation into a
typeMirror
, then into a string that represents the class name. The string, however, has a dot rather than a dollar sign for the class name. Any clue how I could fix this?
Cole K
10/01/2020, 6:13 PM
i guess I could write a small tool that just tries different permutations of dots switched out with dollar signs until I get a class out lol. I dont like that solution, but it is a solution
e
ephemient
10/01/2020, 7:53 PM
.
is for packages (it's actually a
/
in the JVM internally). within a classname, nesting always uses