Class ExceptionCollection
An exception that represents a collection of exceptions. Useful for deferring the throwing of exceptions.
Inherited Members
Namespace: UnityEngine.Localization.SmartFormat.Tests.Common
Syntax
public class ExceptionCollection : ExceptionCollection<Exception>, ISerializable, _Exception, IList<Exception>, ICollection<Exception>, IEnumerable<Exception>, IEnumerable
Constructors
ExceptionCollection()
Declaration
public ExceptionCollection()
ExceptionCollection(IEnumerable<Exception>)
Declaration
public ExceptionCollection(IEnumerable<Exception> exceptions)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<Exception> | exceptions |
ExceptionCollection(Exception)
Declaration
public ExceptionCollection(Exception exception)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception |
Methods
AddNewException(Exception, String, Object[])
Adds a new Exception to the ExceptionCollection.
Declaration
public void AddNewException(Exception innerException, string message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
Exception | innerException | The exception that is the cause of the current exception. Can be null. |
String | message | The issue message that explains the reason for the exception. This message can optionally contain string.Format placeholders for the following arguments. |
Object[] | args | An optional list of objects to use for formatting the message. |
AddNewException(String, Object[])
Adds a new Exception to the ExceptionCollection.
Declaration
public void AddNewException(string message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
String | message | The issue message that explains the reason for the exception. This message can optionally contain string.Format placeholders for the following arguments. |
Object[] | args | An optional list of objects to use for formatting the message. |
Combine(ExceptionCollection[])
Declaration
public static ExceptionCollection Combine(params ExceptionCollection[] combineAllExceptions)
Parameters
Type | Name | Description |
---|---|---|
ExceptionCollection[] | combineAllExceptions |
Returns
Type | Description |
---|---|
ExceptionCollection |