// s = mail address or gmail handle static S gmailGetHandle(S s) { int i = s.indexOf('@'); if (i < 0) ret s.toLowerCase(); S a = s.substring(0, i), b = s.substring(i+1); if (eqicOneOf(b, "gmail.com", "googlemail.com")) ret a.toLowerCase(); fail("Not a gmail address: " + s); }
download show line numbers debug dex old transpilations
Travelled to 15 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, onxytkatvevr, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1003576 |
Snippet name: | gmailGetHandle |
Eternal ID of this version: | #1003576/1 |
Text MD5: | e4267fcfbde3797b3880ebbfb31d2e23 |
Author: | stefan |
Category: | javax / gmail bot |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2016-07-22 13:43:38 |
Source code size: | 298 bytes / 9 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 410 / 459 |
Referenced in: | [show references] |