本文整理汇总了C#中System.Arguments.CoerceAndAddAll方法的典型用法代码示例。如果您正苦于以下问题:C# Arguments.CoerceAndAddAll方法的具体用法?C# Arguments.CoerceAndAddAll怎么用?C# Arguments.CoerceAndAddAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Arguments
的用法示例。
在下文中一共展示了Arguments.CoerceAndAddAll方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ne
/// <summary>
/// <para>Test if two values are not equal.</para>
/// </summary>
/// <example><para>Example: Does 2 not equal 2?</para>
/// <code>r.expr(2).ne(2).run(conn, callback)
/// </code></example>
public Ne ne ( Object exprA, params object[] exprs )
{
Arguments arguments = new Arguments(this);
arguments.CoerceAndAdd(exprA);
arguments.CoerceAndAddAll(exprs);
return new Ne (arguments );
}
示例2: without
/// <summary>
/// <para>The opposite of pluck; takes an object or a sequence of objects, and returns them with
/// the specified paths removed.</para>
/// </summary>
/// <example><para>Example: Since we don't need it for this computation we'll save bandwidth and leave
/// out the list of IronMan's romantic conquests.</para>
/// <code>r.table('marvel').get('IronMan').without('personalVictoriesList').run(conn, callback)
/// </code></example>
public Without without ( params object[] exprs )
{
Arguments arguments = new Arguments(this);
arguments.CoerceAndAddAll(exprs);
return new Without (arguments );
}
示例3: and
/// <summary>
/// <para>Compute the logical "and" of two or more values.</para>
/// </summary>
/// <example><para>Example: Return whether both <code>a</code> and <code>b</code> evaluate to true.</para>
/// <code>var a = true, b = false;
/// r.expr(a).and(b).run(conn, callback);
/// // result passed to callback
/// false
/// </code></example>
public And and ( params object[] exprs )
{
Arguments arguments = new Arguments(this);
arguments.CoerceAndAddAll(exprs);
return new And (arguments );
}
示例4: GetAll
/// <summary>
/// <para>Get all documents where the given value matches the value of the requested index.</para>
/// </summary>
/// <example><para>Example: Secondary index keys are not guaranteed to be unique so we cannot query via <a href="/api/javascript/get/">get</a> when using a secondary index.</para>
/// <code>r.table('marvel').getAll('man_of_steel', {index:'code_name'}).run(conn, callback)
/// </code></example>
/// <param name="args">Same as calling params object[] overload, except the collection is applied as object[] params.</param>
public GetAll GetAll ( ICollection<Guid> args )
{
var arguments = new Arguments(this);
arguments.CoerceAndAddAll(args);
return new GetAll (arguments);
}
示例5: pluck
/// <summary>
/// <para>Plucks out one or more attributes from either an object or a sequence of objects
/// (projection).</para>
/// </summary>
/// <example><para>Example: We just need information about IronMan's reactor and not the rest of the
/// document.</para>
/// <code>r.table('marvel').get('IronMan').pluck('reactorState', 'reactorPower').run(conn, callback)
/// </code></example>
public Pluck pluck ( params object[] exprs )
{
Arguments arguments = new Arguments(this);
arguments.CoerceAndAddAll(exprs);
return new Pluck (arguments );
}
示例6: union
/// <summary>
/// <para>Concatenate two or more sequences.</para>
///</summary>
/// <example><para>Example: Construct a stream of all heroes.</para>
/// <code>r.table('marvel').union(r.table('dc')).run(conn, callback);
/// </code></example>
public Union union ( params object[] exprs )
{
Arguments arguments = new Arguments();
arguments.CoerceAndAddAll(exprs);
return new Union (arguments);
}
示例7: or
/// <summary>
/// <para>Compute the logical "or" of two or more values.</para>
///</summary>
/// <example><para>Example: Return whether either <code>a</code> or <code>b</code> evaluate to true.</para>
/// <code>var a = true, b = false;
/// r.expr(a).or(b).run(conn, callback);
/// // result passed to callback
/// true
/// </code></example>
public Or or ( Object expr, Object exprA, params object[] exprs )
{
Arguments arguments = new Arguments();
arguments.CoerceAndAdd(expr);
arguments.CoerceAndAdd(exprA);
arguments.CoerceAndAddAll(exprs);
return new Or (arguments);
}
示例8: HasFields
/// <summary>
/// <para>Test if an object has one or more fields. An object has a field if it has that key and the key has a non-null value. For instance, the object <code>{'a': 1,'b': 2,'c': null}</code> has the fields <code>a</code> and <code>b</code>.</para>
/// </summary>
/// <example><para>Example: Return the players who have won games.</para>
/// <code>r.table('players').hasFields('games_won').run(conn, callback)
/// </code></example>
/// <param name="args">Same as calling params object[] overload, except the collection is applied as object[] params.</param>
public HasFields HasFields ( ICollection<string> args )
{
var arguments = new Arguments(this);
arguments.CoerceAndAddAll(args);
return new HasFields (arguments);
}
示例9: Pluck
/// <summary>
/// <para>Plucks out one or more attributes from either an object or a sequence of objects
/// (projection).</para>
/// </summary>
/// <example><para>Example: We just need information about IronMan's reactor and not the rest of the
/// document.</para>
/// <code>r.table('marvel').get('IronMan').pluck('reactorState', 'reactorPower').run(conn, callback)
/// </code></example>
/// <param name="args">Same as calling params object[] overload, except the collection is applied as object[] params.</param>
public Pluck Pluck ( ICollection<string> args )
{
var arguments = new Arguments(this);
arguments.CoerceAndAddAll(args);
return new Pluck (arguments);
}
示例10: Branch
/// <summary>
/// <para>Perform a branching conditional equivalent to <code>if-then-else</code>.</para>
/// <para>The <code>branch</code> command takes 2n+1 arguments: pairs of conditional expressions and commands to be executed if the conditionals return any value but <code>false</code> or <code>null</code> (i.e., "truthy" values), with a final "else" command to be evaluated if all of the conditionals are <code>false</code> or <code>null</code>.</para>
///</summary>
/// <example><para>Example: Test the value of x.</para>
/// <code>var x = 10;
/// r.branch(r.expr(x).gt(5), 'big', 'small').run(conn, callback);
/// // Result passed to callback
/// "big"
/// </code></example>
public Branch Branch ( Object expr, Object exprA, Object exprB, params object[] exprs )
{
Arguments arguments = new Arguments();
arguments.CoerceAndAdd(expr);
arguments.CoerceAndAdd(exprA);
arguments.CoerceAndAdd(exprB);
arguments.CoerceAndAddAll(exprs);
return new Branch (arguments);
}
示例11: Or
/// <summary>
/// <para>Compute the logical "or" of one or more values.</para>
///</summary>
/// <example><para>Example: Return whether either <code>a</code> or <code>b</code> evaluate to true.</para>
/// <code>var a = true, b = false;
/// r.expr(a).or(b).run(conn, callback);
/// // result passed to callback
/// true
/// </code></example>
public Or Or ( params object[] exprs )
{
Arguments arguments = new Arguments();
arguments.CoerceAndAddAll(exprs);
return new Or (arguments);
}
示例12: indexWait
/// <summary>
/// <para>Wait for the specified indexes on this table to be ready, or for all
/// indexes on this table to be ready if no indexes are specified.</para>
/// </summary>
/// <example><para>Example: Wait for all indexes on the table <code>test</code> to be ready:</para>
/// <code>r.table('test').indexWait().run(conn, callback)
/// </code>
/// <para>Example: Wait for the index <code>timestamp</code> to be ready:</para>
/// <code>r.table('test').indexWait('timestamp').run(conn, callback)
/// </code></example>
public IndexWait indexWait ( params object[] exprs )
{
Arguments arguments = new Arguments(this);
arguments.CoerceAndAddAll(exprs);
return new IndexWait (arguments);
}
示例13: getAll
/// <summary>
/// <para>Get all documents where the given value matches the value of the requested index.</para>
/// </summary>
/// <example><para>Example: Secondary index keys are not guaranteed to be unique so we cannot query via <a href="/api/javascript/get/">get</a> when using a secondary index.</para>
/// <code>r.table('marvel').getAll('man_of_steel', {index:'code_name'}).run(conn, callback)
/// </code></example>
public GetAll getAll ( params object[] exprs )
{
Arguments arguments = new Arguments(this);
arguments.CoerceAndAddAll(exprs);
return new GetAll (arguments);
}
示例14: IndexWait
/// <summary>
/// <para>Wait for the specified indexes on this table to be ready, or for all
/// indexes on this table to be ready if no indexes are specified.</para>
/// </summary>
/// <example><para>Example: Wait for all indexes on the table <code>test</code> to be ready:</para>
/// <code>r.table('test').indexWait().run(conn, callback)
/// </code></example>
/// <param name="args">Same as calling params object[] overload, except the collection is applied as object[] params.</param>
public IndexWait IndexWait ( ICollection<string> args )
{
var arguments = new Arguments(this);
arguments.CoerceAndAddAll(args);
return new IndexWait (arguments);
}
示例15: polygon
/// <summary>
/// <para>Construct a geometry object of type Polygon. The Polygon can be specified in one of two ways:</para>
/// <ul>
/// <li>Three or more two-item arrays, specifying longitude and latitude numbers of the polygon's vertices;</li>
/// <li>Three or more <a href="/api/javascript/point">Point</a> objects specifying the polygon's vertices.</li>
/// </ul>
///</summary>
/// <example><para>Example: Define a polygon.</para>
/// <code>r.table('geo').insert({
/// id: 101,
/// rectangle: r.polygon(
/// [-122.423246,37.779388],
/// [-122.423246,37.329898],
/// [-121.886420,37.329898],
/// [-121.886420,37.779388]
/// )
/// }).run(conn, callback);
/// </code></example>
public Polygon polygon ( Object expr, Object exprA, Object exprB, params object[] exprs )
{
Arguments arguments = new Arguments();
arguments.CoerceAndAdd(expr);
arguments.CoerceAndAdd(exprA);
arguments.CoerceAndAdd(exprB);
arguments.CoerceAndAddAll(exprs);
return new Polygon (arguments);
}