Copyright @ 2002 SAP. All Rights Reserved.

com.sap.tc.complib
Interface BuildVariant


public interface BuildVariant


Method Summary
 java.util.Map emptyVariantMapping()
          Remove all mappings from the map or create an empty Map.
 java.util.List getBuildOptionNames()
          gets a List with the names of the build options for this build variant
 java.util.List getBuildOptionValues(java.lang.String buildOptionName)
          gets a List with the values of the build option.
 boolean getIsRequired()
          gets if the make of this build variant is required for sucessful activation
 java.lang.String getName()
          gets ethe name of the build variant
 java.util.Map getVariantMapping()
          gets the Map with the build variant mappings.
 void putBuildOption(java.lang.String buildOptionName, java.util.List buildOptionValues)
          adds a new multi-valued build option or replaces an existing one with that name.
 void putBuildOption(java.lang.String buildOptionName, java.lang.String buildOptionValue)
          adds a new single valued build option or replaces an existing one with that name.
 void removeBuildOption(java.lang.String optionName)
          removes the given build option
 void serialize(XMLWriter writer, boolean isBuildable)
          Serializes the source state info to the given XMLWriter.
 void serialize(XMLWriter writer, java.lang.String schemaVersion, boolean isBuildable)
           
 void setIsRequired(boolean value)
          sets if the make of this build variant is required for sucessful activation
 void setName(java.lang.String value)
          sets the name of the build variant
 void validate()
          Verifies that the object is valid (e.g. mandatory children and attributes).
 

Method Detail

getName

public java.lang.String getName()
gets ethe name of the build variant

setName

public void setName(java.lang.String value)
sets the name of the build variant

getIsRequired

public boolean getIsRequired()
gets if the make of this build variant is required for sucessful activation

setIsRequired

public void setIsRequired(boolean value)
sets if the make of this build variant is required for sucessful activation

getBuildOptionNames

public java.util.List getBuildOptionNames()
gets a List with the names of the build options for this build variant

getBuildOptionValues

public java.util.List getBuildOptionValues(java.lang.String buildOptionName)
gets a List with the values of the build option. The build option must exist. If there are no values defined yet, an empty List is returned. You get the internally used list. Use it directly to add or remove values. Important: Finally the list must contain at least one element

putBuildOption

public void putBuildOption(java.lang.String buildOptionName,
                           java.util.List buildOptionValues)
adds a new multi-valued build option or replaces an existing one with that name.

putBuildOption

public void putBuildOption(java.lang.String buildOptionName,
                           java.lang.String buildOptionValue)
adds a new single valued build option or replaces an existing one with that name.

removeBuildOption

public void removeBuildOption(java.lang.String optionName)
removes the given build option

getVariantMapping

public java.util.Map getVariantMapping()
gets the Map with the build variant mappings. The key is the name of the used compartment. The value is the name of the mapped build variant to be used You get the internally used Map. Use it directly to add or remove entries.

emptyVariantMapping

public java.util.Map emptyVariantMapping()
Remove all mappings from the map or create an empty Map.

serialize

public void serialize(XMLWriter writer,
                      boolean isBuildable)
               throws ValidationException
Serializes the source state info to the given XMLWriter.
Parameters:
writer - the XMLWriter to use for serialization.
isBuildable - true if the containg compartmnet can be built in the configuration

serialize

public void serialize(XMLWriter writer,
                      java.lang.String schemaVersion,
                      boolean isBuildable)
               throws ValidationException

validate

public void validate()
              throws ValidationException
Verifies that the object is valid (e.g. mandatory children and attributes). Consistency of variant mappings (existing targets) is checked by the configuration object Completeness of variant mappings is not checked (impossible based on configuration data only).
Throws:
ValidationException - if the object is not valid.

Copyright @ 2002 SAP. All Rights Reserved.