1 | static <A> A assertNotNullVerbose(A y) {
|
2 | assertNotNullVerbose((S) null, y); |
3 | ret y; |
4 | } |
5 | |
6 | static <A> A assertNotNullVerbose(S msg, A y) {
|
7 | if (y == null) {
|
8 | fail((msg != null ? msg + ": " : "") + "value is null"); |
9 | } else |
10 | print("OK (not null): " + y);
|
11 | ret y; |
12 | } |
Began life as a copy of #1002936
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1023270 |
| Snippet name: | assertNotNullVerbose |
| Eternal ID of this version: | #1023270/1 |
| Text MD5: | 6ab048fd8a5fe27cccf29d96fe41f6dc |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2019-05-21 16:42:51 |
| Source code size: | 282 bytes / 12 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 701 / 687 |
| Referenced in: | [show references] |