Added abstractions for PBDB objects to be easier to work with.
Fixed namespace resolution issue with exceptions