A Methodology based on Commonsense Knowledge and Ontologies for the Automatic Classification of Legal Cases