{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.Google.Resource.FusionTables.Task.List
(
TaskListResource
, taskList'
, TaskList'
, tlPageToken
, tlTableId
, tlStartIndex
, tlMaxResults
) where
import Network.Google.FusionTables.Types
import Network.Google.Prelude
type TaskListResource =
"fusiontables" :>
"v2" :>
"tables" :>
Capture "tableId" Text :>
"tasks" :>
QueryParam "pageToken" Text :>
QueryParam "startIndex" (Textual Word32) :>
QueryParam "maxResults" (Textual Word32) :>
QueryParam "alt" AltJSON :> Get '[JSON] TaskList
data TaskList' = TaskList''
{ _tlPageToken :: !(Maybe Text)
, _tlTableId :: !Text
, _tlStartIndex :: !(Maybe (Textual Word32))
, _tlMaxResults :: !(Maybe (Textual Word32))
} deriving (Eq,Show,Data,Typeable,Generic)
taskList'
:: Text
-> TaskList'
taskList' pTlTableId_ =
TaskList''
{ _tlPageToken = Nothing
, _tlTableId = pTlTableId_
, _tlStartIndex = Nothing
, _tlMaxResults = Nothing
}
tlPageToken :: Lens' TaskList' (Maybe Text)
tlPageToken
= lens _tlPageToken (\ s a -> s{_tlPageToken = a})
tlTableId :: Lens' TaskList' Text
tlTableId
= lens _tlTableId (\ s a -> s{_tlTableId = a})
tlStartIndex :: Lens' TaskList' (Maybe Word32)
tlStartIndex
= lens _tlStartIndex (\ s a -> s{_tlStartIndex = a})
. mapping _Coerce
tlMaxResults :: Lens' TaskList' (Maybe Word32)
tlMaxResults
= lens _tlMaxResults (\ s a -> s{_tlMaxResults = a})
. mapping _Coerce
instance GoogleRequest TaskList' where
type Rs TaskList' = TaskList
type Scopes TaskList' =
'["https://www.googleapis.com/auth/fusiontables",
"https://www.googleapis.com/auth/fusiontables.readonly"]
requestClient TaskList''{..}
= go _tlTableId _tlPageToken _tlStartIndex
_tlMaxResults
(Just AltJSON)
fusionTablesService
where go
= buildClient (Proxy :: Proxy TaskListResource)
mempty