Environment Class ================= This class provides access to the environment variables and provides facilities to specify where to load the underlying AMPL interpreter. Namespace :dn:ns:`ampl` Assemblies * AMPL ---- .. contents:: :local: Inheritance Hierarchy --------------------- * :dn:cls:`System.Object` * :dn:cls:`ampl.Environment` Syntax ------ .. code-block:: csharp public class Environment : IEnumerable>, IEnumerable, IDisposable .. dn:class:: ampl.Environment :hidden: .. dn:class:: ampl.Environment Fields ------ .. dn:class:: ampl.Environment :noindex: :hidden: .. dn:field:: ampl.Environment.swigCMemOwn :rtype: System.Boolean .. code-block:: csharp protected bool swigCMemOwn Constructors ------------ .. dn:class:: ampl.Environment :noindex: :hidden: .. dn:constructor:: ampl.Environment.Environment() .. code-block:: csharp public Environment() .. dn:constructor:: ampl.Environment.Environment(System.String) :type binaryDirectory: System.String .. code-block:: csharp public Environment(string binaryDirectory) .. dn:constructor:: ampl.Environment.Environment(ampl.Environment) :type other: ampl.Environment .. code-block:: csharp public Environment(Environment other) Properties ---------- .. dn:class:: ampl.Environment :noindex: :hidden: .. dn:property:: ampl.Environment.BinDir :rtype: System.String .. code-block:: csharp public string BinDir { get; set; } .. dn:property:: ampl.Environment.Item[System.String] Access and sets values :param key: Environment variable to get or set :type key: System.String :rtype: System.String :return: Its value if present, null otherwise .. code-block:: csharp public string this[string key] { get; set; } Methods ------- .. dn:class:: ampl.Environment :noindex: :hidden: .. dn:method:: ampl.Environment.Clone(ampl.Environment) :type other: ampl.Environment :rtype: ampl.Environment .. code-block:: csharp public Environment Clone(Environment other) .. dn:method:: ampl.Environment.Dispose() .. code-block:: csharp public virtual void Dispose() .. dn:method:: ampl.Environment.Finalize() .. code-block:: csharp protected void Finalize() .. dn:method:: ampl.Environment.GetEnumerator() Get the enumerator for the map of environment variables :rtype: System.Collections.Generic.IEnumerator{System.Collections.Generic.KeyValuePair{System.String, System.String}} .. code-block:: csharp public IEnumerator> GetEnumerator() .. dn:method:: ampl.Environment.System.Collections.IEnumerable.GetEnumerator() Get the enumerator for the map of environment variables :rtype: System.Collections.IEnumerator .. code-block:: csharp IEnumerator IEnumerable.GetEnumerator() .. dn:method:: ampl.Environment.ToString() :rtype: System.String .. code-block:: csharp public override string ToString()