using System; using System.Runtime.Serialization; namespace LibGit2Sharp { /// /// The exception that is thrown when a commit would create an "empty" /// commit that is treesame to its parent without an explicit override. /// [Serializable] public class EmptyCommitException : LibGit2SharpException { /// /// Initializes a new instance of the class. /// public EmptyCommitException() { } /// /// Initializes a new instance of the class with a specified error message. /// /// A message that describes the error. public EmptyCommitException(string message) : base(message) { } /// /// Initializes a new instance of the class with a specified error message and a reference to the inner exception that is the cause of this exception. /// /// The error message that explains the reason for the exception. /// The exception that is the cause of the current exception. If the parameter is not a null reference, the current exception is raised in a catch block that handles the inner exception. public EmptyCommitException(string message, Exception innerException) : base(message, innerException) { } /// /// Initializes a new instance of the class with a serialized data. /// /// The that holds the serialized object data about the exception being thrown. /// The that contains contextual information about the source or destination. protected EmptyCommitException(SerializationInfo info, StreamingContext context) : base(info, context) { } } }