wt.epm.upgrade
Class I3MigratorR7

java.lang.Object
  extended bywt.epm.upgrade.I3MigratorR7
All Implemented Interfaces:
JavaMigrator

public class I3MigratorR7
extends Object
implements JavaMigrator


Field Summary
private static String JAR
          This migrator updates I-Cubed Pro/E authored EPMDocuments to be consistent with Wildfire/WMPro.
private static String ZIP
           
 
Constructor Summary
I3MigratorR7()
           
 
Method Summary
protected  boolean isContentAPackage(String cdata)
           
private  boolean isJar(String fileName)
           
protected  String lastExtension(String cdata)
           
private  boolean migrateCatiaPackages(DirectiveServices ds)
           
private  int renameContent(DirectiveServices ds, String jarName, long docId)
           
 boolean runMigration(DirectiveServices directive_services)
          Run the migration.
protected  String stripName(String modelName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

JAR

private static final String JAR
This migrator updates I-Cubed Pro/E authored EPMDocuments to be consistent with Wildfire/WMPro. It does the following: Identify Pro/E I3 published EPMDocs and mark the owner application as "I3 Cad Mgr". Change content for packages from .jar to .zip CADName value must be the same value as the content filename. Use the IBA_primary_legend_filename. In case of uniqueness exception, throw it and tell the customer to fix it and then rerun migration. Also changes Catia content from .jar to .zip It accesses the database directly in order to avoid all of the checks and restrictions involved with changing a CADName and renaming contents.

See Also:
Constant Field Values

ZIP

private static final String ZIP
See Also:
Constant Field Values
Constructor Detail

I3MigratorR7

public I3MigratorR7()
Method Detail

runMigration

public boolean runMigration(DirectiveServices directive_services)
                     throws SQLException,
                            WTException
Description copied from interface: JavaMigrator
Run the migration.

Migrators should log all output to the given PrintWriter. This is the log that is created by RunMigrators. It is an autoflush writer.

Migrators should return true if they successfully completed migration and false otherwise. It is the migrator's responsibility to log failure reasons to the log.

Migrators should not concern themselves with committing the work on the connection. The MigratorRunner will commit the connection work after running each Migrator.

Specified by:
runMigration in interface JavaMigrator
Parameters:
directive_services - provide access to database, logging, and versioning information
Throws:
SQLException
WTException

migrateCatiaPackages

private boolean migrateCatiaPackages(DirectiveServices ds)
                              throws SQLException,
                                     WTException
Throws:
SQLException
WTException

renameContent

private int renameContent(DirectiveServices ds,
                          String jarName,
                          long docId)
                   throws SQLException,
                          WTException
Throws:
SQLException
WTException

isJar

private boolean isJar(String fileName)

isContentAPackage

protected boolean isContentAPackage(String cdata)

stripName

protected String stripName(String modelName)

lastExtension

protected String lastExtension(String cdata)