KeyUnavailableException

Summary

Represents an exception when a dictionary key cannot be found.

Description

Represents an exception when a dictionary key cannot be found.

Examples

Example of how this exception might be encountered
1
2
3
4
5
6
7
8
9
10
import System;
import System.Exceptions;
 
Dictionary<string> emptyDict = {{ }};
try {
    Console.log(emptyDict["some_key"]);
}
catch(KeyUnavailableException e) {
    Console.error(e);
}

Methods

Share

HTML | BBCode | Direct Link