A generalized non-local optical response theory for plasmonic nanostructures