class DLFileEntryTypeResolversImpl implements DLFileEntryTypeResolvers {

    @Override
    public DataFetcher<CompletableFuture<DLFileEntryType>> getDLFileEntryTypeDataFetcher() {
        return environment -> {
            long fileEntryTypeId = getFileEntryTypeId(environment);
            if (fileEntryTypeId <= 0) {
                return null;
            }

            DataLoader<Long, DLFileEntryType> dataLoader = environment.getDataLoader(DLFileEntryTypeBatchLoader.KEY);
            return dataLoader.load(fileEntryTypeId);
        };
    }

}