Introduced pollView method
Extended example to use pollView method