Added getAs helper methods. Closes #3