Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

3
LINES

< > BotCompany Repo | #1024488 // dropSuffixICOrNull_trim - suffix parameter first. returs null when suffix not found

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (1654L/11K).

sS dropSuffixICOrNull_trim(S suffix, S s) {
  ret !ewic(s, suffix) ? null : trimSubstring(s, 0, l(s)-l(suffix));
}

Author comment

Began life as a copy of #1010559

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: #1024488
Snippet name: dropSuffixICOrNull_trim - suffix parameter first. returs null when suffix not found
Eternal ID of this version: #1024488/1
Text MD5: 0c0512bb304d26e4ed2272a37ec6c380
Transpilation MD5: 499457899b9b2b09f5c4de0b6cd44e65
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-08-14 12:27:58
Source code size: 116 bytes / 3 lines
Pitched / IR pitched: No / No
Views / Downloads: 189 / 274
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)