com.intel.gpe.client2.adapters
Class ClientAdapter

java.lang.Object
  extended by com.intel.gpe.client2.adapters.ClientAdapter
All Implemented Interfaces:
AsyncClient, Client, ListClient, MessageProvider, SimpleMessageProvider, SelectionClient

public class ClientAdapter
extends java.lang.Object
implements Client, SelectionClient, ListClient

The class delegating functionality to 3 providers:

  • AsyncClient
  • MessageProvider
  • SelectionClient
  • ListClient
  • Version:
    $Id: ClientAdapter.java,v 1.16 2007/02/15 14:01:38 dizhigul Exp $
    Author:
    Alexander Lukichev, Valery Shorin

    Constructor Summary
    ClientAdapter(AsyncClient asyncClient, MessageProvider messageProvider, SelectionClient selectionClient, ListClient listClient, GridBeanSpaceProvider gridBeanSpaceProvider, FileProvider fileProvider, GPESecurityManager securityManager)
               
     
    Method Summary
     void executeRequest(Request request, com.intel.gpe.util.observer.IObserver observer)
              Execute request
     void executeRequest(Request request, IObserver observer)
              Deprecated. 
     void fetchFiles(com.intel.gpe.clients.api.StorageClient storageClient, java.util.List<FileTransfer> transfers, com.intel.gpe.util.observer.IObserver observer, FileTransferProgressListener progress)
               
     void fetchFiles(com.intel.gpe.clients.api.StorageClient storageClient, java.util.List<Pair<GPEFile,java.lang.String>> transfers, com.intel.gpe.util.observer.IObserver observer)
              Deprecated. 
     void fetchFiles(com.intel.gpe.clients.api.StorageClient storageClient, java.util.List<Pair<GPEFile,java.lang.String>> transfers, com.intel.gpe.util.observer.IObserver observer, FileFetchingProgressListener progress)
              Deprecated. 
     MessageAdapter getMessageAdapter()
              Deprecated. 
     java.util.List<com.intel.gpe.clients.api.RegistryClient> getRegistries()
              Get client's registries list.
     java.util.List<ClientWrapper<com.intel.gpe.clients.api.RegistryClient,java.lang.String>> getRegistryClientWrapperList()
              Get the list of the regisrties available in the current user's context.
     com.intel.gpe.clients.api.RegistryClient getSelectedRegistry()
              Get the selected registry.
     ClientWrapper<com.intel.gpe.clients.api.RegistryClient,java.lang.String> getSelectedRegistryWrapper()
              Get the wrapper of the client to the selected registry.
     com.intel.gpe.clients.api.TargetSystemClient getSelectedTargetSystem()
              Get the selected target system.
     ClientWrapper<com.intel.gpe.clients.api.TargetSystemClient,java.lang.String> getSelectedTargetSystemWrapper()
              Get the wrapper of the client to the selected target system.
     NamedGPEFile newTemporaryFile(java.lang.String localFileName)
              Create the temporary file in the GridBean's local temporary directory corresponding to the remote file.
     void setGridBeanSpaceProvider(GridBeanSpaceProvider gridBeanSpaceProvider)
               
     void show(GPEPanel panel)
              Deprecated. 
     void show(GPEPanel panel, INode node)
              Display the panel
     void showException(java.lang.String message, java.lang.Throwable exception)
              Show an error message with the stack trace.
     void showMessage(java.lang.String message)
              Show a single message.
     
    Methods inherited from class java.lang.Object
    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
     

    Constructor Detail

    ClientAdapter

    public ClientAdapter(AsyncClient asyncClient,
                         MessageProvider messageProvider,
                         SelectionClient selectionClient,
                         ListClient listClient,
                         GridBeanSpaceProvider gridBeanSpaceProvider,
                         FileProvider fileProvider,
                         GPESecurityManager securityManager)
    Method Detail

    executeRequest

    public void executeRequest(Request request,
                               com.intel.gpe.util.observer.IObserver observer)
    Description copied from interface: AsyncClient
    Execute request

    Specified by:
    executeRequest in interface AsyncClient

    executeRequest

    @Deprecated
    public void executeRequest(Request request,
                                          IObserver observer)
    Deprecated. 

    Description copied from interface: AsyncClient
    Execute request

    Specified by:
    executeRequest in interface AsyncClient

    show

    @Deprecated
    public void show(GPEPanel panel)
    Deprecated. 

    Description copied from interface: SimpleMessageProvider
    Display the panel

    Specified by:
    show in interface SimpleMessageProvider

    show

    public void show(GPEPanel panel,
                     INode node)
    Description copied from interface: SimpleMessageProvider
    Display the panel

    Specified by:
    show in interface SimpleMessageProvider
    Parameters:
    panel - the panel
    node - the preferences node to store the window settings

    getSelectedTargetSystem

    public com.intel.gpe.clients.api.TargetSystemClient getSelectedTargetSystem()
    Description copied from interface: Client
    Get the selected target system.

    Specified by:
    getSelectedTargetSystem in interface Client
    Returns:
    the TargetSystemClient object; null if nothing is selected

    getRegistries

    public java.util.List<com.intel.gpe.clients.api.RegistryClient> getRegistries()
    Description copied from interface: Client
    Get client's registries list.

    Specified by:
    getRegistries in interface Client
    Returns:
    the list of RegistryClient objects

    getSelectedRegistry

    public com.intel.gpe.clients.api.RegistryClient getSelectedRegistry()
    Description copied from interface: Client
    Get the selected registry.

    Specified by:
    getSelectedRegistry in interface Client
    Returns:
    the selected registry

    getSelectedRegistryWrapper

    public ClientWrapper<com.intel.gpe.clients.api.RegistryClient,java.lang.String> getSelectedRegistryWrapper()
    Description copied from interface: SelectionClient
    Get the wrapper of the client to the selected registry.

    Specified by:
    getSelectedRegistryWrapper in interface SelectionClient
    Returns:
    the list of WSRPClienItem objects where String is registry client object representation

    getSelectedTargetSystemWrapper

    public ClientWrapper<com.intel.gpe.clients.api.TargetSystemClient,java.lang.String> getSelectedTargetSystemWrapper()
    Description copied from interface: SelectionClient
    Get the wrapper of the client to the selected target system.

    Specified by:
    getSelectedTargetSystemWrapper in interface SelectionClient
    Returns:
    the WSRPClientItem object containing string representation and the target system client object; null if nothing is selected

    getRegistryClientWrapperList

    public java.util.List<ClientWrapper<com.intel.gpe.clients.api.RegistryClient,java.lang.String>> getRegistryClientWrapperList()
    Description copied from interface: ListClient
    Get the list of the regisrties available in the current user's context.

    Specified by:
    getRegistryClientWrapperList in interface ListClient
    Returns:

    fetchFiles

    @Deprecated
    public void fetchFiles(com.intel.gpe.clients.api.StorageClient storageClient,
                                      java.util.List<Pair<GPEFile,java.lang.String>> transfers,
                                      com.intel.gpe.util.observer.IObserver observer)
    Deprecated. 

    Description copied from interface: Client
    Fetch the files from the remote file system.

    Specified by:
    fetchFiles in interface Client
    Parameters:
    storageClient - - the storage to fetch the files from
    observer - - the observer

    fetchFiles

    @Deprecated
    public void fetchFiles(com.intel.gpe.clients.api.StorageClient storageClient,
                                      java.util.List<Pair<GPEFile,java.lang.String>> transfers,
                                      com.intel.gpe.util.observer.IObserver observer,
                                      FileFetchingProgressListener progress)
    Deprecated. 

    Description copied from interface: Client
    Fetch the files from the remote file system. A progress listener may be specified.

    Specified by:
    fetchFiles in interface Client
    Parameters:
    storageClient - - the storage to fetch the files from
    observer - - the observer
    progress - - the progress listener

    newTemporaryFile

    public NamedGPEFile newTemporaryFile(java.lang.String localFileName)
    Description copied from interface: Client
    Create the temporary file in the GridBean's local temporary directory corresponding to the remote file.

    Specified by:
    newTemporaryFile in interface Client
    Parameters:
    localFileName - - the local name of the file
    Returns:
    the created NamedGPEFile instance

    setGridBeanSpaceProvider

    public void setGridBeanSpaceProvider(GridBeanSpaceProvider gridBeanSpaceProvider)

    getMessageAdapter

    @Deprecated
    public MessageAdapter getMessageAdapter()
    Deprecated. 

    Description copied from interface: Client
    Get the MessageAdapter.

    Specified by:
    getMessageAdapter in interface Client
    Returns:
    the MessageAdapter MessageAdapter object;

    fetchFiles

    public void fetchFiles(com.intel.gpe.clients.api.StorageClient storageClient,
                           java.util.List<FileTransfer> transfers,
                           com.intel.gpe.util.observer.IObserver observer,
                           FileTransferProgressListener progress)
    Specified by:
    fetchFiles in interface Client
    progress - the progress listener (may be null)

    showException

    public void showException(java.lang.String message,
                              java.lang.Throwable exception)
    Description copied from interface: MessageProvider
    Show an error message with the stack trace.

    Specified by:
    showException in interface MessageProvider
    Parameters:
    message - the message
    exception - the exception containing the stack trace

    showMessage

    public void showMessage(java.lang.String message)
    Description copied from interface: MessageProvider
    Show a single message.

    Specified by:
    showMessage in interface MessageProvider
    Parameters:
    message - the message string


    Copyright © 2008. All Rights Reserved.