Adding some check conditions and constructors for the cursor