Skip to content

Commit 376c0ff

Browse files
Review XML comments for exceptions DynamicsValue/fake-xrm-easy#157
1 parent 5c6158b commit 376c0ff

9 files changed

+31
-9
lines changed

src/FakeXrmEasy.Core/Exceptions/Query/FetchXml/ArithmeticTypeConversionException.cs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,17 @@
22

33
namespace FakeXrmEasy.Core.Exceptions.Query.FetchXml
44
{
5+
/// <summary>
6+
/// Exception raised in a query when an attribute value type could not be determined correctly
7+
/// </summary>
58
public class ArithmeticTypeConversionException: Exception
69
{
7-
public ArithmeticTypeConversionException(string entityName, string attributeName) :
10+
/// <summary>
11+
/// Default constructor
12+
/// </summary>
13+
/// <param name="entityName"></param>
14+
/// <param name="attributeName"></param>
15+
internal ArithmeticTypeConversionException(string entityName, string attributeName) :
816
base($"When using arithmetic values in a condition of attribute '{attributeName}' of entity '{entityName}' in a Fetch a ProxyTypesAssembly must be used in order to know which types to cast values to. If you are using early bound types, please make sure the early bound type was generated for entity '{entityName}'")
917
{
1018

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/CouldNotAddFileException.cs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,15 @@
22

33
namespace FakeXrmEasy.Core.FileStorage.Db.Exceptions
44
{
5+
/// <summary>
6+
/// Internal exception used for internal testing only thrown when a file could not be added to the InMemoryFileDb
7+
/// </summary>
58
public class CouldNotAddFileException: Exception
69
{
7-
public CouldNotAddFileException(): base("A file could not be added")
10+
/// <summary>
11+
/// Default constructor
12+
/// </summary>
13+
internal CouldNotAddFileException(): base("A file could not be added")
814
{
915

1016
}

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/CouldNotCommitFileException.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,11 @@ namespace FakeXrmEasy.Core.FileStorage.Db.Exceptions
77
/// </summary>
88
public class CouldNotCommitFileException: Exception
99
{
10-
public CouldNotCommitFileException(string fileUploadContinuationToken) : base($"The file associated to continuation token '{fileUploadContinuationToken}' could not be committed due to an unknown error")
10+
/// <summary>
11+
/// Default constructor
12+
/// </summary>
13+
/// <param name="fileUploadContinuationToken"></param>
14+
internal CouldNotCommitFileException(string fileUploadContinuationToken) : base($"The file associated to continuation token '{fileUploadContinuationToken}' could not be committed due to an unknown error")
1115
{
1216

1317
}

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/DuplicateFileBlockException.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ public class DuplicateFileBlockException: Exception
1212
/// </summary>
1313
/// <param name="blockId">The block Id that already existed</param>
1414
/// <param name="fileUploadSessionId">The Id of the FileUploadSession where that block existed</param>
15-
public DuplicateFileBlockException(string blockId, string fileUploadSessionId) : base($"A block was already uploaded with Id {blockId} against the current file continuation token: {fileUploadSessionId}")
15+
internal DuplicateFileBlockException(string blockId, string fileUploadSessionId) : base($"A block was already uploaded with Id {blockId} against the current file continuation token: {fileUploadSessionId}")
1616
{
1717

1818
}

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/FileToDownloadNotFoundException.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ public class FileToDownloadNotFoundException: Exception
1313
/// </summary>
1414
/// <param name="entityReference">An entity reference of the record</param>
1515
/// <param name="fileAttributeName">The column where a file was not found</param>
16-
public FileToDownloadNotFoundException(EntityReference entityReference, string fileAttributeName)
16+
internal FileToDownloadNotFoundException(EntityReference entityReference, string fileAttributeName)
1717
: base($"A file was not found for record with logical name '{entityReference.LogicalName}' and Id '{entityReference.Id.ToString()}' in column '{fileAttributeName}'")
1818
{
1919

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/FileTokenContinuationNotFoundException.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ namespace FakeXrmEasy.Core.FileStorage.Db.Exceptions
44
{
55
public class FileTokenContinuationNotFoundException: Exception
66
{
7-
public FileTokenContinuationNotFoundException(string fileContinuationTokenId)
7+
internal FileTokenContinuationNotFoundException(string fileContinuationTokenId)
88
: base($"The file continuation token with Id '{fileContinuationTokenId}' could not be found or has already been committed")
99
{
1010

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/InvalidBlockLengthException.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ public class InvalidBlockLengthException: Exception
1010
/// <summary>
1111
/// Default constructor
1212
/// </summary>
13-
public InvalidBlockLengthException() : base($"The BlockLength property must be greater than zero.")
13+
internal InvalidBlockLengthException() : base($"The BlockLength property must be greater than zero.")
1414
{
1515

1616
}

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/MaxSizeExceededException.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ public class MaxSizeExceededException: Exception
1212
/// </summary>
1313
/// <param name="logicalName">The table with the column that has the max file size limitation</param>
1414
/// <param name="attributeName">The column with the max file size limitation</param>
15-
public MaxSizeExceededException(string logicalName, string attributeName, int currentMaxSize) :
15+
internal MaxSizeExceededException(string logicalName, string attributeName, int currentMaxSize) :
1616
base($"Could not commit the file upload because the sum of the block sizes exceeds the current allowed max file size of {currentMaxSize.ToString()}KB for column '{attributeName}' in table '{logicalName}'")
1717
{
1818

src/FakeXrmEasy.Core/FileStorage/Db/Exceptions/RecordNotFoundException.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,11 @@ namespace FakeXrmEasy.Core.FileStorage.Db.Exceptions
88
/// </summary>
99
public class RecordNotFoundException: Exception
1010
{
11-
public RecordNotFoundException(EntityReference reference) : base($"The entity reference record for logical name '{reference.LogicalName}' and '{reference.Id}' does not exist.")
11+
/// <summary>
12+
/// Default constructor
13+
/// </summary>
14+
/// <param name="reference"></param>
15+
internal RecordNotFoundException(EntityReference reference) : base($"The entity reference record for logical name '{reference.LogicalName}' and '{reference.Id}' does not exist.")
1216
{
1317

1418
}

0 commit comments

Comments
 (0)