{-# 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.Storage.DefaultObjectAccessControls.List
(
DefaultObjectAccessControlsListResource
, defaultObjectAccessControlsList
, DefaultObjectAccessControlsList
, doaclIfMetagenerationMatch
, doaclBucket
, doaclUserProject
, doaclIfMetagenerationNotMatch
) where
import Network.Google.Prelude
import Network.Google.Storage.Types
type DefaultObjectAccessControlsListResource =
"storage" :>
"v1" :>
"b" :>
Capture "bucket" Text :>
"defaultObjectAcl" :>
QueryParam "ifMetagenerationMatch" (Textual Int64) :>
QueryParam "userProject" Text :>
QueryParam "ifMetagenerationNotMatch" (Textual Int64)
:>
QueryParam "alt" AltJSON :>
Get '[JSON] ObjectAccessControls
data DefaultObjectAccessControlsList = DefaultObjectAccessControlsList'
{ _doaclIfMetagenerationMatch :: !(Maybe (Textual Int64))
, _doaclBucket :: !Text
, _doaclUserProject :: !(Maybe Text)
, _doaclIfMetagenerationNotMatch :: !(Maybe (Textual Int64))
} deriving (Eq,Show,Data,Typeable,Generic)
defaultObjectAccessControlsList
:: Text
-> DefaultObjectAccessControlsList
defaultObjectAccessControlsList pDoaclBucket_ =
DefaultObjectAccessControlsList'
{ _doaclIfMetagenerationMatch = Nothing
, _doaclBucket = pDoaclBucket_
, _doaclUserProject = Nothing
, _doaclIfMetagenerationNotMatch = Nothing
}
doaclIfMetagenerationMatch :: Lens' DefaultObjectAccessControlsList (Maybe Int64)
doaclIfMetagenerationMatch
= lens _doaclIfMetagenerationMatch
(\ s a -> s{_doaclIfMetagenerationMatch = a})
. mapping _Coerce
doaclBucket :: Lens' DefaultObjectAccessControlsList Text
doaclBucket
= lens _doaclBucket (\ s a -> s{_doaclBucket = a})
doaclUserProject :: Lens' DefaultObjectAccessControlsList (Maybe Text)
doaclUserProject
= lens _doaclUserProject
(\ s a -> s{_doaclUserProject = a})
doaclIfMetagenerationNotMatch :: Lens' DefaultObjectAccessControlsList (Maybe Int64)
doaclIfMetagenerationNotMatch
= lens _doaclIfMetagenerationNotMatch
(\ s a -> s{_doaclIfMetagenerationNotMatch = a})
. mapping _Coerce
instance GoogleRequest
DefaultObjectAccessControlsList where
type Rs DefaultObjectAccessControlsList =
ObjectAccessControls
type Scopes DefaultObjectAccessControlsList =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/devstorage.full_control"]
requestClient DefaultObjectAccessControlsList'{..}
= go _doaclBucket _doaclIfMetagenerationMatch
_doaclUserProject
_doaclIfMetagenerationNotMatch
(Just AltJSON)
storageService
where go
= buildClient
(Proxy ::
Proxy DefaultObjectAccessControlsListResource)
mempty