Fixed DCLayerFactory and added comments