private void SetDefaultAttributeSchemaInfo(XmlSchemaAttribute schemaAttribute)
{
Debug.Assert(_attributeSchemaInfo != null);
_attributeSchemaInfo.Clear();
_attributeSchemaInfo.IsDefault = true;
_attributeSchemaInfo.IsNil = false;
_attributeSchemaInfo.SchemaType = schemaAttribute.AttributeSchemaType;
_attributeSchemaInfo.SchemaAttribute = schemaAttribute;
//Get memberType for default attribute
SchemaAttDef attributeDef = schemaAttribute.AttDef;
if (attributeDef.Datatype.Variety == XmlSchemaDatatypeVariety.Union)
{
XsdSimpleValue simpleValue = attributeDef.DefaultValueTyped as XsdSimpleValue;
Debug.Assert(simpleValue != null);
_attributeSchemaInfo.MemberType = simpleValue.XmlType;
}
_attributeSchemaInfo.Validity = XmlSchemaValidity.Valid;
}