God! That's a shame if all files lost. But don't be upset, and you can rebuild iTunes Library with third-party tool to rescue your deleted items. Try as the following asked:
1. Download the free trial version of TunesGo. Install and run it on computer. Connect your device to computer via a USB cable.
2. Select "Copy Music from Device to iTunes", and select "Start" from the pop-up interface. When the program finished scanning the media files on your device, all categories found will be checked by default. Click on "Music" > "Copy to iTunes" to recover deleted songs in iTunes library.