first i decided to delete this question because of very stupid mistake. but later i decided to remain as it is.
there was some setting problem or bug in netbeans, thats why it was unable to expand $this object member "splpriorityqueue".
$this->paths = isset($paths) ? $paths : $this->loadPaths();
above statement is perfectly correct.
and the error "layout path was not found" was beacause i named my tmpl folder as templ. which was causing realpath() function in
JPath::find()
to not work properly.