Copyright | (c) 2013-2017 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Returns some or all (up to 1000) of the objects in a bucket. You can use the request parameters as selection criteria to return a subset of the objects in a bucket. Note: ListObjectsV2 is the revised List Objects API and we recommend you use this revised API for new application development.
- listObjectsV :: BucketName -> ListObjectsV
- data ListObjectsV
- lStartAfter :: Lens' ListObjectsV (Maybe Text)
- lContinuationToken :: Lens' ListObjectsV (Maybe Text)
- lFetchOwner :: Lens' ListObjectsV (Maybe Bool)
- lPrefix :: Lens' ListObjectsV (Maybe Text)
- lEncodingType :: Lens' ListObjectsV (Maybe EncodingType)
- lRequestPayer :: Lens' ListObjectsV (Maybe RequestPayer)
- lMaxKeys :: Lens' ListObjectsV (Maybe Int)
- lDelimiter :: Lens' ListObjectsV (Maybe Delimiter)
- lBucket :: Lens' ListObjectsV BucketName
- listObjectsVResponse :: Int -> ListObjectsVResponse
- data ListObjectsVResponse
- lrsStartAfter :: Lens' ListObjectsVResponse (Maybe Text)
- lrsKeyCount :: Lens' ListObjectsVResponse (Maybe Int)
- lrsContents :: Lens' ListObjectsVResponse [Object]
- lrsContinuationToken :: Lens' ListObjectsVResponse (Maybe Text)
- lrsPrefix :: Lens' ListObjectsVResponse (Maybe Text)
- lrsCommonPrefixes :: Lens' ListObjectsVResponse [CommonPrefix]
- lrsEncodingType :: Lens' ListObjectsVResponse (Maybe EncodingType)
- lrsName :: Lens' ListObjectsVResponse (Maybe BucketName)
- lrsNextContinuationToken :: Lens' ListObjectsVResponse (Maybe Text)
- lrsMaxKeys :: Lens' ListObjectsVResponse (Maybe Int)
- lrsIsTruncated :: Lens' ListObjectsVResponse (Maybe Bool)
- lrsDelimiter :: Lens' ListObjectsVResponse (Maybe Delimiter)
- lrsResponseStatus :: Lens' ListObjectsVResponse Int
Creating a Request
Creates a value of ListObjectsV
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
lStartAfter
- StartAfter is where you want Amazon S3 to start listing from. Amazon S3 starts listing after this specified key. StartAfter can be any key in the bucketlContinuationToken
- ContinuationToken indicates Amazon S3 that the list is being continued on this bucket with a token. ContinuationToken is obfuscated and is not a real keylFetchOwner
- The owner field is not present in listV2 by default, if you want to return owner field with each key in the result then set the fetch owner field to truelPrefix
- Limits the response to keys that begin with the specified prefix.lEncodingType
- Encoding type used by Amazon S3 to encode object keys in the response.lRequestPayer
- Confirms that the requester knows that she or he will be charged for the list objects request in V2 style. Bucket owners need not specify this parameter in their requests.lMaxKeys
- Sets the maximum number of keys returned in the response. The response might contain fewer keys but will never contain more.lDelimiter
- A delimiter is a character you use to group keys.lBucket
- Name of the bucket to list.
data ListObjectsV Source #
See: listObjectsV
smart constructor.
Request Lenses
lStartAfter :: Lens' ListObjectsV (Maybe Text) Source #
StartAfter is where you want Amazon S3 to start listing from. Amazon S3 starts listing after this specified key. StartAfter can be any key in the bucket
lContinuationToken :: Lens' ListObjectsV (Maybe Text) Source #
ContinuationToken indicates Amazon S3 that the list is being continued on this bucket with a token. ContinuationToken is obfuscated and is not a real key
lFetchOwner :: Lens' ListObjectsV (Maybe Bool) Source #
The owner field is not present in listV2 by default, if you want to return owner field with each key in the result then set the fetch owner field to true
lPrefix :: Lens' ListObjectsV (Maybe Text) Source #
Limits the response to keys that begin with the specified prefix.
lEncodingType :: Lens' ListObjectsV (Maybe EncodingType) Source #
Encoding type used by Amazon S3 to encode object keys in the response.
lRequestPayer :: Lens' ListObjectsV (Maybe RequestPayer) Source #
Confirms that the requester knows that she or he will be charged for the list objects request in V2 style. Bucket owners need not specify this parameter in their requests.
lMaxKeys :: Lens' ListObjectsV (Maybe Int) Source #
Sets the maximum number of keys returned in the response. The response might contain fewer keys but will never contain more.
lDelimiter :: Lens' ListObjectsV (Maybe Delimiter) Source #
A delimiter is a character you use to group keys.
lBucket :: Lens' ListObjectsV BucketName Source #
Name of the bucket to list.
Destructuring the Response
Creates a value of ListObjectsVResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
lrsStartAfter
- StartAfter is where you want Amazon S3 to start listing from. Amazon S3 starts listing after this specified key. StartAfter can be any key in the bucketlrsKeyCount
- KeyCount is the number of keys returned with this request. KeyCount will always be less than equals to MaxKeys field. Say you ask for 50 keys, your result will include less than equals 50 keyslrsContents
- Metadata about each object returned.lrsContinuationToken
- ContinuationToken indicates Amazon S3 that the list is being continued on this bucket with a token. ContinuationToken is obfuscated and is not a real keylrsPrefix
- Limits the response to keys that begin with the specified prefix.lrsCommonPrefixes
- CommonPrefixes contains all (if there are any) keys between Prefix and the next occurrence of the string specified by delimiterlrsEncodingType
- Encoding type used by Amazon S3 to encode object keys in the response.lrsName
- Name of the bucket to list.lrsNextContinuationToken
- NextContinuationToken is sent when isTruncated is true which means there are more keys in the bucket that can be listed. The next list requests to Amazon S3 can be continued with this NextContinuationToken. NextContinuationToken is obfuscated and is not a real keylrsMaxKeys
- Sets the maximum number of keys returned in the response. The response might contain fewer keys but will never contain more.lrsIsTruncated
- A flag that indicates whether or not Amazon S3 returned all of the results that satisfied the search criteria.lrsDelimiter
- A delimiter is a character you use to group keys.lrsResponseStatus
- -- | The response status code.
data ListObjectsVResponse Source #
See: listObjectsVResponse
smart constructor.
Response Lenses
lrsStartAfter :: Lens' ListObjectsVResponse (Maybe Text) Source #
StartAfter is where you want Amazon S3 to start listing from. Amazon S3 starts listing after this specified key. StartAfter can be any key in the bucket
lrsKeyCount :: Lens' ListObjectsVResponse (Maybe Int) Source #
KeyCount is the number of keys returned with this request. KeyCount will always be less than equals to MaxKeys field. Say you ask for 50 keys, your result will include less than equals 50 keys
lrsContents :: Lens' ListObjectsVResponse [Object] Source #
Metadata about each object returned.
lrsContinuationToken :: Lens' ListObjectsVResponse (Maybe Text) Source #
ContinuationToken indicates Amazon S3 that the list is being continued on this bucket with a token. ContinuationToken is obfuscated and is not a real key
lrsPrefix :: Lens' ListObjectsVResponse (Maybe Text) Source #
Limits the response to keys that begin with the specified prefix.
lrsCommonPrefixes :: Lens' ListObjectsVResponse [CommonPrefix] Source #
CommonPrefixes contains all (if there are any) keys between Prefix and the next occurrence of the string specified by delimiter
lrsEncodingType :: Lens' ListObjectsVResponse (Maybe EncodingType) Source #
Encoding type used by Amazon S3 to encode object keys in the response.
lrsName :: Lens' ListObjectsVResponse (Maybe BucketName) Source #
Name of the bucket to list.
lrsNextContinuationToken :: Lens' ListObjectsVResponse (Maybe Text) Source #
NextContinuationToken is sent when isTruncated is true which means there are more keys in the bucket that can be listed. The next list requests to Amazon S3 can be continued with this NextContinuationToken. NextContinuationToken is obfuscated and is not a real key
lrsMaxKeys :: Lens' ListObjectsVResponse (Maybe Int) Source #
Sets the maximum number of keys returned in the response. The response might contain fewer keys but will never contain more.
lrsIsTruncated :: Lens' ListObjectsVResponse (Maybe Bool) Source #
A flag that indicates whether or not Amazon S3 returned all of the results that satisfied the search criteria.
lrsDelimiter :: Lens' ListObjectsVResponse (Maybe Delimiter) Source #
A delimiter is a character you use to group keys.
lrsResponseStatus :: Lens' ListObjectsVResponse Int Source #
- - | The response status code.