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

7
LINES

< > BotCompany Repo | #1024466 - mapGet2 - checks map for null, but not the key

JavaX fragment (include)

static <A, B> B mapGet2(Map<A, B> map, A a) {
  ret map == null ? null : map.get(a);
}

static <A, B> B mapMethodLike mapGet2(A a, Map<A, B> map) {
  ret map == null ? null : map.get(a);
}

Author comment

Began life as a copy of #1008055

download  show line numbers  debug dex   

Travelled to 2 computer(s): mqqgnosmbjvj, tvejysmllsmz

No comments. add comment

Snippet ID: #1024466
Snippet name: mapGet2 - checks map for null, but not the key
Eternal ID of this version: #1024466/1
Text MD5: c43552be5ebdedd2954275824bf75103
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-08-13 13:04:08
Source code size: 194 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 9 / 20
Referenced in: [show references]

Formerly at http://tinybrain.de/1024466 & http://1024466.tinybrain.de