Possible to use SystemRemoteFileDialog/SystemRemoteFolderDialog without RSE open [message #575355] |
Wed, 18 June 2008 19:32 |
Eclipse User |
|
|
|
Originally posted by: zengland.us.ibm.com
Is it possible to make use of the
SystemRemoteFileDialog/SystemRemoteFolderDialog classes without being in
or possibly even activating the Remote systems view or Remote Systems
Explorer perspective?
I have another perspective and view from which I need to browse a remote
system for which I already have the host name/address and a
userid/password.
I started out trying some code like below but ran into a number of issues
with the bundle not being loaded and values not being initialized.
new RSECorePlugin();
IRSESystemType[] systemTypes =
RSECorePlugin.getTheCoreRegistry().getSystemTypes();
if(systemTypes != null)
{
System.out.println(systemTypes);
}
Host host = null;
SystemProfile prof = null;
prof = new SystemProfile(hostAddress, true);
host = new Host(prof);
IRSESystemType type =
RSECoreRegistry.getInstance().getSystemTypeById(IRSESystemTy pe.SYSTEMTYPE_SSH_ONLY_ID);
ISubSystemConfigurator sub[] = null;
SystemRegistry reg = SystemRegistry.getInstance();
try {
reg.createHost("builtIn", type , hostName, hostName, id, remoteHost, 0,
sub );
} catch (Exception e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
diag = new SystemRemoteFileDialog(l_Form.getShell(), "browse remote file
system", host);
diag.open();
Object o = diag.getSelectedObject();
Is this type of usage even possible?
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04089 seconds