FileDocCategorySizeDatePackage
SOSLabel.javaAPI DocApache Ant 1.702993Wed Dec 13 06:16:20 GMT 2006org.apache.tools.ant.taskdefs.optional.sos

SOSLabel

public class SOSLabel extends SOS
Labels Visual SourceSafe files via a SourceOffSite server.
ant.task
name="soslabel" category="scm"

Fields Summary
Constructors Summary
Methods Summary
protected org.apache.tools.ant.types.CommandlinebuildCmdLine()
Build the command line
AddLabel required parameters: -server -name -password -database -project -label
AddLabel optional parameters: -verbose -comment

return
Commandline the generated command to be executed

        commandLine = new Commandline();

        // add -command AddLabel to the commandline
        commandLine.createArgument().setValue(SOSCmd.FLAG_COMMAND);
        commandLine.createArgument().setValue(SOSCmd.COMMAND_LABEL);

        getRequiredAttributes();

        // a label is required
        if (getLabel() == null) {
            throw new BuildException("label attribute must be set!", getLocation());
        }
        commandLine.createArgument().setValue(SOSCmd.FLAG_LABEL);
        commandLine.createArgument().setValue(getLabel());

        // -verbose
        commandLine.createArgument().setValue(getVerbose());
        // Look for a comment
        if (getComment() != null) {
            commandLine.createArgument().setValue(SOSCmd.FLAG_COMMENT);
            commandLine.createArgument().setValue(getComment());
        }
        return commandLine;
    
public voidsetComment(java.lang.String comment)
The comment to apply to all files being labelled.

param
comment The new comment value

        super.setInternalComment(comment);
    
public voidsetLabel(java.lang.String label)
The label to apply the the files in SourceSafe.

param
label The new label value
ant.attribute
group="required"

        super.setInternalLabel(label);
    
public voidsetVersion(java.lang.String version)
The version number to label.

param
version The new version value

        super.setInternalVersion(version);