493 |
this.out = new CRLFOutputStream(out); |
this.out = new CRLFOutputStream(out); |
494 |
return true; |
return true; |
495 |
} |
} |
496 |
catch(ClassNotFoundException e) |
catch (RuntimeException e) |
497 |
{ |
{ |
498 |
return false; // No javax.net classes in runtime |
return false; // No javax.net classes in runtime |
499 |
} |
} |
581 |
} |
} |
582 |
} |
} |
583 |
} |
} |
584 |
catch(SaslException e) |
catch (SaslException e) |
585 |
{ |
{ |
586 |
return false; // No provider for mechanism |
return false; // No provider for mechanism |
587 |
} |
} |
588 |
catch(ClassNotFoundException e) |
catch (RuntimeException e) |
589 |
{ |
{ |
590 |
return false; // No javax.security.sasl classes |
return false; // No javax.security.sasl classes |
591 |
} |
} |
663 |
protected int getResponse() throws IOException |
protected int getResponse() throws IOException |
664 |
{ |
{ |
665 |
String line = null; |
String line = null; |
666 |
try |
try |
667 |
{ |
{ |
668 |
line = in.readLine(); |
line = in.readLine(); |
669 |
// Handle special case eg 334 where CRLF occurs after code. |
// Handle special case eg 334 where CRLF occurs after code. |
681 |
response = line.substring(4); |
response = line.substring(4); |
682 |
return code; |
return code; |
683 |
} |
} |
684 |
catch(NumberFormatException e) |
catch (NumberFormatException e) |
685 |
{ |
{ |
686 |
throw new ProtocolException("Unexpected response: " + line); |
throw new ProtocolException("Unexpected response: " + line); |
687 |
} |
} |