'Difference between passing parameter "params object array" and "object array"

I'm currently coding an function of input object array, and have read many example, then I found these example in EntityFrameworkCore document:

public virtual ValueTask<TEntity?> FindAsync(params object?[]? keyValues)
public virtual ValueTask<TEntity?> FindAsync(object?[]? keyValues, CancellationToken cancellationToken)

Is there any difference between the first input parameter of these two methods, params object?[]? and object?[]?

I have looked up many of introductions of params or other related articles, but not found any disscusion of the difference.

In particular I've read MSDN params keyword says

By using the params keyword, you can specify a method parameter that takes a variable number of arguments. The parameter type must be a single-dimensional array.

and shows example of passing comma separated parameters in case of params :

public static void UseParams2(params object[] list){}
...
UseParams2(1, 'a', "test");

When I tried similar thing with method that does not specify params it failed to compile:

...FindAsync(1, 'a', "test", CancellationToken.None)

seems like params can be ignore? Does someone know the difference between them? or they are exactly the same meaning?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source