src/Cassandra/KeyspaceMetadata.cs
/// <summary>
///  Returns metadata of specified view in this keyspace.
/// </summary>
/// <param name="viewName">the name of view to retrieve </param>
/// <returns>the metadata for view <c>viewName</c> in this keyspace if it
///  exists, <c>null</c> otherwise.</returns>
Returns metadata of specified view in this keyspace.
Returns metadata of specified view in this keyspace .
public MaterializedViewMetadata GetMaterializedViewMetadata(string viewName)
        {
            {
                MaterializedViewMetadata view;
                if (_views.TryGetValue(viewName, out view))
                {
                    return view;
                }
            }
            var task = _parent.SchemaParser
                .GetView(Name, viewName)
                .ContinueSync(view =>
                {
                    if (view == null)
                    {
                        return null;
                    }
                    _views.AddOrUpdate(viewName, view, (k, o) => view);
                    return view;
                });
            return TaskHelper.WaitToComplete(task, _parent.Configuration.ClientOptions.GetQueryAbortTimeout(2));
        }
public MaterializedViewMetadata GetMaterializedViewMetadata ( string viewName ) { { MaterializedViewMetadata view ; if ( _views . TryGetValue ( viewName , out view ) ) { return view ; } } var task = _parent . SchemaParser . GetView ( Name , viewName ) . ContinueSync ( view => { if ( view == null ) { return null ; } _views . AddOrUpdate ( viewName , view , ( k , o ) => view ) ; return view ; } ) ; return TaskHelper . WaitToComplete ( task , _parent . Configuration . ClientOptions . GetQueryAbortTimeout ( 2 ) ) ; }
Returns metadata of specified view in this keyspace.
Returns metadata of specified view in this keyspace .
//use a code block to avoid reusing 'view' field on lambdas //The table metadata is available in local cache //Cache it
the metadata for view viewNamenull
the metadata for view viewNamenull
viewName
string
the name of view to retrieve
the name of view to retrieve