Bug 1149766 - Number of child resources retrieved using REST can't be
modified using ps param and is always limited to 100

Added suport for paging, default page size is now 20
Fix if clause, instanceof always returns false is object is null
Fix equals method to check correct class