1 | sS lightlyShortenClassName(S name) { |
2 | if (name == null) null; |
3 | int i = indexOf(name, "$"); |
4 | if (i < 0) i = indexOf(name, "."); |
5 | ret i < 0 ? name : substring(name, i+1); |
6 | } |
Began life as a copy of #1005243
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1025162 |
Snippet name: | lightlyShortenClassName - drop part before first $ or . |
Eternal ID of this version: | #1025162/1 |
Text MD5: | 24847b3942099725ffcb98e4068c009d |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-09-09 23:27:23 |
Source code size: | 179 bytes / 6 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 231 / 277 |
Referenced in: | [show references] |