Added docs for the portlet

with some comments and reference.