implements create container in swift