Issue #154: Convert taxonomy objects into real classes

PR for #backdrop-issues/154.

Based on available patches from drupal.org.