src/Cassandra/KeyspaceMetadata.cs
/// <summary>
/// Gets a CQL function by name and signature
/// </summary>
/// <returns>The function metadata or null if not found.</returns>
Gets a CQL function by name and signature
Gets a CQL function by name and signature
public FunctionMetadata GetFunction(string functionName, string[] signature)
        {
            if (signature == null)
            {
                signature = new string[0];
            }
            FunctionMetadata func;
            var key = GetFunctionKey(functionName, signature);
            if (_functions.TryGetValue(key, out func))
            {
                return func;
            }
            var signatureString = "[" + string.Join(",", signature.Select(s => "'" + s + "'")) + "]";
            var t = _parent.SchemaParser
                .GetFunction(Name, functionName, signatureString)
                .ContinueSync(f =>
                {
                    if (f == null)
                    {
                        return null;
                    }
                    _functions.AddOrUpdate(key, f, (k, v) => f);
                    return f;
                });
            return TaskHelper.WaitToComplete(t, _parent.Configuration.ClientOptions.QueryAbortTimeout);
        }
public FunctionMetadata GetFunction ( string functionName , string [ ] signature ) { if ( signature == null ) { signature = new string [ 0 ] ; } FunctionMetadata func ; var key = GetFunctionKey ( functionName , signature ) ; if ( _functions . TryGetValue ( key , out func ) ) { return func ; } var signatureString = " " + string . Join ( " " , signature . Select ( s => " " + s + " " ) ) + " " ; var t = _parent . SchemaParser . GetFunction ( Name , functionName , signatureString ) . ContinueSync ( f => { if ( f == null ) { return null ; } _functions . AddOrUpdate ( key , f , ( k , v ) => f ) ; return f ; } ) ; return TaskHelper . WaitToComplete ( t , _parent . Configuration . ClientOptions . QueryAbortTimeout ) ; }
Gets a CQL function by name and signature
Gets a CQL function by name and signature
The function metadata or null if not found.
The function metadata or null if not found .
functionName
string
signature
string[]