code: public void setSSLSocketFactory(SSLSocketFactory sf) {
          if (sf == null) {
              throw new IllegalArgumentException(
                  "no SSLSocketFactory specified");
          }
  
          SecurityManager sm = System.getSecurityManager();
          if (sm != null) {
              sm.checkSetFactory();
          }
          sslSocketFactory = sf;
      }
docs: Sets the <code>SSLSocketFactory</code> to be used when this instance
  creates sockets for secure https URL connections.
  <P>
  New instances of this class inherit the default static
  <code>SSLSocketFactory</code> set by
  {@link #setDefaultSSLSocketFactory(SSLSocketFactory)
  setDefaultSSLSocketFactory}.  Calls to this method replace
  this object's <code>SSLSocketFactory</code>.
  
  @param sf the SSL socket factory
  @throws IllegalArgumentException if the <code>SSLSocketFactory</code>
  parameter is null.
  @see #getSSLSocketFactory()