Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Ganeti.Query.Query
Description
Implementation of the Ganeti Query2 functionality.
Synopsis
- query :: ConfigData -> Bool -> Query -> IO (ErrorResult QueryResult)
- queryFields :: QueryFields -> ErrorResult QueryFieldsResult
- queryCompat :: QueryResult -> ErrorResult [[JSValue]]
- getRequestedNames :: Query -> [String]
- nameField :: ItemType -> FilterField
- data NoDataRuntime
- uuidField :: ItemType -> FilterField
Documentation
Arguments
:: ConfigData | The current configuration |
-> Bool | Whether to collect live data |
-> Query | The query (item, fields, filter) |
-> IO (ErrorResult QueryResult) | Result |
Main query execution function.
queryFields :: QueryFields -> ErrorResult QueryFieldsResult #
Query fields call.
queryCompat :: QueryResult -> ErrorResult [[JSValue]] #
Classic query converter. It gets a standard query result on input and computes the classic style results.
getRequestedNames :: Query -> [String] #
Checks that we have either requested a valid set of names, or we have a more complex filter.
nameField :: ItemType -> FilterField #
Computes the name field for different query types.
data NoDataRuntime #
The runtime used by queries which retrieve no live data.
uuidField :: ItemType -> FilterField #
Computes the uuid field, or the best possible substitute, for different query types.