code: public static FunctionImport getAndCheckFunctionImport(EntityDataModel entityDataModel, String functionImportName) {
          FunctionImport functionImport = entityDataModel.getEntityContainer().getFunctionImport(functionImportName);
          if (functionImport == null) {
              throw new ODataSystemException("Function import not found in the entity data model: " + functionImportName);
          }
  
          return functionImport;
      }
docs: Gets the function import by the specified name, throw an exception if no function import with the specified name
  exists.
  
  @param entityDataModel    The entity data model.
  @param functionImportName The name of the function import.
  @return The function import