com.esri.arcgis.geodatabasedistributed
Class GdbImporter

java.lang.Object
  extended by com.esri.arcgis.geodatabasedistributed.GdbImporter
All Implemented Interfaces:
IGdbXmlImport, com.esri.arcgis.interop.RemoteObjRef, ISupportErrorInfo, Serializable

public class GdbImporter
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IGdbXmlImport, ISupportErrorInfo

Esri Geodatabase Importer object.

Remarks

Use the GdbImporter coclass when you wish to import schema and data or schema from a resulting XML document to an PGDB or ArcSDE geodatabase. See the IGdbXMLImport methods for more on getting information about importing resulting XML document to geodatabase.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

See Also:
GdbExporter, Serialized Form

Constructor Summary
GdbImporter()
          Constructs a GdbImporter using ArcGIS Engine.
GdbImporter(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
GdbImporter theGdbImporter = (GdbImporter) obj;
 
Method Summary
 void addIFeatureProgressListener(IFeatureProgress theListener)
          addIFeatureProgressListener.
 void addIOperationProgressListener(IOperationProgress theListener)
          addIOperationProgressListener.
 boolean equals(Object o)
          Compare this object with another
 boolean generateNameMapping(String inFile, IWorkspace workspace, IEnumNameMapping[] enumNameMapping)
          Generate a list of objects to import.
static String getClsid()
          getClsid.
 IFields getRecordSetFields(String inFile)
          Generate a fieldset to load from xml.
 int hashCode()
          the hashcode for this object
 void importRecordSet(String inFile, IFields sourceFields, IFields targetMappedFields, ITable pTable)
          Loading data from xml recordset.
 void importWorkspace(String inFile, IEnumNameMapping enumNameMapping, IWorkspace pWorkspace, boolean schemaOnly)
          Imports a workspace from XML.
 void interfaceSupportsErrorInfo(GUID riid)
          interfaceSupportsErrorInfo
 void removeIFeatureProgressListener(IFeatureProgress theListener)
          removeIFeatureProgressListener.
 void removeIOperationProgressListener(IOperationProgress theListener)
          removeIOperationProgressListener.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef
getJintegraDispatch, release
 

Constructor Detail

GdbImporter

public GdbImporter()
            throws IOException,
                   UnknownHostException
Constructs a GdbImporter using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

GdbImporter

public GdbImporter(Object obj)
            throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
GdbImporter theGdbImporter = (GdbImporter) obj;

Construct a GdbImporter using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to GdbImporter.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

addIFeatureProgressListener

public void addIFeatureProgressListener(IFeatureProgress theListener)
                                 throws IOException
addIFeatureProgressListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabase.IFeatureProgress interface.
Throws:
IOException - If there are communications problems.

removeIFeatureProgressListener

public void removeIFeatureProgressListener(IFeatureProgress theListener)
                                    throws IOException
removeIFeatureProgressListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabase.IFeatureProgress interface.
Throws:
IOException - If there are communications problems.

addIOperationProgressListener

public void addIOperationProgressListener(IOperationProgress theListener)
                                   throws IOException
addIOperationProgressListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabasedistributed.IOperationProgress interface.
Throws:
IOException - If there are communications problems.

removeIOperationProgressListener

public void removeIOperationProgressListener(IOperationProgress theListener)
                                      throws IOException
removeIOperationProgressListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.geodatabasedistributed.IOperationProgress interface.
Throws:
IOException - If there are communications problems.

generateNameMapping

public boolean generateNameMapping(String inFile,
                                   IWorkspace workspace,
                                   IEnumNameMapping[] enumNameMapping)
                            throws IOException,
                                   AutomationException
Generate a list of objects to import.

Remarks

The GenerateNameMapping method generates a name mapping enumeration where you pass in inFile, IWorkspace, and IEnumNameMapping.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
generateNameMapping in interface IGdbXmlImport
Parameters:
inFile - The inFile (in)
workspace - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)
enumNameMapping - A reference to a com.esri.arcgis.geodatabase.IEnumNameMapping (out: use single element array)
Returns:
The hasConflict
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

importWorkspace

public void importWorkspace(String inFile,
                            IEnumNameMapping enumNameMapping,
                            IWorkspace pWorkspace,
                            boolean schemaOnly)
                     throws IOException,
                            AutomationException
Imports a workspace from XML.

Remarks

The ImportWorkspace method imports a geodatabase workspace schema and data.

In order to import a workspace, you need to pass in IEnumNameMapping and IWorkspace. The inFile is a string that identifies the input XML filename. The filename must have a "xml" file extension, for example, "c:\temp\file.xml". Otherwise, the inFile is a .ZIP or .Z file extension.

If you set schemaOnly to TRUE, the imported workspace will contain the schema and no data. Otherwise, the workspace being imported will contain schema and data.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
importWorkspace in interface IGdbXmlImport
Parameters:
inFile - The inFile (in)
enumNameMapping - A reference to a com.esri.arcgis.geodatabase.IEnumNameMapping (in)
pWorkspace - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)
schemaOnly - The schemaOnly (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

importRecordSet

public void importRecordSet(String inFile,
                            IFields sourceFields,
                            IFields targetMappedFields,
                            ITable pTable)
                     throws IOException,
                            AutomationException
Loading data from xml recordset.

Remarks

The ImportRecordSet method imports a geodatabase recordset.

In order to import a recordset, you need to pass in IFields and ITable. The inFile is a string that identifies the input XML filename. The filename must have a "xml" file extension, for example, "c:\temp\file.xml". Otherwise, the inFile is a .ZIP or .Z file extension.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
importRecordSet in interface IGdbXmlImport
Parameters:
inFile - The inFile (in)
sourceFields - A reference to a com.esri.arcgis.geodatabase.IFields (in)
targetMappedFields - A reference to a com.esri.arcgis.geodatabase.IFields (in)
pTable - A reference to a com.esri.arcgis.geodatabase.ITable (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getRecordSetFields

public IFields getRecordSetFields(String inFile)
                           throws IOException,
                                  AutomationException
Generate a fieldset to load from xml.

Remarks

The GetRecordSetFields method retrieves recordset fields and records from resulting XML file. You need to pass in inFile as a string that identifies the input XML file.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
getRecordSetFields in interface IGdbXmlImport
Parameters:
inFile - The inFile (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IFields
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

interfaceSupportsErrorInfo

public void interfaceSupportsErrorInfo(GUID riid)
                                throws IOException,
                                       AutomationException
interfaceSupportsErrorInfo

Description

Indicates whether the interface supports IErrorInfo.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Specified by:
interfaceSupportsErrorInfo in interface ISupportErrorInfo
Parameters:
riid - A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.