Added getPid method