Added Count() method to ReferenceCounted template.

Added som comments.