Although I know that StackOverflow has already setRequestProperty function of HttpURLConnection question, I really don't understand what this method does. I cannot "step into" it (F7) when debugging. I pressed Ctrl-B to view the method's body, but it only has the following code:
public void setRequestProperty(String field, String newValue) {
checkNotConnected();
if (field == null) {
throw new NullPointerException("field == null");
}
}
and checkNotConnected:
private void checkNotConnected() {
if (connected) {
throw new IllegalStateException("Already connected");
}
}
I mean that where is the code that puts the value to the field? Any explanation is appreciated.
UPDATE (2015/08/08): I have found the way to view its implementation. Since it's abstract, must use Ctrl-Alt-B instead of Ctrl-B to view.
