/// <summary> /// Determines if substring of <paramref name="s"/> should be turned into a link. /// </summary> /// <param name="s">A string.</param> /// <param name="start">A start index.</param> /// <param name="end">An end index.</param> /// <returns> /// <b>true</b> - if substring between start and end indexes should be turned into a link; otherwise - <b>false</b>. /// </returns> public bool AcceptMatch(Java.Lang.ICharSequence s, int start, int end) { if (Patterns.IpAddress.Matcher(s.SubSequenceFormatted(start, end)).Matches()) { return(false); } return(true); }
public Java.Lang.ICharSequence FilterFormatted(Java.Lang.ICharSequence source, int start, int end, ISpanned dest, int dstart, int dend) { string formatedSource = source.SubSequenceFormatted(start, end).ToString(); string destPrefix = dest.SubSequenceFormatted(0, dstart).ToString(); string destSuffix = dest.SubSequenceFormatted(dend, dest.Length()).ToString(); string result = destPrefix + formatedSource + destSuffix; Matcher matcher = mPattern.Matcher(result); if (!matcher.Matches()) { return(new Java.Lang.String(string.Empty)); } return(null); }
public Java.Lang.ICharSequence FilterFormatted(Java.Lang.ICharSequence source, int start, int end, ISpanned dest, int dstart, int dend) { return(source.SubSequenceFormatted(0, 0)); }
public Java.Lang.ICharSequence SubSequenceFormatted(int start, int end) { return(_source.SubSequenceFormatted(start, end)); // Return default }