Database trigger

How do prevent to delete the Records only Owner or Creater of the Record in Salesforce? If object model is public and delete button is enabled to pagelayout, but Owner or Contact only to delete the contacts records. not possible…