implemented basic view functions