Code example for Matcher

Methods: replaceAll

         * Apply this formatting rule to the given input string, and return the 
         * resulting new string. 
        public String apply(String input) {
            Matcher m = mPattern.matcher(input);
            return m.replaceAll(mReplaceWith);
     * List of internal formatting rules to apply when parsing wiki text. These 
     * include indenting various bullets, apply italic and bold styles, and 
     * adding internal linking. 
    private static final List<FormatRule> sFormatRules = new ArrayList<FormatRule>();
    static { 
        // Format header blocks and wrap outside content in ordered list 
        sFormatRules.add(new FormatRule("^=+(.+?)=+", "</ol><h2>$1</h2><ol>",