@webref intdict:method @brief Add to a value
(String key, int amount)
| 427 | * @brief Add to a value |
| 428 | */ |
| 429 | public void add(String key, int amount) { |
| 430 | int index = index(key); |
| 431 | if (index == -1) { |
| 432 | create(key, amount); |
| 433 | } else { |
| 434 | values[index] += amount; |
| 435 | } |
| 436 | } |
| 437 | |
| 438 | |
| 439 | /** |