Beispiel #1
0
    public static void logHashtable(Hashtable result)
    {
        StringBuilder stringBuilder = new StringBuilder();

        ResultLogger.addHashtableToString(stringBuilder, result);
        Debug.Log(stringBuilder.ToString());
    }
Beispiel #2
0
    public static void addArraylistToString(StringBuilder builder, ArrayList result)
    {
        IEnumerator enumerator = result.GetEnumerator();

        try
        {
            while (enumerator.MoveNext())
            {
                object obj = enumerator.Current;
                if (obj is Hashtable)
                {
                    ResultLogger.addHashtableToString(builder, (Hashtable)obj);
                }
                else if (obj is ArrayList)
                {
                    ResultLogger.addArraylistToString(builder, (ArrayList)obj);
                }
                builder.Append("\n--------------------\n");
            }
        }
        finally
        {
            IDisposable disposable;
            if ((disposable = (enumerator as IDisposable)) != null)
            {
                disposable.Dispose();
            }
        }
        Debug.Log(builder.ToString());
    }
Beispiel #3
0
    public static void addHashtableToString(StringBuilder builder, Hashtable item)
    {
        IDictionaryEnumerator enumerator = item.GetEnumerator();

        try
        {
            while (enumerator.MoveNext())
            {
                object          obj             = enumerator.Current;
                DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
                if (dictionaryEntry.Value is Hashtable)
                {
                    builder.AppendFormat("{0}: ", dictionaryEntry.Key);
                    ResultLogger.addHashtableToString(builder, (Hashtable)dictionaryEntry.Value);
                }
                else if (dictionaryEntry.Value is ArrayList)
                {
                    builder.AppendFormat("{0}: ", dictionaryEntry.Key);
                    ResultLogger.addArraylistToString(builder, (ArrayList)dictionaryEntry.Value);
                }
                else
                {
                    builder.AppendFormat("{0}: {1}\n", dictionaryEntry.Key, dictionaryEntry.Value);
                }
            }
        }
        finally
        {
            IDisposable disposable;
            if ((disposable = (enumerator as IDisposable)) != null)
            {
                disposable.Dispose();
            }
        }
    }
Beispiel #4
0
    public static void logArraylist(ArrayList result)
    {
        StringBuilder stringBuilder = new StringBuilder();
        IEnumerator   enumerator    = result.GetEnumerator();

        try
        {
            while (enumerator.MoveNext())
            {
                object    obj  = enumerator.Current;
                Hashtable item = (Hashtable)obj;
                ResultLogger.addHashtableToString(stringBuilder, item);
                stringBuilder.Append("\n--------------------\n");
            }
        }
        finally
        {
            IDisposable disposable;
            if ((disposable = (enumerator as IDisposable)) != null)
            {
                disposable.Dispose();
            }
        }
        Debug.Log(stringBuilder.ToString());
    }
Beispiel #5
0
    public static void logArraylist(ArrayList result)
    {
        StringBuilder stringBuilder = new StringBuilder();

        foreach (Hashtable item in result)
        {
            ResultLogger.addHashtableToString(stringBuilder, item);
            stringBuilder.Append("\n--------------------\n");
        }
        Debug.Log(stringBuilder.ToString());
    }
    public static void logArraylist(ArrayList result)
    {
        StringBuilder builder = new StringBuilder();

        // we start off with an ArrayList of Hashtables
        foreach (Hashtable item in result)
        {
            ResultLogger.addHashtableToString(builder, item);
            builder.Append("\n--------------------\n");
        }

        Debug.Log(builder.ToString());
    }
Beispiel #7
0
 // Token: 0x06001BA0 RID: 7072 RVA: 0x0008E124 File Offset: 0x0008C324
 public static void addArraylistToString(StringBuilder builder, ArrayList result)
 {
     foreach (object obj in result)
     {
         if (obj is Hashtable)
         {
             ResultLogger.addHashtableToString(builder, (Hashtable)obj);
         }
         else if (obj is ArrayList)
         {
             ResultLogger.addArraylistToString(builder, (ArrayList)obj);
         }
         builder.Append("\n--------------------\n");
     }
 }
Beispiel #8
0
 public static void addArraylistToString(StringBuilder builder, ArrayList result)
 {
     foreach (object current in result)
     {
         if (current is Hashtable)
         {
             ResultLogger.addHashtableToString(builder, (Hashtable)current);
         }
         else if (current is ArrayList)
         {
             ResultLogger.addArraylistToString(builder, (ArrayList)current);
         }
         builder.Append("\n--------------------\n");
     }
     Debug.Log(builder.ToString());
 }
    public static void addArraylistToString(StringBuilder builder, ArrayList result)
    {
        // we start off with an ArrayList of Hashtables
        foreach (object item in result)
        {
            if (item is Hashtable)
            {
                ResultLogger.addHashtableToString(builder, (Hashtable)item);
            }
            else if (item is ArrayList)
            {
                ResultLogger.addArraylistToString(builder, (ArrayList)item);
            }
            builder.Append("\n--------------------\n");
        }

        Debug.Log(builder.ToString());
    }
Beispiel #10
0
 public static void addHashtableToString(StringBuilder builder, Hashtable item)
 {
     foreach (DictionaryEntry dictionaryEntry in item)
     {
         if (dictionaryEntry.Value is Hashtable)
         {
             builder.AppendFormat("{0}: ", dictionaryEntry.Key);
             ResultLogger.addHashtableToString(builder, (Hashtable)dictionaryEntry.Value);
         }
         else if (dictionaryEntry.Value is ArrayList)
         {
             builder.AppendFormat("{0}: ", dictionaryEntry.Key);
             ResultLogger.addArraylistToString(builder, (ArrayList)dictionaryEntry.Value);
         }
         else
         {
             builder.AppendFormat("{0}: {1}\n", dictionaryEntry.Key, dictionaryEntry.Value);
         }
     }
 }