|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ptc.windchill.upgrade.dust.ExportBlobDataServer
For the given class and its descendents, finds all properties of those classes which are blobs. For each blob, extract it from the database, and write the encoded object to the data file. A file will be written for each class examined and will have the same name as the class with a .data suffix.
Field Summary | |
private static boolean |
DEVELOPER_MODE
|
private boolean |
enforce
|
private static String |
EXPORT_SERVER_METHOD_NAME
|
private ExportXMLHandler |
handler
|
static int |
INLINEBLOB
|
private static ExportBlobDataServer |
instance__
|
private ExportLogging |
logger
|
private static int |
MAX_OBJECTS
|
private int |
number_of_classes_processed
|
static int |
ORACLE_8_0_BLOB_TYPE
|
private static int |
PAGE_SIZE
|
private static int |
PAGE_SIZE_DEFAULT
|
private PagingIteratorIfc |
pagingIterator
|
private static String |
RESOURCE
|
private Hashtable |
serializedClasses
|
private static String |
SERVER_CLASS_NAME
|
static int |
SMALLBLOB
|
private TimerStats |
timerStats
|
private long |
totalInstanceCount_
|
private boolean |
useMaxObjects
|
Fields inherited from interface wt.method.RemoteAccess |
versionID |
Constructor Summary | |
ExportBlobDataServer()
|
Method Summary | |
private void |
addIfNeeded(SortedSet set,
ClassInfo class_info)
Return the set of classes and their descendants, including only those which are concrete and persistable. |
private boolean |
changeAccessControl(boolean setting)
Changes the access control, returning the initial setting. |
private String |
exportBlobDataFor_(String output_dir,
String root_class_name,
String release_level,
Integer page_size,
Integer max_objects)
|
static String |
exportBlobDataFor(String dir,
String class_name,
String release_level,
Integer page_size,
Integer max_objects)
Request to rewrite all blobs for each concrete persistable class to .xml files. |
private SortedSet |
getAllClassNames(String root_class_name)
Return the set of the class and its descendants, including only those which are concrete and persistable. |
private SortedSet |
getAllClassNames(String[] root_class_names)
Return the set of classes and their descendants, including only those which are concrete and persistable. |
private PropertyDescriptor[] |
getBlobPropertyDescriptors(ClassInfo ci)
Returns an array of PropertyDescriptor with an entry for each property that is a persistent blob type. |
static ExportBlobDataServer |
getInstance()
|
private File |
getOutputDirectory(String output_dir)
Ensures the directory specified by the user argument is usable. |
private void |
interrupt()
Halt processing. |
private boolean |
isBlobLike(PropertyDescriptor pd,
ColumnDescriptor[] cds)
Determines whether the property is stored in as a blob-like object. |
private static boolean |
isConcretePersistable(ClassInfo class_info)
Returns true if the class is both concrete and persistable. |
static boolean |
isSQLTypeBlob(int sql_type)
|
private int |
queryAndExport(ClassInfo class_info,
PropertyDescriptor[] blob_pds)
For each instance of class_info type classes, read blob data, serialize it, encode it, and write it as XML to a data file. |
private Object |
readBlob(Persistable p,
PropertyDescriptor blob_pds)
Returns a de-serialized blob object. |
private void |
stop()
Halt processing. |
private void |
writeBlobsForClass(String class_name,
File dir,
int total_number_of_classes)
The main loop called for each class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final boolean DEVELOPER_MODE
private static final int PAGE_SIZE_DEFAULT
private static int PAGE_SIZE
private static int MAX_OBJECTS
private static final String RESOURCE
private static final String SERVER_CLASS_NAME
private static final String EXPORT_SERVER_METHOD_NAME
public static final int SMALLBLOB
public static final int INLINEBLOB
public static final int ORACLE_8_0_BLOB_TYPE
private static ExportBlobDataServer instance__
private ExportLogging logger
private boolean enforce
private boolean useMaxObjects
private TimerStats timerStats
private ExportXMLHandler handler
private long totalInstanceCount_
private Hashtable serializedClasses
private int number_of_classes_processed
private PagingIteratorIfc pagingIterator
Constructor Detail |
public ExportBlobDataServer() throws WTException
Method Detail |
public static ExportBlobDataServer getInstance() throws WTException
WTException
public static String exportBlobDataFor(String dir, String class_name, String release_level, Integer page_size, Integer max_objects) throws WTException
dir
- the output directoryclass_name
- export blobs for objects of this class and all subclasses/implementations of this class
WTException
private String exportBlobDataFor_(String output_dir, String root_class_name, String release_level, Integer page_size, Integer max_objects) throws WTException
WTException
private void writeBlobsForClass(String class_name, File dir, int total_number_of_classes) throws WTException, InterruptedException
WTException
InterruptedException
private int queryAndExport(ClassInfo class_info, PropertyDescriptor[] blob_pds) throws SAXException, WTException, InterruptedException
SAXException
WTException
InterruptedException
private Object readBlob(Persistable p, PropertyDescriptor blob_pds) throws WTException, InvocationTargetException, IllegalAccessException
WTException
InvocationTargetException
IllegalAccessException
private PropertyDescriptor[] getBlobPropertyDescriptors(ClassInfo ci) throws WTException
WTException
private boolean isBlobLike(PropertyDescriptor pd, ColumnDescriptor[] cds)
public static boolean isSQLTypeBlob(int sql_type)
private SortedSet getAllClassNames(String root_class_name) throws WTException
WTException
private SortedSet getAllClassNames(String[] root_class_names) throws WTException
WTException
private void addIfNeeded(SortedSet set, ClassInfo class_info)
private static boolean isConcretePersistable(ClassInfo class_info)
private void interrupt()
private void stop()
private boolean changeAccessControl(boolean setting)
private File getOutputDirectory(String output_dir) throws WTException
WTException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |