Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

RSE
Release 3.0

org.eclipse.rse.subsystems.shells.core.subsystems
Interface IRemoteCmdSubSystem

All Superinterfaces:
IPropertySetContainer, IRemoteObjectResolver, IRSEModelObject, IRSEPersistableContainer, ISchedulingRule, ISubSystem, ISystemFilterPoolReferenceManagerProvider
All Known Subinterfaces:
IShellServiceSubSystem
All Known Implementing Classes:
RemoteCmdSubSystem, ShellServiceSubSystem

public interface IRemoteCmdSubSystem
extends ISubSystem

interface RemoteCmdSubSystem extends SubSystem {}


Field Summary
 
Fields inherited from interface org.eclipse.rse.core.model. IRSEPersistableContainer
NO_CHILDREN
 
Method Summary
 void addEnvironmentVariable ( IRemoteSystemEnvVar rsev)
          Add environment variable entry, given a RemoteSystemEnvVar object
 void addEnvironmentVariable ( String name, String value)
          Add environment variable entry, given a name and value
 void cancelShell ( Object commandObject, IProgressMonitor monitor)
          Cancel a shell or running command.
 boolean canRunCommand ()
          Determine whether the command subsystem can run a command
 boolean canRunShell ()
          Determine whether the command subsystem can run a shell
  ICandidateCommand[] getCandidateCommands ( Object context)
          Provide a list of possible commands for the specified context.
  IRemoteCommandShell getDefaultShell ()
          Get the default running command shell for this command subsystem.
  IRemoteSystemEnvVar getEnvironmentVariable ( String name)
          Given an environment variable name, find its RemoteSystemEnvVar object.
  IRemoteSystemEnvVar[] getEnvironmentVariableList ()
          Get the initial environment variable list as a string of RemoteSystemEnvVar objects.
  String getEnvironmentVariableValue ( String name)
          Given an environment variable name, find its value.
  String[] getExecutedCommands ()
          Provide list of executed commands on subsystem.This is only applicable if the subsystem factory reports true for supportsCommands().
  List getHostEnvironmentVariables ()
           
  String getInvalidEnvironmentVariableNameCharacters ()
          Get the invalid characters for an environment variable name.
  IRemoteCmdSubSystemConfiguration getParentRemoteCmdSubSystemConfiguration ()
          Return parent subsystem factory, cast to a RemoteCmdSubSystemConfiguration
  IRemoteCommandShell[] getShells ()
          Get all command shells and transient commands that have been run or are running for this command subsystem.
 void removeEnvironmentVariable ( IRemoteSystemEnvVar rsev)
          Remove environment variable entry given its RemoteSystemEnvVar object
 void removeEnvironmentVariable ( String name)
          Remove environment variable entry given only its environment variable name
 void removeShell ( Object commandObject)
          Remove a shell.
  IRemoteCommandShell[] restoreShellState ( Shell shell)
          Restore all the command shells that were open before disconnecting during the previous session
  Object[] runCommand ( String command, Object context, boolean interpretOutput, IProgressMonitor monitor)
          Execute a remote command.
  Object[] runCommand ( String command, Object context, IProgressMonitor monitor)
          Execute a remote command.
  IRemoteCommandShell runShell ( Object context, IProgressMonitor monitor)
          Launch a new command shell.
 void sendCommandToShell ( String input, Object commandObject, IProgressMonitor monitor)
          Send a command as input to a running command shell.
 void setEnvironmentVariableList ( String[] envVarNames, String[] envVarValues)
          Set the initial environment variable list entries, all in one shot, using a pair of String arrays: the first is the environment variable names, the second is the corresponding environment variable values.
 
Methods inherited from interface org.eclipse.rse.core.subsystems. ISubSystem
canSwitchTo, checkIsConnected, clearLocalUserId, connect, connect, deletingConnection, disconnect, disconnect, doesFilterListContentsOf, doesFilterMatch, doesFilterStringListContentsOf, doesFilterStringMatch, forceUserIdToUpperCase, getCacheManager, getChildren, getConfigurationId, getConnectorService, getFilterPoolReferenceManager, getHost, getHostAliasName, getLocalUserId, getName, getPrimarySubSystem, getProperties, getProperty, getServiceType, getSubSystemConfiguration, getSystemFilterPoolReferenceManager, getSystemProfile, getSystemProfileName, getTargetForFilter, getUserId, getVendorAttribute, hasChildren, initializeSubSystem, isConnected, isConnectionError, isHidden, isOffline, isPrimarySubSystem, renamingConnection, renamingProfile, resolveFilterString, resolveFilterString, resolveFilterStrings, setConfigurationId, setConnectionError, setConnectorService, setFilterPoolReferenceManager, setHidden, setHost, setName, setProperties, setProperty, setSubSystemConfiguration, setVendorAttribute, supportsCaching, switchServiceFactory, uninitializeSubSystem
 
Methods inherited from interface org.eclipse.rse.core.filters. ISystemFilterPoolReferenceManagerProvider
filterEventFilterCreated, filterEventFilterPoolReferenceCreated, filterEventFilterPoolReferenceDeleted, filterEventFilterPoolReferenceRenamed, filterEventFilterPoolReferenceReset, filterEventFilterPoolReferencesRePositioned, filterEventFilterPoolReferencesReset, filterEventFilterStringCreated, getUniqueOwningSystemFilterPool
 
Methods inherited from interface org.eclipse.rse.core.subsystems. IRemoteObjectResolver
getObjectWithAbsoluteName, getObjectWithAbsoluteName
 
Methods inherited from interface org.eclipse.core.runtime.jobs. ISchedulingRule
contains, isConflicting
 
Methods inherited from interface org.eclipse.rse.core.model. IRSEModelObject
getDescription
 
Methods inherited from interface org.eclipse.rse.core.model. IPropertySetContainer
addPropertySet, addPropertySets, createPropertySet, createPropertySet, getPropertySet, getPropertySets, removePropertySet
 
Methods inherited from interface org.eclipse.rse.core.model. IRSEPersistableContainer
commit, getPersistableChildren, getPersistableParent, isDirty, isTainted, setDirty, setTainted, setWasRestored, wasRestored
 

Method Detail

getParentRemoteCmdSubSystemConfiguration


IRemoteCmdSubSystemConfiguration getParentRemoteCmdSubSystemConfiguration()
Return parent subsystem factory, cast to a RemoteCmdSubSystemConfiguration


runCommand


Object[] runCommand(
String command,
                    
Object context,
                    
IProgressMonitor monitor)
                    throws 
Exception
Execute a remote command. This is only applicable if the subsystem factory reports true for supportsCommands().

Parameters:
command - Command to be executed remotely.
context - context of a command (i.e. working directory). Null is valid and means to run the command as a shell command in the default shell.
monitor - the progress monitor
Returns:
Array of objects that are the result of running this command. In a typical use, such as a command run from a shell, there is only one result in the array and that is the IRemoteCommandShell object. In that cause, the lines of output for the shell are contained as children under the IRemoteCommandShell object.
Throws:
Exception

runCommand


Object[] runCommand(
String command,
                    
Object context,
                    boolean interpretOutput,
                    
IProgressMonitor monitor)
                    throws 
Exception
Execute a remote command. This is only applicable if the subsystem factory reports true for supportsCommands().

Parameters:
command - Command to be executed remotely.
context - context of a command (i.e. working directory). Null is valid and means to run the command as a shell command in the default shell.
interpretOutput - whether to interpret the output or not
monitor - the progress monitor
Returns:
Array of objects that are the result of running this command. In a typical use, such as a command run from a shell, there is only one result in the array and that is the IRemoteCommandShell object. In that cause, the lines of output for the shell are contained as children under the IRemoteCommandShell object.
Throws:
Exception

runShell


IRemoteCommandShell runShell(
Object context,
                             
IProgressMonitor monitor)
                             throws 
Exception
Launch a new command shell. This is only applicable if the subsystem factory reports true for supportsCommands().

Parameters:
context - context of a shell (i.e. working directory). Null is valid and means to use the default context.
monitor - the progress monitor
Returns:
An object that represents the command and it's output.
Throws:
Exception

sendCommandToShell

void sendCommandToShell(
String input,
                        
Object commandObject,
                        
IProgressMonitor monitor)
                        throws 
Exception
Send a command as input to a running command shell.

Parameters:
input - the command to invoke in the shell.
commandObject - the shell or command to send the invocation to.
monitor - the progress monitor
Throws:
Exception

cancelShell

void cancelShell(
Object commandObject,
                 
IProgressMonitor monitor)
                 throws 
Exception
Cancel a shell or running command.

Parameters:
commandObject - the shell or command to cancel
monitor - the progress monitor
Throws:
Exception

removeShell

void removeShell(
Object commandObject)
                 throws 
Exception
Remove a shell. If the shell is running cancel it first.

Parameters:
commandObject - the shell or command to cancel & remove.
Throws:
Exception

getDefaultShell


IRemoteCommandShell getDefaultShell()
                                    throws 
Exception
Get the default running command shell for this command subsystem. If no such shell exists or is running, a new one is launched.

Returns:
the default running command shell
Throws:
Exception

getShells


IRemoteCommandShell[] getShells()
Get all command shells and transient commands that have been run or are running for this command subsystem.

Returns:
the list of running command shells and commands

restoreShellState


IRemoteCommandShell[] restoreShellState(
Shell shell)
Restore all the command shells that were open before disconnecting during the previous session

Parameters:
shell - a window used for notification
Returns:
the command shells that were restored

canRunShell

boolean canRunShell()
Determine whether the command subsystem can run a shell

Returns:
whether a shell can be run or not

canRunCommand

boolean canRunCommand()
Determine whether the command subsystem can run a command

Returns:
whether a command can be run or not

getExecutedCommands


String[] getExecutedCommands()
Provide list of executed commands on subsystem.This is only applicable if the subsystem factory reports true for supportsCommands().


getCandidateCommands


ICandidateCommand[] getCandidateCommands(
Object context)
Provide a list of possible commands for the specified context. This method is primarily used for command line assist to get a list of possible command completions. Typically the context is a handle to a shell or command, such as an IRemoteCommandShell, but the interface is left generic, with Object, because some command subsystems have different notions of context.

Parameters:
context - the context for the possible commands
Returns:
a list of possible commands

getEnvironmentVariableList


IRemoteSystemEnvVar[] getEnvironmentVariableList()
Get the initial environment variable list as a string of RemoteSystemEnvVar objects. Array returned may be size zero but will not be null.


setEnvironmentVariableList

void setEnvironmentVariableList(
String[] envVarNames,
                                
String[] envVarValues)
Set the initial environment variable list entries, all in one shot, using a pair of String arrays: the first is the environment variable names, the second is the corresponding environment variable values.


addEnvironmentVariable

void addEnvironmentVariable(
String name,
                            
String value)
Add environment variable entry, given a name and value


addEnvironmentVariable

void addEnvironmentVariable(
IRemoteSystemEnvVar rsev)
Add environment variable entry, given a RemoteSystemEnvVar object


removeEnvironmentVariable

void removeEnvironmentVariable(
IRemoteSystemEnvVar rsev)
Remove environment variable entry given its RemoteSystemEnvVar object


removeEnvironmentVariable

void removeEnvironmentVariable(
String name)
Remove environment variable entry given only its environment variable name


getEnvironmentVariable


IRemoteSystemEnvVar getEnvironmentVariable(
String name)
Given an environment variable name, find its RemoteSystemEnvVar object. Returns null if not found!


getEnvironmentVariableValue


String getEnvironmentVariableValue(
String name)
Given an environment variable name, find its value. Returns null if not found.


getInvalidEnvironmentVariableNameCharacters


String getInvalidEnvironmentVariableNameCharacters()
Get the invalid characters for an environment variable name. Used by the environment variables property page to diagnose invalid environment variable names.


getHostEnvironmentVariables


List getHostEnvironmentVariables()

RSE
Release 3.0

Copyright (c) IBM Corporation and others 2000, 2008. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire