Duality.Log.FieldInfo C# (CSharp) Method

FieldInfo() public static method

Returns a string that can be used for representing a field in log entries.
public static FieldInfo ( FieldInfo info, bool includeDeclaringType = true ) : string
info System.Reflection.FieldInfo
includeDeclaringType bool If true, the fields declaring type is included in the returned name.
return string
        public static string FieldInfo(FieldInfo info, bool includeDeclaringType = true)
        {
            string declTypeName = Type(info.DeclaringType);
            string fieldTypeName = Type(info.FieldType);
            return string.Format(System.Globalization.CultureInfo.InvariantCulture,
                "{0} {1}{2}",
                fieldTypeName,
                includeDeclaringType ? declTypeName + "." : "",
                info.Name);
        }