shadows/framework/src/main/java/org/robolectric/shadows/ShadowCameraCharacteristics.java
public <T> void set(Key<T> key, Object value) {
    Preconditions.checkArgument(!charactersKeyToValue.containsKey(key));
    charactersKeyToValue.put(key, value);
  }
public <T> void set(Key<T> key, Object value) {
    Preconditions.checkArgument(!charactersKeyToValue.containsKey(key));
    charactersKeyToValue.put(key, value);
  }
Sets the value for a given key.

@throws IllegalArgumentException if there's an existing value for the key.