Assigned
Status Update
Comments
na...@google.com <na...@google.com> #2
By "api says", I assume you're referring to
http://developer.android.com/reference/java/net/Socket.html
This seems like a deficiency of our API doc generation. Socket implements Closeable only since API level 18 (kitkat & JB MR2) but that information isn't in the generated documentation.
This seems like a deficiency of our API doc generation. Socket implements Closeable only since API level 18 (kitkat & JB MR2) but that information isn't in the generated documentation.
na...@google.com <na...@google.com> #3
(actually, that should be API 19 (kitkat only))
fr...@gmail.com <fr...@gmail.com> #4
I see. Just wanted to report this in case it is a bug because Socket has everything to be closable but does not implements Closable. BTW: a short hint in the document would be very usefull. Something like "implements Closable (Added in API level 19)"
na...@google.com <na...@google.com> #5
Yes, I agree. The documentation should make it very clear.
I've cc'ed the folks that deal with that, perhaps they can chime in.
I've cc'ed the folks that deal with that, perhaps they can chime in.
fr...@gmail.com <fr...@gmail.com> #6
Thank you.
na...@google.com <na...@google.com> #7
I think this is a high priority fix. The docs are pretty misleading, as things stand.
na...@google.com <na...@google.com> #8
Ping. I want to make sure this isn't forgotten.
fr...@gmail.com <fr...@gmail.com> #9
Is the generation of the docs that automated that it is that hard to add a little sidenote? ;)
en...@google.com <en...@google.com>
na...@google.com <na...@google.com> #10
Yes, it is pretty automated. This is going to be a pretty large and painful change to make to the automated javadoc tools.
I guess I could add something to the javadoc but i'm fairly certain that isn't going to help anybody because it's hard(er) to spot.
I guess I could add something to the javadoc but i'm fairly certain that isn't going to help anybody because it's hard(er) to spot.
na...@google.com <na...@google.com>
ps...@google.com <ps...@google.com>
to...@google.com <to...@google.com>
to...@gmail.com <to...@gmail.com> #11
This issue needs to be addressed. I recently ran into the issue that LocalServerSocket(https://developer.android.com/reference/android/net/LocalServerSocket ) claims to implement Closeable, while it is only adding after 2017. This will crash whenever a developer uses the `Closeable?.use(block)` kotlin extension in an app on any kind of these classes.
da...@google.com <da...@google.com> #12
+dmail@ to see if annotating interface implementation changes is available in Android documentation, e.g. "implements Closable [available from API level 26]".
sa...@google.com <sa...@google.com> #13
Thank you for your feedback. We assure you that we are doing our best to address all issues reported. For now, we will be closing the issue as won't fix obsolete. If this issue currently still exists, we request that you log a new issue along with the bug report here https://goo.gl/TbMiIO and reference this bug for context.
bd...@google.com <bd...@google.com> #14
Reopening issues that had been marked with hotlistid:4240 to prevent bulk closure.
Description
Although java.net.Socket implements the method public void close() a cast to Closable leads to a ClassCastException. Afterwards i looked in the attatched source and found that it doesn't implements Closable.