@Override
public CompilationUnit adapt(CompilationUnitContext context) {
CompilationUnit compilationUnit = createNode(context);
PackageDeclarationContext packageDeclarationContext =
getChild(context, PackageDeclarationContext.class);
if (packageDeclarationContext != null) {
compilationUnit.setPackageDeclaration(
getAdapter(PackageDeclarationAdapter.class).adapt(packageDeclarationContext));
}