/*global Autolinker */ /** * @class Autolinker.match.Phone * @extends Autolinker.match.Match * * Represents a Phone number match found in an input string which should be * Autolinked. * * See this class's superclass ({@link Autolinker.match.Match}) for more * details. */ Autolinker.match.Phone = Autolinker.Util.extend( Autolinker.match.Match, { /** * @cfg {String} number (required) * * The phone number that was matched. */ /** * Returns a string name for the type of match that this class represents. * * @return {String} */ getType : function() { return 'phone'; }, /** * Returns the phone number that was matched. * * @return {String} */ getNumber: function() { return this.number; }, /** * Returns the anchor href that should be generated for the match. * * @return {String} */ getAnchorHref : function() { return 'tel:' + this.number; }, /** * Returns the anchor text that should be generated for the match. * * @return {String} */ getAnchorText : function() { return this.matchedText; } } );