List of usage examples for javax.resource ResourceException ResourceException
public ResourceException(Throwable cause)
From source file:org.teiid.test.teiid4441.FTPClientFactory.java
public FTPClient createClient() throws IOException, ResourceException { FTPClient client = createClientInstance(); beforeConnectProcessing(client);/*from w ww. ja v a 2 s.com*/ client.connect(this.host, this.port); if (!FTPReply.isPositiveCompletion(client.getReplyCode())) { throw new ResourceException("ftp_connect_failed"); } if (!client.login(this.username, this.password)) { throw new IllegalStateException("ftp_login_failed"); //$NON-NLS-1$ } afterConnectProcessing(client); return client; }