Long get or set information is saved here.
Ejemplo n.º 1
0
 /// <summary>
 /// Reset settings when connection is made or close.
 /// </summary>
 /// <param name="connected"></param>
 public void Reset(bool connected)
 {
     transaction         = null;
     Settings.BlockIndex = 1;
     Settings.Count      = Settings.Index = 0;
     Settings.Connected  = false;
     replyData.Clear();
     receivedData.Clear();
     Settings.Password = null;
     if (!connected)
     {
         info.Clear();
         Settings.ServerAddress = 0;
         Settings.ClientAddress = 0;
     }
     Settings.Authentication           = Authentication.None;
     Settings.IsAuthenticationRequired = false;
     if (Settings.Cipher != null)
     {
         if (!connected)
         {
             Settings.Cipher.Reset();
         }
         else
         {
             Settings.Cipher.Security = Gurux.DLMS.Enums.Security.None;
         }
     }
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Reset settings when connection is made or close.
 /// </summary>
 /// <param name="all"></param>
 public void Reset(bool connected)
 {
     transaction = null;
     Settings.BlockIndex = 1;
     Settings.Count = Settings.Index = 0;
     Settings.Connected = false;
     replyData.Clear();
     receivedData.Clear();
     Settings.Password = null;
     if (!connected)
     {
         info.Clear();
         Settings.ServerAddress = 0;
         Settings.ClientAddress = 0;
     }
     Settings.Authentication = Authentication.None;
     Settings.IsAuthenticationRequired = false;
     if (Settings.Cipher != null)
     {
         if (!connected)
         {
             Settings.Cipher.Reset();
         }
         else
         {
             Settings.Cipher.Security = Gurux.DLMS.Enums.Security.None;
         }
     }
 }