select_async


Description:

public async void select_async (string where, ArrayList<T> ret) throws ThreadError

Selects objects from the table matching a WHERE clause asynchronously.

This method executes a SELECT query in a background thread and populates the result list with instantiated objects of type T.

**IMPORTANT**: You MUST always use `yield` when calling this method. The result list (`ret`) is being populated in a background thread and is NOT thread-safe to access while the query is running. Only access the result list after `yield` returns (i.e., after the async method completes).

Parameters:

where

The WHERE clause (e.g., "WHERE id = 5" or "WHERE name = 'test'")

ret

The list to populate with results (DO NOT access until after yield completes)

Exceptions:

ThreadError

if thread creation fails