Mac Developer Library

Developer

OpenDirectory Framework Reference ODQueryDelegate Protocol Reference

Options
Deployment Target:

On This Page
Language:

ODQueryDelegate

The ODQueryDelegate protocol defines methods for receiving results returned from an Open Directory query.

Inheritance


Not Applicable

Import Statement


import OpenDirectory @import OpenDirectory;

Availability


Available in OS X v10.6 and later.
  • The delegate method called as results are returned from a query scheduled in a run loop.

    Declaration

    Swift

    func query(_ inQuery: ODQuery!, foundResults inResults: [AnyObject]!, error inError: NSError!)

    Objective-C

    - (void)query:(ODQuery *)inQuery foundResults:(NSArray *)inResults error:(NSError *)inError

    Parameters

    inQuery

    The query.

    inResults

    Partial results returned from the query.

    inError

    An error reference for error details.

    Discussion

    This method is called as soon as any results become available. Results must be retained or copied. If both inResults and inError are nil, the query has completed.

    Import Statement

    import OpenDirectory

    Availability

    Available in OS X v10.6 and later.