question: private String pickEncoding ( InputSource inputSource ) { Reader reader = inputSource . getCharacterStream ( ) ; if ( reader != null ) { return CHARACTER_ENCODING ; } String encoding = inputSource . getEncoding ( ) ; return encoding == null ? DEFAULT_ENCODING : encoding ; }
target:  Picks an encoding for an external entity. Defaults to UTF-8.