com.ptc.windchill.enterprise.dataops.server
Class DataMaintHelper

java.lang.Object
  extended bycom.ptc.windchill.enterprise.dataops.server.DataMaintHelper

public class DataMaintHelper
extends Object

Title:

Description: Helper methods to work with DataMaintRecord classes.

Copyright: Copyright (c) 2004

Company:


Field Summary
private static String RESOURCE
           
 
Constructor Summary
DataMaintHelper()
           
 
Method Summary
static PurgeRecord addPreviewFileToPurgeRecord(WTCollection col, PurgeRecord record)
           
static PurgeRecord createPurgeRecord(String recordName, String description, WTContainerRef containerRef, boolean doArchive, CollectionCriteria criteria, RelationshipMap relMap)
          Create and store PurgeRecord.
static RestoreRecord createRestoreRecord(String name, String description, Archive archive, WTContainerRef containerRef)
          Create and store RestoreRecord.
static ArchiveRecord getArchiveRecordFromPurgeRecord(PurgeRecord purge)
           
private static void PP(String s)
           
 
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
Constructor Detail

DataMaintHelper

public DataMaintHelper()
Method Detail

getArchiveRecordFromPurgeRecord

public static ArchiveRecord getArchiveRecordFromPurgeRecord(PurgeRecord purge)
                                                     throws WTException
Throws:
WTException

createPurgeRecord

public static PurgeRecord createPurgeRecord(String recordName,
                                            String description,
                                            WTContainerRef containerRef,
                                            boolean doArchive,
                                            CollectionCriteria criteria,
                                            RelationshipMap relMap)
                                     throws WTException
Create and store PurgeRecord. If doArchive=true, create and store ArchiveRecord of the same name and container reference, and connect it to PurgeRecord as "related record". In addition, set CollectionCriteria and RelationshipMap.

Parameters:
recordName -
containerRef -
description -
doArchive -
criteria -
Returns:
Throws:
WTException

addPreviewFileToPurgeRecord

public static PurgeRecord addPreviewFileToPurgeRecord(WTCollection col,
                                                      PurgeRecord record)
                                               throws WTException
Throws:
WTException

createRestoreRecord

public static RestoreRecord createRestoreRecord(String name,
                                                String description,
                                                Archive archive,
                                                WTContainerRef containerRef)
                                         throws WTException
Create and store RestoreRecord. No actual restore is done at this point.

Parameters:
name - Name of RestoreRecord
archive - Archive object (pointer to the archive file) which should be restored
containerRef - Container context to store RestoreRecord in. Can be null, in which case the context of Archive object will be used.
Returns:
Throws:
WTException

PP

private static void PP(String s)