System.Xml.Serialization.Globals.IsDBNullValue C# (CSharp) Method

IsDBNullValue() static private method

static private IsDBNullValue ( object o ) : bool
o object
return bool
        internal static bool IsDBNullValue(object o)
        {
            return o != null && ValueOfDBNull != null && ValueOfDBNull.Equals(o);
        }
        internal static Exception NotSupported(string msg)

Usage Example

Example #1
0
        private void WriteQualifiedNameElement(string name, string ns, object defaultValue, XmlQualifiedName o, bool nullable, bool isSoap, PrimitiveMapping mapping)
        {
            bool hasDefault = defaultValue != null && !Globals.IsDBNullValue(defaultValue) && mapping.TypeDesc.HasDefaultSupport;

            if (hasDefault && IsDefaultValue(mapping, o, defaultValue, nullable))
            {
                return;
            }

            if (isSoap)
            {
                throw new PlatformNotSupportedException();
            }

            if (nullable)
            {
                WriteNullableQualifiedNameLiteral(name, ns, o);
            }
            else
            {
                WriteElementQualifiedName(name, ns, o);
            }
        }
All Usage Examples Of System.Xml.Serialization.Globals::IsDBNullValue