RelativityNotSupportedException
The exception thrown when attempting to import or export with an unsupported Relativity instance.
using System;
using System.Runtime.Serialization;
namespace Relativity.DataExchange
{
[Serializable]
public class RelativityNotSupportedException : Exception
{
public Version RelativityVersion { get; set; }
public RelativityNotSupportedException()
{
}
public RelativityNotSupportedException(string message)
: base(message)
{
}
public RelativityNotSupportedException(string message, Version relativityVersion)
: base(message)
{
RelativityVersion = relativityVersion;
}
public RelativityNotSupportedException(string message, Exception innerException)
: base(message, innerException)
{
}
protected RelativityNotSupportedException(SerializationInfo info, StreamingContext context)
: base(info, context)
{
info.AddValue("RelativityVersion", RelativityVersion);
}
public override void GetObjectData(SerializationInfo info, StreamingContext context)
{
if (info == null)
throw new ArgumentNullException("info");
RelativityVersion = (info.GetValue("RelativityVersion", typeof(Version)) as Version);
base.GetObjectData(info, context);
}
}
}