Libraryless. Click here for Pure Java version (5051L/28K).
1 | static <A> IPred<A> setToPredicate(Set<A> set) { |
2 | ret set == null ? a -> false : a -> contains(set, a); |
3 | } |
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
Snippet ID: | #1034874 |
Snippet name: | setToPredicate - .contains() as a predicate. null set will return always-false predicate |
Eternal ID of this version: | #1034874/2 |
Text MD5: | 283c6bbb155a4ad88ae1b210645053ee |
Transpilation MD5: | 6df8ecbc14cbbd34d2986815cc6f3271 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-03-12 22:39:41 |
Source code size: | 108 bytes / 3 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 136 / 211 |
Version history: | 1 change(s) |
Referenced in: | [show references] |