Added warning handling code and hasLink method to resource class