public class JDFSpawn extends Object
Modifier and Type | Field and Description |
---|---|
boolean |
bCopyComments
if true, copy comments
|
boolean |
bCopyCustomerInfo
if true, copy customer info
|
boolean |
bCopyNodeInfo
if true, copy node info
|
boolean |
bFixResources
if true, ensure sufficient partitioning of rw resources, else do not add missing partitions
|
boolean |
bSpawnIdentical
if true, copy identical elements
|
boolean |
bSpawnROPartsOnly
if true, reduce read only partitions, else retain entire resource
|
boolean |
bSpawnRWPartsMultiple
if true, allow multiple rw spawning of resources note that this feature causes race conditions when merging
|
static int |
exAlreadyMerged
exception id for multiple merge attempt
|
static int |
exMultiSpawnRW
exception id for multiple rw spawns
|
String |
parentURL |
String |
spawnURL |
VString |
vRWResources_in
list of all resources to copy rw
|
VJDFAttributeMap |
vSpawnParts
list of partitions to spawn
|
Modifier and Type | Method and Description |
---|---|
protected void |
calcAuditSpawnIDs(JDFSpawned spawnAudit,
HashSet<String> vvRO,
HashSet<String> vvRW) |
Collection<JDFResource> |
checkSpawnedResources()
return the resources that would be spawned RW multiple times
|
Collection<JDFResource> |
cleanSpawnedResources()
cleans up node so that no multiple spawnIDs remain
removes SpawnIDS and SpawnStatus from all resources that are spawnedRW by this spawn; note that the vRWResources_in and vSpawnParts MUST be populated audits are not modified |
void |
setNode(JDFNode newNode)
set the node to spawn
|
JDFNode |
spawn()
spawn a node; url is the file name of the new node, vRWResourceUsage is the vector of Resources Usages (or Names if no usage exists for the process) that are spawned RW, all others are spawned
read only; vParts is the vector of part maps that are to be spawned, defaults to no part, i.e. the whole thing
the format is one of:
ResName:Input ResName:Output ResName:ProcessUsage |
JDFNode |
spawn(String _parentURL,
String _spawnURL,
VString _vRWResources_in,
VJDFAttributeMap _vSpawnParts,
boolean _bSpawnROPartsOnly,
boolean _bCopyNodeInfo,
boolean _bCopyCustomerInfo,
boolean _bCopyComments)
spawn a node; url is the file name of the new node, vRWResourceUsage is the vector of Resources Usages (or Names if no usage exists for the process) that are spawned RW, all others are spawned
read only; vParts is the vector of part maps that are to be spawned, defaults to no part, i.e. the whole thing
|
JDFNode |
spawnInformative()
spawn a node in informative mode without modifying the root JDF; url is the file name of the new node, the parameters except for the list of rw resources, which are by definition empty, are
identical to those of Spawn
vRWResourceUsage is the vector of Resources Usages, Resource Names or Resource IDs that are spawned RW, all others are spawned read only; vParts is the vector of part maps that are to be
spawned, defaults to no part, i.e. the whole thing
|
JDFNode |
spawnInformative(String _parentURL,
String _spawnURL,
VJDFAttributeMap _vSpawnParts,
boolean _bSpawnROPartsOnly,
boolean _bCopyNodeInfo,
boolean _bCopyCustomerInfo,
boolean _bCopyComments)
spawn a node in informative mode without modifying the root JDF; url is the file name of the new node, the parameters except for the list of rw resources, which are by definition empty, are
identical to those of Spawn
vRWResourceUsage is the vector of Resources Usages, Resource Names or Resource IDs that are spawned RW, all others are spawned read only; vParts is the vector of part maps that are to be
spawned, defaults to no part, i.e. the whole thing
|
String |
toString() |
JDFNode |
unSpawn(String spawnID)
Method unSpawn. undo a spawn, removing any and all bookkeeping of that spawning
|
void |
unSpawnChild(JDFNode childNode)
remove all spawn related stuff from the spawned childNode
|
public boolean bSpawnROPartsOnly
public boolean bSpawnRWPartsMultiple
public boolean bCopyNodeInfo
public boolean bSpawnIdentical
public boolean bCopyCustomerInfo
public boolean bCopyComments
public boolean bFixResources
public String parentURL
public String spawnURL
public VString vRWResources_in
public VJDFAttributeMap vSpawnParts
public static final int exAlreadyMerged
public static final int exMultiSpawnRW
public JDFSpawn(JDFNode nodeToSpawn)
nodeToSpawn
- the node to be spawnedpublic void setNode(JDFNode newNode)
newNode
- the node to setJDFException
- if node is NOT in the same document as the initial nodepublic JDFNode spawn()
public Collection<JDFResource> cleanSpawnedResources()
public Collection<JDFResource> checkSpawnedResources()
protected void calcAuditSpawnIDs(JDFSpawned spawnAudit, HashSet<String> vvRO, HashSet<String> vvRW)
public JDFNode spawnInformative()
public JDFNode spawn(String _parentURL, String _spawnURL, VString _vRWResources_in, VJDFAttributeMap _vSpawnParts, boolean _bSpawnROPartsOnly, boolean _bCopyNodeInfo, boolean _bCopyCustomerInfo, boolean _bCopyComments)
_parentURL
- _spawnURL
- : URL of the spawned JDF file_vRWResources_in
- : vector of resource names and Usage / ProcessUsage that are spawned as rw _vSpawnParts
- vector of mAttributes that describe the parts to spawn, only valid PartIDKeys are allowed_bSpawnROPartsOnly
- if true, only the parts of RO resources that are specified in vParts are spawned, else the complete resource is spawned_bCopyNodeInfo
- copy the NodeInfo elements into the Ancestors_bCopyCustomerInfo
- copy the CustomerInfo elements into the Ancestors_bCopyComments
- copy the Comment elements into the Ancestorspublic JDFNode spawnInformative(String _parentURL, String _spawnURL, VJDFAttributeMap _vSpawnParts, boolean _bSpawnROPartsOnly, boolean _bCopyNodeInfo, boolean _bCopyCustomerInfo, boolean _bCopyComments)
_parentURL
- _spawnURL
- : URL of the spawned JDF file_vSpawnParts
- : vector of mAttributes that describe the parts to spawn_bSpawnROPartsOnly
- if true, only the parts of RO resources that are specified in vParts are spawned, else the complete resource is spawned_bCopyNodeInfo
- copy the NodeInfo elements into the Ancestors_bCopyCustomerInfo
- copy the CustomerInfo elements into the Ancestors_bCopyComments
- copy the Comment elements into the Ancestorspublic JDFNode unSpawn(String spawnID)
spawnID
- spawnID of the spawn to undo, if null find the first spawned nodepublic String toString()
toString
in class Object
Object.toString()
public void unSpawnChild(JDFNode childNode)
childNode
- Copyright © 2018. All rights reserved.