YUI.add("text-wordbreak",function(r,e){var n=r.Text,t=n.Data.WordBreak,s=[new RegExp(t.aletter),new RegExp(t.midnumlet),new RegExp(t.midletter),new RegExp(t.midnum),new RegExp(t.numeric),new RegExp(t.cr),new RegExp(t.lf),new RegExp(t.newline),new RegExp(t.extend),new RegExp(t.format),new RegExp(t.katakana),new RegExp(t.extendnumlet)],g=new RegExp("^"+t.punctuation+"$"),x=/\s/,c={getWords:function(e,n){var r,t,a,u=0,o=c._classify(e),i=o.length,d=[],s=[];for((n=n||{}).ignoreCase&&(e=e.toLowerCase()),t=n.includePunctuation,a=n.includeWhitespace;u<i;++u)r=e.charAt(u),d.push(r),c._isWordBoundary(o,u)&&(!(d=d.join(""))||!a&&x.test(d)||!t&&g.test(d)||s.push(d),d=[]);return s},getUniqueWords:function(e,n){return r.Array.unique(c.getWords(e,n))},isWordBoundary:function(e,n){return c._isWordBoundary(c._classify(e),n)},_classify:function(e){for(var n,r,t,a,u=[],o=0,i=e.length,d=s.length;o<i;++o){for(n=e.charAt(o),a=12,r=0;r<d;++r)if((t=s[r])&&t.test(n)){a=r;break}u.push(a)}return u},_isWordBoundary:function(e,n){var r,t=e[n],a=e[n+1];return!(n<0||n>e.length-1&&0!==n)&&(0!==t||0!==a)&&(r=e[n+2],0!==t||2!==a&&1!==a||0!==r)&&(n=e[n-1],2!==t&&1!==t||0!==a||0!==n)&&(4!==t&&0!==t||4!==a&&0!==a)&&(3!==t&&1!==t||4!==a||4!==n)&&(4!==t||3!==a&&1!==a||4!==r)&&8!==t&&9!==t&&8!==n&&9!==n&&8!==a&&9!==a&&!(5===t&&6===a||7!==t&&5!==t&&6!==t&&7!==a&&5!==a&&6!==a&&(10===t&&10===a||11===a&&(0===t||4===t||10===t||11===t)||11===t&&(0===a||4===a||10===a)))}};n.WordBreak=c},"patched-v3.18.7",{requires:["array-extras","text-data-wordbreak"]});