站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > NetBeans API Javadoc 4.1.0

CommandCustomizationSupport (NetBeans VCS API) - NetBeans API Javadoc 4.1.0

 

org.netbeans.modules.vcscore.commands
Class CommandCustomizationSupport

java.lang.Object
  extended byorg.netbeans.modules.vcscore.commands.CommandCustomizationSupport

public class CommandCustomizationSupport
extends Object

This class contains a support for VCS commands customization.


Field Summary
static String GLOBAL_INPUT_DESCRIPTOR
          The name of the variable, where the global input descriptor is stored.
static String GLOBAL_INPUT_EXPRESSION
          The name of the variable, where the global input expression is stored.
static String INPUT_DESCRIPTOR_PARSED
           
static String INPUT_DESCRIPTOR_RESOURCE_BUNDLES
           
 
Method Summary
static void addImportantFiles(Collection fos, Table res, boolean all, VcsFileSystem fileSystem, boolean doNotTestFS)
          Add files.
static void commandNotification(VcsCommandExecutor vce, String notification, CommandExecutionContext executionContext)
           
static VariableInputDialog createInputDialog(CommandExecutionContext executionContext, String exec, Hashtable vars, VcsDescribedCommand dcmd, boolean[] forEachFile, StringBuffer retTitle)
           
static void defineGlobalOptions(Map vars, CommandExecutionContext executionContext, VcsCommand cmd)
          Insert the global options into the map of variables.
static FileObject[] getApplicableFiles(CommandExecutionContext executionContext, VcsCommand cmd, FileObject[] files)
           
static boolean preCustomize(CommandExecutionContext executionContext, VcsCommand cmd, Hashtable vars)
          Perform the pre-customization of a command.
static String preCustomizeExec(CommandExecutionContext executionContext, VcsCommand cmd, Hashtable vars)
          Perform the pre-customization of a command's execution string.
static StructuredExec preCustomizeStructuredExec(CommandExecutionContext executionContext, VcsCommand cmd, Hashtable vars)
          Perform the pre-customization of a command's structured execution string.
static void setupUncustomizedCommand(CommandExecutionContext executionContext, String exec, Hashtable vars, VcsCommand cmd)
          Setup some necessary variables, but do not present any GUI - the command does not wish to be customized.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GLOBAL_INPUT_DESCRIPTOR

public static final String GLOBAL_INPUT_DESCRIPTOR
The name of the variable, where the global input descriptor is stored.

See Also:
Constant Field Values

GLOBAL_INPUT_EXPRESSION

public static final String GLOBAL_INPUT_EXPRESSION
The name of the variable, where the global input expression is stored. This expression will be inserted to the execution string instead of ${USER_GLOBAL_PARAM}

See Also:
Constant Field Values

INPUT_DESCRIPTOR_PARSED

public static final String INPUT_DESCRIPTOR_PARSED
See Also:
Constant Field Values

INPUT_DESCRIPTOR_RESOURCE_BUNDLES

public static final String INPUT_DESCRIPTOR_RESOURCE_BUNDLES
See Also:
Constant Field Values
Method Detail

addImportantFiles

public static void addImportantFiles(Collection fos,
                                     Table res,
                                     boolean all,
                                     VcsFileSystem fileSystem,
                                     boolean doNotTestFS)
Add files.

Parameters:
res - the Table of path and FileObject pairs.
all - whether to add unimportant files as well
fileSystem - the file system
doNotTestFS - if true, FileObjects will not be tested whether they belong to VcsFileSystem

getApplicableFiles

public static FileObject[] getApplicableFiles(CommandExecutionContext executionContext,
                                              VcsCommand cmd,
                                              FileObject[] files)

preCustomize

public static boolean preCustomize(CommandExecutionContext executionContext,
                                   VcsCommand cmd,
                                   Hashtable vars)
Perform the pre-customization of a command. After this it's necessary to call preCustomizeExec(org.netbeans.modules.vcscore.commands.CommandExecutionContext, org.netbeans.modules.vcscore.commands.VcsCommand, java.util.Hashtable) or preCustomizeStructuredExec(org.netbeans.modules.vcscore.commands.CommandExecutionContext, org.netbeans.modules.vcscore.commands.VcsCommand, java.util.Hashtable)

Returns:
false when the precustomization was cancelled, true otherwise.

preCustomizeExec

public static String preCustomizeExec(CommandExecutionContext executionContext,
                                      VcsCommand cmd,
                                      Hashtable vars)
Perform the pre-customization of a command's execution string. Should be called after preCustomize(org.netbeans.modules.vcscore.commands.CommandExecutionContext, org.netbeans.modules.vcscore.commands.VcsCommand, java.util.Hashtable).

Returns:
the new execution string of the command or null when the precustomization was cancelled.

preCustomizeStructuredExec

public static StructuredExec preCustomizeStructuredExec(CommandExecutionContext executionContext,
                                                        VcsCommand cmd,
                                                        Hashtable vars)
Perform the pre-customization of a command's structured execution string. Should be called after preCustomize(org.netbeans.modules.vcscore.commands.CommandExecutionContext, org.netbeans.modules.vcscore.commands.VcsCommand, java.util.Hashtable).

Returns:
the new structured execution property of the command or null when the precustomization was cancelled.

defineGlobalOptions

public static void defineGlobalOptions(Map vars,
                                       CommandExecutionContext executionContext,
                                       VcsCommand cmd)
Insert the global options into the map of variables.


commandNotification

public static void commandNotification(VcsCommandExecutor vce,
                                       String notification,
                                       CommandExecutionContext executionContext)

setupUncustomizedCommand

public static void setupUncustomizedCommand(CommandExecutionContext executionContext,
                                            String exec,
                                            Hashtable vars,
                                            VcsCommand cmd)
                                     throws UserCancelException
Setup some necessary variables, but do not present any GUI - the command does not wish to be customized. The only exception is a prompt for password. This method just sets the password (and prompt for it if it's not set).

Throws:
UserCancelException

createInputDialog

public static VariableInputDialog createInputDialog(CommandExecutionContext executionContext,
                                                    String exec,
                                                    Hashtable vars,
                                                    VcsDescribedCommand dcmd,
                                                    boolean[] forEachFile,
                                                    StringBuffer retTitle)
                                             throws UserCancelException
Throws:
UserCancelException

 

Built on May 4 2005.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.