|
|
|
@ -18,14 +18,21 @@ module Pancake =
|
|
|
|
|
/// </summary> |
|
|
|
|
/// <param name="noOfSentences"> |
|
|
|
|
/// The number of sentences the cleaned string should have. |
|
|
|
|
/// This should be smaller than the number of sentences the original text has. |
|
|
|
|
/// </param> |
|
|
|
|
/// <param name="text"> |
|
|
|
|
/// The string to clean. |
|
|
|
|
/// </param> |
|
|
|
|
/// <returns> |
|
|
|
|
/// A string of text which has been trimmed to the specified sentence count. |
|
|
|
|
/// </returns> |
|
|
|
|
/// <exception cref="System.InvalidOperationException"> |
|
|
|
|
/// Thrown when the number of sentences requested is bigger than the number in the text passed in. |
|
|
|
|
/// </exception> |
|
|
|
|
/// <remarks> |
|
|
|
|
/// This function's aim is to trim or remove excess sentences. |
|
|
|
|
/// If the string has less sentences than the number requested, it will not change. |
|
|
|
|
/// </remarks> |
|
|
|
|
/// </remarks> |
|
|
|
|
let CleanResultAsync noOfSentences text = |
|
|
|
|
async { |
|
|
|
|
try |
|
|
|
|