<?xml version="1.0"?>
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
  <CodeSnippet Format="1.0.0">
    <Header>
      <Title>Query over a collection</Title>
      <Author>Microsoft Corporation</Author>
      <Description>A query over a collection.</Description>
      <Shortcut>qArray</Shortcut>
    </Header>
    <Snippet>
      <Declarations>
        <Literal>
          <ID>queryResult</ID>
          <Type>item</Type>
          <ToolTip>Replace with the identifier for the query.</ToolTip>
          <Default>query</Default>
        </Literal>
        <Literal>
          <ID>item</ID>
          <Type>item</Type>
          <ToolTip>Replace with the identifier for the variable that represents an item from your data source.</ToolTip>
          <Default>name</Default>
        </Literal>
        <Literal>
          <ID>dataSource</ID>
          <Type>String</Type>
          <ToolTip>Replace with the identifier for your data source.</ToolTip>
          <Default>names</Default>
        </Literal>
          <Literal>
          <ID>dataSourceType</ID>
          <Type>String</Type>
          <ToolTip>Replace with the type of your data source.</ToolTip>
          <Default>List(Of String)</Default>
        </Literal>
      </Declarations>
      <Code Language="VB" Kind="method body"><![CDATA[Dim $dataSource$ As New $dataSourceType$
        
                 ' populate your collection here.
                 ' $dataSource$.Add( ... )

                 Dim $queryResult$ = From $item$ In $dataSource$ _
                              Select $item$]]></Code>
    </Snippet>
  </CodeSnippet>
</CodeSnippets>