Added test PCL adapter. Minor refactoring.