No, it's not possible with CFMX. They meant you'd have to write a new Java class to extend theirs.
> -----Original Message----- > From: blists [mailto:[EMAIL PROTECTED] > Sent: Friday, January 20, 2006 8:58 PM > To: CF-Talk > Subject: Re: Using a .jar file > > Ahhh yes, your right. I figured this out with some help from > their tech > support but you are right on the money. Now, I have another > problem. I got > this working, but now I need to listen for events to know if > the ftp was > successfull etc, ect. The only way to do this, according to their > documentation I need to create a new object/class to do this > and while I > could figure out how to do this in Java or AS, I'm not sure how its > possible within CFMX. Is it even possible to do something > like this with > cfscript? > > For an object to listen for events published by the Sftp class the > following steps are required: > > 1. Set object to implement SftpListener or extend SftpAdapter class. > 2. Overload event handling methods. > 3. Subscribe object to receive events published by Sftp instance. > > The example below demonstrates using the SftpAdapter class. > > import com.jscape.inet.sftp.*; > import com.jscape.inet.sftp.events.*; > import com.jscape.inet.ssh.util.SshParameters; > > public class MySftpAdapter extends SftpAdapter { > > public void connected(SftpConnectedEvent evt) { > System.out.println("Connected to host: " + evt.getHostname()); > } > > public void disconnected(SftpDisconnectedEvent evt) { > System.out.println("Disconnected from host: " + > evt.getHostname()); > } > > public static void main(String[] args) { > try { > String hostname = "ftp.host.com"; > String username = "jsmith"; > String password = "secret"; > > // create connection parameters > SshParameters sshParams = new > SshParameters(hostname,username,password); > Sftp sftp = new Sftp(sshParams); > > // subscribe listener to published SFTP events > sftp.addSftpListener(new MySftpAdapter()); > > // connect then disconnect > sftp.connect(); > sftp.disconnect(); > > } catch(SftpException e) { > e.printStackTrace(); > } > } > } > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:230222 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54