Coelom, the cavity between the alimentary canal and the body wall is enclosed by
mesoderm on both sides
Coelom is the body cavity in some animals such as annelids, molluscs, arthropods, echinoderms, hemichordates and chordates, which is lined by the mesoderm.
The ectoderm and endoderm are the external and internal germ layers, respectively, in animals such as cnidaria.