-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #40 from henrivain/master
Fix #38
- Loading branch information
Showing
13 changed files
with
166 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace TesseractOcrMaui.Exceptions; | ||
|
||
/// <summary> | ||
/// Exception thrown when multiple images are given to TessEngine at the same time. | ||
/// Old TessPage must be disposed before trying to process new image. | ||
/// </summary> | ||
public class PageNotDisposedException : TesseractException | ||
{ | ||
/// <summary> | ||
/// New exception thrown when multiple images are given to TessEngine at the same time. | ||
/// Old TessPage must be disposed before trying to process new image. | ||
/// </summary> | ||
public PageNotDisposedException() { } | ||
|
||
/// <summary> | ||
/// New exception with message thrown when multiple images are given to TessEngine at the same time. | ||
/// Old TessPage must be disposed before trying to process new image. | ||
/// </summary> | ||
/// <param name="message">Error reason</param> | ||
public PageNotDisposedException(string message) : base(message) { } | ||
|
||
/// <summary> | ||
/// New exception with message and inner exception thrown when multiple images are given to TessEngine at the same time. | ||
/// Old TessPage must be disposed before trying to process new image. | ||
/// </summary> | ||
/// <param name="message">Error reason</param> | ||
/// <param name="innerException">Exception that caused this exception</param> | ||
public PageNotDisposedException(string message, Exception innerException) | ||
: base(message, innerException) { } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
namespace TesseractOcrMaui.Exceptions; | ||
|
||
/// <summary> | ||
/// Exception thrown when library cannot marshal string returned from native library correctly. | ||
/// </summary> | ||
public class StringMarshallingException : TesseractException | ||
{ | ||
/// <summary> | ||
/// New Exception thrown when library cannot marshal string returned from native library correctly. | ||
/// </summary> | ||
public StringMarshallingException() : base() { } | ||
|
||
/// <summary> | ||
/// New Exception with message thrown when library cannot marshal string returned from native library correctly. | ||
/// </summary> | ||
/// <param name="message">Error reason.</param> | ||
public StringMarshallingException(string? message) : base(message) { } | ||
|
||
/// <summary> | ||
/// New Exception with message and inner exception. | ||
/// Thrown when library cannot marshal string returned from native library correctly. | ||
/// </summary> | ||
/// <param name="message">Error reason.</param> | ||
/// <param name="innerException">Exception that caused this error.</param> | ||
public StringMarshallingException(string? message, Exception? innerException) : base(message, innerException) | ||
{ | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.