public object ParseRelativeSource (ref string expression)
{
char next;
string mode_str = GetNextPiece (ref expression, out next);
try {
return new RelativeSource ((RelativeSourceMode) Enum.Parse (typeof (RelativeSourceMode), mode_str, true));
} catch {
throw new XamlParseException (String.Format ("MarkupExpressionParser: Error parsing RelativeSource, unknown mode: {0}", mode_str));
}
}