nl_tokens: @param { String / Number } version The version number in the following standard format :
pl_tokens: function ( version ) { var parts , releaseStartIndex ; if ( version instanceof Version ) { return version ; } this . version = this . shortVersion = String ( version ) . toLowerCase ( ) . replace ( / _ / g , '.' ) . replace ( / [\-+] / g , '' ) ; releaseStartIndex = this . version . search ( / ([^\d\.]) / ) ; if ( releaseStartIndex !== - 1 ) { this . release = this . version . substr ( releaseStartIndex , version . length ) ; this . shortVersion = this . version . substr ( 0 , releaseStartIndex ) ; } this . shortVersion = this . shortVersion . replace ( / [^\d] / g , '' ) ; parts = this . <mask> . split ( '.' ) ; this . major = parseInt ( parts . shift ( ) || 0 , 10 ) ; this . minor = parseInt ( parts . shift ( ) || 0 , 10 ) ; this . patch = parseInt ( parts . shift ( ) || 0 , 10 ) ; this . build = parseInt ( parts . shift ( ) || 0 , 10 ) ; return this ; }