renamed Document to Resource