| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.esri.arcgis.geoprocessing.GPEnvironmentManager
public class GPEnvironmentManager
Environment Manager.
The GPEnvironmentManager is a collection of environments used by geoprocessing tools. It is the managing object for all geoprocessing environments and their settings. The GPEnvironmentManager object is passed to each tool during Validate() and Execute() to provide access to all current environments and settings.
| Constructor Summary | |
|---|---|
| GPEnvironmentManager()Constructs a GPEnvironmentManager using ArcGIS Engine. | |
| GPEnvironmentManager(Object obj)Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.  GPEnvironmentManager theGPEnvironmentManager = (GPEnvironmentManager) obj; | |
| Method Summary | |
|---|---|
|  void | add(IGPVariable pVariable)Adds a variable. | 
|  void | addEnvironment(IGPEnvironment env)Adds the given geoprocessing environment to the environment manager. | 
|  void | addOutputName(String name)Adds the given name to the list. | 
|  void | assign(IClone src)Assigns the properties of src to the receiver. | 
|  boolean | checkOutputName(String name)Returns whether or not the given name exists within the list. | 
|  void | deserialize(IXMLSerializeData data)Deserializes an object from XML. | 
|  boolean | equals(Object o)Compare this object with another | 
|  IClone | esri_clone()Clones the receiver and assigns the result to *clone. | 
|  IGPVariable | find(String name)Finds a variable. | 
|  IGPEnvironment | findEnvironment(String name)Locates and returns the environment with the specified name. | 
|  void | getClassID(GUID[] pClassID)getClassID | 
| static String | getClsid()getClsid. | 
|  IArray | getEnvironments()Returns the environments of the environment manager as an array. | 
|  Object | getEnvVariant(IGPEnvironment env)Returns the value of the given environment as a variant. | 
|  IArray | getLocalEnvironments()Returns an array of the environments that have been updated locally. | 
|  IGPEnvironmentManager | getParent()Returns the parent environment manager. | 
|  void | getSizeMax(_ULARGE_INTEGER[] pcbSize)getSizeMax | 
|  IArray | getVariables()Returns an array of all of the variables. | 
|  int | hashCode()the hashcode for this object | 
|  boolean | isAddOutputsToMap()Indicates whether resulting output datasets should be added to the application display. | 
|  void | isDirty()isDirty | 
|  boolean | isEqual(IClone other)Indicates if the receiver and other have the same properties. | 
|  boolean | isIdentical(IClone other)Indicates if the receiver and other are the same object. | 
|  boolean | isLogHistory()Indicates whether or not to log the execution of geoprocessing tools. | 
|  boolean | isOverwriteOutput()Indicates whether output datasets should be overwritten when executing geoprocessing tools. | 
|  boolean | isShowModelBuilderPrompts()Indicates whether to prompt the user when connecting elements in ModelBuilder if there is more than one possible connection. | 
|  boolean | isTemporaryMapLayers()Indicates whether new map layers are temporary by default. | 
|  void | load(IStream pstm)load | 
|  void | putEnvVariant(IGPEnvironment env,
              Object value)Sets the value of the given environment to the given variant. | 
|  void | readExternal(ObjectInput in) | 
|  void | remove(String name)Removes a variable. | 
|  void | removeAll()Removes all variables. | 
|  void | removeAllOutputNames()Removes all names from the list. | 
|  void | removeEnvironment(IGPEnvironment env)Removes the given geoprocessing environment from the environment manager. | 
|  void | removeEnvironments()Removes all environments from the environment manager. | 
|  void | removeOutputName(String name)Removes the specified name from the list. | 
|  void | save(IStream pstm,
     int fClearDirty)save | 
|  void | serialize(IXMLSerializeData data)Serializes an object to XML. | 
|  void | setAddOutputsToMap(boolean addToMap)Indicates whether resulting output datasets should be added to the application display. | 
|  void | setLogHistory(boolean logHistory)Indicates whether or not to log the execution of geoprocessing tools. | 
|  void | setOverwriteOutput(boolean overwriteOutput)Indicates whether output datasets should be overwritten when executing geoprocessing tools. | 
|  void | setParentByRef(IGPEnvironmentManager parent)Returns the parent environment manager. | 
|  void | setPersistAll(boolean rhs1)Indicates whether all environments or only local environments are persisted. | 
|  void | setShowModelBuilderPrompts(boolean showPrompts)Indicates whether to prompt the user when connecting elements in ModelBuilder if there is more than one possible connection. | 
|  void | setTemporaryMapLayers(boolean temporaryMapLayers)Indicates whether new map layers are temporary by default. | 
|  void | substituteEnvironments(IArray pParams)Substitues the values of the given array of parameters with the current environment values. | 
|  void | writeExternal(ObjectOutput out) | 
| 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 | 
|---|
public GPEnvironmentManager()
                     throws IOException,
                            UnknownHostException
IOException - if there are interop problems
UnknownHostException - if there are interop problems
public GPEnvironmentManager(Object obj)
                     throws IOException
 GPEnvironmentManager theGPEnvironmentManager = (GPEnvironmentManager) obj;
obj to GPEnvironmentManager.
obj - an object returned from ArcGIS Engine or Server
IOException - if there are interop problems| Method Detail | 
|---|
public static String getClsid()
public boolean equals(Object o)
equals in class Objectpublic int hashCode()
hashCode in class Object
public IGPEnvironmentManager getParent()
                                throws IOException,
                                       AutomationException
The Parent property returns a reference to the root environment manager, i.e., ArcToolbox.
getParent in interface IGPEnvironmentManagerIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setParentByRef(IGPEnvironmentManager parent)
                    throws IOException,
                           AutomationException
setParentByRef in interface IGPEnvironmentManagerparent - A reference to a com.esri.arcgis.geoprocessing.IGPEnvironmentManager  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void addEnvironment(IGPEnvironment env)
                    throws IOException,
                           AutomationException
The AddEnvironment methods adds a given environment to the environments array.
addEnvironment in interface IGPEnvironmentManagerenv - A reference to a com.esri.arcgis.geoprocessing.IGPEnvironment  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void removeEnvironment(IGPEnvironment env)
                       throws IOException,
                              AutomationException
removeEnvironment in interface IGPEnvironmentManagerenv - A reference to a com.esri.arcgis.geoprocessing.IGPEnvironment  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void substituteEnvironments(IArray pParams)
                            throws IOException,
                                   AutomationException
substituteEnvironments in interface IGPEnvironmentManagerpParams - A reference to a com.esri.arcgis.system.IArray  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void removeEnvironments()
                        throws IOException,
                               AutomationException
removeEnvironments in interface IGPEnvironmentManagerIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IArray getEnvironments()
                       throws IOException,
                              AutomationException
The GetEnvironments method returns all possible environments of an environment manager as an array. Use this method to access a complete environments list of a GPEnviornmentManager object.
getEnvironments in interface IGPEnvironmentManagerIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IArray getLocalEnvironments()
                            throws IOException,
                                   AutomationException
The GetLocalEnvironments method returns the environments [as an IArray object] defined for an object such as a model process or a model.
getLocalEnvironments in interface IGPEnvironmentManagerIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IGPEnvironment findEnvironment(String name)
                               throws IOException,
                                      AutomationException
The FindEnvironment method returns the specified environment as string. Use this method to access a specific environment.
A code snippet on how to use this method is included below.
findEnvironment in interface IGPEnvironmentManagername - The name  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void putEnvVariant(IGPEnvironment env,
                          Object value)
                   throws IOException,
                          AutomationException
putEnvVariant in interface IGPEnvironmentManagerenv - A reference to a com.esri.arcgis.geoprocessing.IGPEnvironment  (in)value - A Variant  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public Object getEnvVariant(IGPEnvironment env)
                     throws IOException,
                            AutomationException
getEnvVariant in interface IGPEnvironmentManagerenv - A reference to a com.esri.arcgis.geoprocessing.IGPEnvironment  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setPersistAll(boolean rhs1)
                   throws IOException,
                          AutomationException
setPersistAll in interface IGPEnvironmentManagerrhs1 - The rhs1  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void removeAllOutputNames()
                          throws IOException,
                                 AutomationException
removeAllOutputNames in interface IGPDefaultNameListIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void addOutputName(String name)
                   throws IOException,
                          AutomationException
addOutputName in interface IGPDefaultNameListname - The name  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void removeOutputName(String name)
                      throws IOException,
                             AutomationException
removeOutputName in interface IGPDefaultNameListname - The name  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean checkOutputName(String name)
                        throws IOException,
                               AutomationException
checkOutputName in interface IGPDefaultNameListname - The name  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setAddOutputsToMap(boolean addToMap)
                        throws IOException,
                               AutomationException
setAddOutputsToMap in interface IGeoProcessorSettingsaddToMap - The addToMap  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isAddOutputsToMap()
                          throws IOException,
                                 AutomationException
isAddOutputsToMap in interface IGeoProcessorSettingsIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setOverwriteOutput(boolean overwriteOutput)
                        throws IOException,
                               AutomationException
When creating a custom tool that writes output data, it is necessary to check the GeoProcessor setting OberwriteOutput. A code sample is included below on how to do this.
setOverwriteOutput in interface IGeoProcessorSettingsoverwriteOutput - The overwriteOutput  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isOverwriteOutput()
                          throws IOException,
                                 AutomationException
The OutputOverwrite property determines if output created by a function execution will be overwritten by subsequent function executions. A code sample to check the OutputOverwrite setting is included below.
isOverwriteOutput in interface IGeoProcessorSettingsIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setTemporaryMapLayers(boolean temporaryMapLayers)
                           throws IOException,
                                  AutomationException
setTemporaryMapLayers in interface IGeoProcessorSettingstemporaryMapLayers - The temporaryMapLayers  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isTemporaryMapLayers()
                             throws IOException,
                                    AutomationException
The TemporaryMapLayer property indicates if a new map layer is by default temporary data or not.
isTemporaryMapLayers in interface IGeoProcessorSettingsIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setShowModelBuilderPrompts(boolean showPrompts)
                                throws IOException,
                                       AutomationException
setShowModelBuilderPrompts in interface IGeoProcessorSettingsshowPrompts - The showPrompts  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isShowModelBuilderPrompts()
                                  throws IOException,
                                         AutomationException
isShowModelBuilderPrompts in interface IGeoProcessorSettingsIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setLogHistory(boolean logHistory)
                   throws IOException,
                          AutomationException
setLogHistory in interface IGeoProcessorSettingslogHistory - The logHistory  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isLogHistory()
                     throws IOException,
                            AutomationException
Having a log of function executions can be useful. The LogHistory porperty checks if the setting is on or off.
isLogHistory in interface IGeoProcessorSettingsIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IClone esri_clone()
                  throws IOException,
                         AutomationException
esri_clone in interface ICloneIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void assign(IClone src)
            throws IOException,
                   AutomationException
assign in interface IClonesrc - A reference to a com.esri.arcgis.system.IClone  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isEqual(IClone other)
                throws IOException,
                       AutomationException
IsEqual returns True if the receiver and the source have the same properties. Note, this does not imply that the receiver and the source reference the same object.
isEqual in interface ICloneother - A reference to a com.esri.arcgis.system.IClone  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isIdentical(IClone other)
                    throws IOException,
                           AutomationException
IsIdentical returns true if the receiver and the source reference the same object.
isIdentical in interface ICloneother - A reference to a com.esri.arcgis.system.IClone  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void getClassID(GUID[] pClassID)
                throws IOException,
                       AutomationException
IPersist is a Microsoft interface. Please refer to MSDN for information about this interface.
getClassID in interface IPersistpClassID - A Structure: com.esri.arcgis.support.ms.stdole.GUID  (out: use single element array)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void isDirty()
             throws IOException,
                    AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
isDirty in interface IPersistStreamIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void load(IStream pstm)
          throws IOException,
                 AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
load in interface IPersistStreampstm - A reference to a com.esri.arcgis.system.IStream  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void save(IStream pstm,
                 int fClearDirty)
          throws IOException,
                 AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
save in interface IPersistStreampstm - A reference to a com.esri.arcgis.system.IStream  (in)fClearDirty - The fClearDirty  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void getSizeMax(_ULARGE_INTEGER[] pcbSize)
                throws IOException,
                       AutomationException
IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.
getSizeMax in interface IPersistStreampcbSize - A Structure: com.esri.arcgis.system._ULARGE_INTEGER  (out: use single element array)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void serialize(IXMLSerializeData data)
               throws IOException,
                      AutomationException
serialize in interface IXMLSerializedata - A reference to a com.esri.arcgis.system.IXMLSerializeData  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void deserialize(IXMLSerializeData data)
                 throws IOException,
                        AutomationException
deserialize in interface IXMLSerializedata - A reference to a com.esri.arcgis.system.IXMLSerializeData  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void add(IGPVariable pVariable)
         throws IOException,
                AutomationException
add in interface IGPVariableManagerpVariable - A reference to a com.esri.arcgis.geodatabase.IGPVariable  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void remove(String name)
            throws IOException,
                   AutomationException
remove in interface IGPVariableManagername - The name  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void removeAll()
               throws IOException,
                      AutomationException
removeAll in interface IGPVariableManagerIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IGPVariable find(String name)
                 throws IOException,
                        AutomationException
find in interface IGPVariableManagername - The name  (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IArray getVariables()
                    throws IOException,
                           AutomationException
getVariables in interface IGPVariableManagerIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void writeExternal(ObjectOutput out)
                   throws IOException
writeExternal in interface ExternalizableIOException
public void readExternal(ObjectInput in)
                  throws IOException,
                         ClassNotFoundException
readExternal in interface ExternalizableIOException
ClassNotFoundException| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||