adapter implementation