library from ZendFramework-1.11.1