QueryResolver
new QueryResolver()
Properties
public regex: { appleMusicAlbumRegex: RegExp,appleMusicPlaylistRegex: RegExp,appleMusicSongRegex: RegExp,attachmentRegex: RegExp,reverbnationRegex: RegExp,spotifyAlbumRegex: RegExp,spotifyPlaylistRegex: RegExp,spotifySongRegex: RegExp,vimeoRegex: RegExp }
Methods
public static getVimeoID(query): undefined | null | string
Parses vimeo id from url
Parameter | Type | Optional | Description |
---|---|---|---|
query | string | ❌ | The query |
public static resolve(query): 'auto' | 'youtube' | 'youtubePlaylist' | 'soundcloudTrack' | 'soundcloudPlaylist' | 'soundcloud' | 'spotifySong' | 'spotifyAlbum' | 'spotifyPlaylist' | 'facebook' | 'vimeo' | 'arbitrary' | 'reverbnation' | 'youtubeSearch' | 'youtubeVideo' | 'soundcloudSearch' | 'appleMusicSong' | 'appleMusicAlbum' | 'appleMusicPlaylist' | 'appleMusicSearch' | 'file'
Resolves the given search query
Parameter | Type | Optional | Description |
---|---|---|---|
query | string | ❌ | The query |
public static validateId(q): boolean
Parameter | Type | Optional | Description |
---|---|---|---|
q | string | ❌ | - |
public static validateURL(q): boolean
Parameter | Type | Optional | Description |
---|---|---|---|
q | string | ❌ | - |