@@ 310-316 (lines=7) @@ | ||
307 | $intSyllableCount = $intWordPartCount + $intAffixCount + (2 * $intDoubleAffixCount) + (3 * $intTripleAffixCount); |
|
308 | $debug['Syllables by Vowel Count'] = $intSyllableCount; |
|
309 | ||
310 | foreach (self::$arrSubSyllables as $strSyllable) { |
|
311 | $_intSyllableCount = $intSyllableCount; |
|
312 | $intSyllableCount -= preg_match('`' . $strSyllable . '`', $strWord); |
|
313 | if ($_intSyllableCount != $intSyllableCount) { |
|
314 | $debug['Subtracting (' . $strSyllable . ')'] = $strSyllable; |
|
315 | } |
|
316 | } |
|
317 | foreach (self::$arrAddSyllables as $strSyllable) { |
|
318 | $_intSyllableCount = $intSyllableCount; |
|
319 | $intSyllableCount += preg_match('`' . $strSyllable . '`', $strWord); |
|
@@ 317-323 (lines=7) @@ | ||
314 | $debug['Subtracting (' . $strSyllable . ')'] = $strSyllable; |
|
315 | } |
|
316 | } |
|
317 | foreach (self::$arrAddSyllables as $strSyllable) { |
|
318 | $_intSyllableCount = $intSyllableCount; |
|
319 | $intSyllableCount += preg_match('`' . $strSyllable . '`', $strWord); |
|
320 | if ($_intSyllableCount != $intSyllableCount) { |
|
321 | $debug['Adding (' . $strSyllable . ')'] = $strSyllable; |
|
322 | } |
|
323 | } |
|
324 | $intSyllableCount = ($intSyllableCount == 0) ? 1 : $intSyllableCount; |
|
325 | ||
326 | $debug['Result'] = $intSyllableCount; |