'Check if resource is mapped to resource_type or is "resource_type".
Check to see if this resource is either mapped to resource_type
or is a "resource_type".'

def has_interface(self, resource_type):

    if (self.type() == resource_type):
        return True
    try:
        ri = self.stack.env.get_resource_info(self.type(), self.name)
    except exception.EntityNotFound:
        return False
    else:
        return (ri.name == resource_type)
