com.ptc.windchill.esi.bom
Class ESIBOMHeaderRenderer

java.lang.Object
  extended bycom.ptc.windchill.esi.rnd.BasicESIRenderer
      extended bycom.ptc.windchill.esi.bom.ESIBOMHeaderRenderer
All Implemented Interfaces:
ESIRenderer, Serializable

public class ESIBOMHeaderRenderer
extends BasicESIRenderer
implements Serializable

This class renders the output of BOM header (ie. ) in ESI DataResponse.

Supported API: true

Extendable: false

See Also:
Serialized Form

Field Summary
private static String CLASSNAME
           
private static String DATE_FORMAT_PATTERN
           
private  String groupName
           
private  TaskHelper helper
           
private  ESIMap map
           
protected static String MAP_FILE_PATH
           
private  ESIMapper mapper
           
private  WTPart part
           
private static String RESOURCE
           
private  Collection targets
           
protected static String wcAttList
           
 
Fields inherited from class com.ptc.windchill.esi.rnd.BasicESIRenderer
adapterName, PART_CLASS_NAME, TASK_URI, XML_META_NAME
 
Constructor Summary
ESIBOMHeaderRenderer()
           
 
Method Summary
protected  Element adjustElement(Element elem, String group, WTPart part, Eff eff, Collection targets)
          Allow subclasses to fix the contents of an element before it's added to the output group(s).
protected  void buildGroups()
          Builds the renderer output.
protected  String getGroupName()
          Gets the value of the attribute: groupName; The logical name of a VdbGroup.
protected  WTPart getPart()
          Gets the value of the attribute: part; The assembly part for this BOM.
protected  Collection getTargets()
          Gets the value of the attribute: targets; A collection ESITarget objects.
private  Element mapBOMHeaderElement(String grpName, Element e, WTPart part, String ufid, Eff eff, Collection targets)
           
 void setData(String groupName, WTPart part, Collection tgts, ESIEffectivityHandler effHandler)
          Store the attributes and reset any variables.
 void setData(String groupName, WTPart part, Collection tgts, ESIEffectivityHandler effHandler, String adapterName)
           
protected  void validate()
          Make sure part, groupName, and targets are correct.
 
Methods inherited from class com.ptc.windchill.esi.rnd.BasicESIRenderer
adjustEffectivities, adjustObjectID, adjustTargets, buildUfidString, getAdapterName, getAttsFromMapFile, getBuilder, getEffectivityHandler, getGroupInfo, getMap, getMapInfo, getTargetsFromAssns, getWCAttributeList, invokeQueryTask, invokeQueryTask, invokeQueryTask, mapElement, mapObject, render, setBuilder, setEffectivityHandler
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

targets

private Collection targets

groupName

private String groupName

part

private WTPart part

DATE_FORMAT_PATTERN

private static final String DATE_FORMAT_PATTERN
See Also:
Constant Field Values

map

private ESIMap map

mapper

private ESIMapper mapper

helper

private TaskHelper helper

MAP_FILE_PATH

protected static final String MAP_FILE_PATH

wcAttList

protected static String wcAttList
Constructor Detail

ESIBOMHeaderRenderer

public ESIBOMHeaderRenderer()
Method Detail

getTargets

protected Collection getTargets()
Gets the value of the attribute: targets; A collection ESITarget objects.

Supported API: true

Returns:
Collection

getGroupName

protected String getGroupName()
Gets the value of the attribute: groupName; The logical name of a VdbGroup.

Supported API: true

Returns:
String

getPart

protected WTPart getPart()
Gets the value of the attribute: part; The assembly part for this BOM.

Supported API: true

Returns:
WTPart

adjustElement

protected Element adjustElement(Element elem,
                                String group,
                                WTPart part,
                                Eff eff,
                                Collection targets)
                         throws ESIRendererException
Allow subclasses to fix the contents of an element before it's added to the output group(s). Default behavior is to return the argument.

Supported API: true

Parameters:
elem - The element to be updated.
group - The logical name of the group to which the element will be added.
part - The assembly part that is being processed.
eff - May be null.
targets - Collection of ESITarget objects.
Returns:
Element
Throws:
ESIRendererException

validate

protected void validate()
                 throws ESIRendererException
Make sure part, groupName, and targets are correct.

Supported API: true

Specified by:
validate in class BasicESIRenderer
Throws:
ESIRendererException

buildGroups

protected void buildGroups()
                    throws ESIRendererException
Builds the renderer output. Does the following:
  1. Obtains the targets for part.
  2. Maps the output.
  3. Calls adjustObjectID() on the base class.
  4. Calls adjustTargets() on the base class.
  5. Calls adjustEffectivities() on the base class.
  6. Calls adjustElement().
  7. Passes the element to the VdbBuilder.


Supported API: true

Specified by:
buildGroups in class BasicESIRenderer
Throws:
ESIRendererException

setData

public void setData(String groupName,
                    WTPart part,
                    Collection tgts,
                    ESIEffectivityHandler effHandler)
Store the attributes and reset any variables.

Supported API: false

Parameters:
groupName -
part -
tgts -
effHandler -

setData

public void setData(String groupName,
                    WTPart part,
                    Collection tgts,
                    ESIEffectivityHandler effHandler,
                    String adapterName)

mapBOMHeaderElement

private Element mapBOMHeaderElement(String grpName,
                                    Element e,
                                    WTPart part,
                                    String ufid,
                                    Eff eff,
                                    Collection targets)
                             throws ESIRendererException
Throws:
ESIRendererException