Sounds like you have the security on the phone set to restore after 10 failed attempts for the passcode. If that is what happened, then it has wiped your device. If you have a backup, restore it, Restore your iPhone, iPad, or iPod touch from a backup - Apple Support
If you do not have a backup, your content is lost. Set the iPhone up as new, and move on. Apple Support cannot recover data you have deleted. If you do not wish this to happen again the next time that you have troubles with the passcode, then go to Settings>Touch ID & Passcode, and turn off Erase Data.