/usr/lib/python2.6/site-packages/boto/s3
NameSizeModeActions
acl.py57270644editdlrm
acl.pyc60930644editdlrm
acl.pyo60930644editdlrm
bucket.py793690644editdlrm
bucket.pyc707340644editdlrm
bucket.pyo706880644editdlrm
bucketlistresultset.py67960644editdlrm
bucketlistresultset.pyc57470644editdlrm
bucketlistresultset.pyo57470644editdlrm
bucketlogging.py31830644editdlrm
bucketlogging.pyc29060644editdlrm
bucketlogging.pyo29060644editdlrm
connection.py261920644editdlrm
connection.pyc237440644editdlrm
connection.pyo236070644editdlrm
cors.py89410644editdlrm
cors.pyc80180644editdlrm
cors.pyo80180644editdlrm
deletemarker.py20870644editdlrm
deletemarker.pyc15010644editdlrm
deletemarker.pyo15010644editdlrm
key.py823190644editdlrm
key.pyc660280644editdlrm
key.pyo660280644editdlrm
keyfile.py44270644editdlrm
keyfile.pyc50100644editdlrm
keyfile.pyo50100644editdlrm
lifecycle.py82540644editdlrm
lifecycle.pyc92330644editdlrm
lifecycle.pyo92330644editdlrm
multidelete.py47570644editdlrm
multidelete.pyc49800644editdlrm
multidelete.pyo49800644editdlrm
multipart.py120490644editdlrm
multipart.pyc119560644editdlrm
multipart.pyo119560644editdlrm
prefix.py16610644editdlrm
prefix.pyc12430644editdlrm
prefix.pyo12430644editdlrm
resumable_download_handler.py155950644editdlrm
resumable_download_handler.pyc103360644editdlrm
resumable_download_handler.pyo103360644editdlrm
tagging.py17320644editdlrm
tagging.pyc36880644editdlrm
tagging.pyo36880644editdlrm
user.py19680644editdlrm
user.pyc15140644editdlrm
user.pyo15140644editdlrm
website.py106070644editdlrm
website.pyc123110644editdlrm
website.pyo123110644editdlrm
__init__.py23450644editdlrm
__init__.pyc18070644editdlrm
__init__.pyo18070644editdlrm
Edit: /usr/lib/python2.6/site-packages/boto/s3/bucket.pyo (70688B)
P5Tc!@sddkZddklZddklZddklZddklZlZl Z ddk l Z ddk l Z ddklZdd klZdd klZdd klZdd klZdd klZddklZddklZddklZddklZddklZddk l!Z!ddk"l#Z#ddk$Zddk%Zddk&Z'ddk(Z'ddk)Z)ddk*Z*ddk+l,Z,ddk-l.Z.l/Z/l0Z0l1Z1de2fdYZ3dddddgZ4de2fdYZ5dS( iN(thandler(t ResultSet(tBotoClientError(tPolicytCannedACLStringstGrant(tKey(tPrefix(t DeleteMarker(tMultiPartUpload(tCompleteMultiPartUpload(tMultiDeleteResult(tError(tBucketListResultSet(tVersionedBucketListResultSet(tMultiPartUploadListResultSet(t Lifecycle(tTags(tCORSConfiguration(t BucketLogging(twebsite(t defaultdict(tBytesIOtsixtStringIOturllibtS3WebsiteEndpointTranslatecBsveZedZded:sss3-website-eu-west-1s eu-west-1ss3-website-us-west-1s us-west-1ss3-website-us-west-2s us-west-2ss3-website-sa-east-1s sa-east-1ss3-website-ap-northeast-1sap-northeast-1ss3-website-ap-southeast-1sap-southeast-1ss3-website-ap-southeast-2sap-southeast-2ss3-website.cn-north-1s cn-north-1cCs |i|S(N(t trans_region(tselftreg((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyttranslate_regionDs(t__name__t __module__RRt classmethodR(((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyR8s        tREADtWRITEtREAD_ACPt WRITE_ACPt FULL_CONTROLtBucketcBs[eZdZdZdZdZdZdWdWedZ dZ dZ dZ d Z d Zd ZdWd ZdWdWdWed ZdZddddWdWdZdddddWdWdZdddWdWdZddZddWdZdZdWdZdWdZdZdWdZdWdZddWedWedZ edWdWdZ!dWdWdWdZ"dWdWdWdWdZ#dWdWd eedWdWd!Z$ddWdWd"Z%ddWdWd#Z&ddWdWd$d%Z'ddWdWd&Z(ddWdWd'Z)ddWdWd(Z*ddWdWd)Z+edWd*Z,edWd+Z-edWdWd,Z.dWd-Z/d.Z0dWd/Z1ddWdWd0Z2dWd1Z3dWd2Z4dWd3Z5dWd4Z6d5dWd6Z7edWdWd7Z8dWd8Z9dWd9Z:dWd:Z;dWd;Z<dWdWdWdWdWd<Z=dWd=Z>dWd>Z?dWd?Z@dWd@ZAdWdAZBdWdBZCdWdCZDdDZEdWdEZFdWdFZGdWdGZHdWdHZIdWdIZJdWdJZKdWdKZLdWdLZMdWedWedWdMZNdWdNZOdWdOZPdWdPZQdQZRdRZSdWdSdTZTdWdUZUdWdVZVRS(Xs.http://acs.amazonaws.com/groups/s3/LogDeliverys %s s %s %s s([A-Za-z]+)s"([A-Za-z]+)cCs||_||_||_dS(N(tnamet connectiont key_class(RR*R)R+((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt__init__]s  cCs d|iS(Ns (R)(R((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt__repr__bscCstt|S(N(titerR (R((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt__iter__escCs|i|dj S(N(tget_keytNone(Rtkey_name((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt __contains__hscCsdS(N(R1(RR)tattrsR*((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt startElementkscCsH|djo ||_n+|djo ||_nt|||dS(NtNamet CreationDate(R)t creation_datetsetattr(RR)tvalueR*((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt endElementns     cCs ||_dS(s  Set the Key class associated with this bucket. By default, this would be the boto.s3.key.Key class but if you want to subclass that for some reason this allows you to associate your new class with a bucket so that when you call bucket.new_key() or when you get a listing of keys in the bucket you will get an instances of your key class rather than the default. :type key_class: class :param key_class: A subclass of Key that can be more specific N(R+(RR+((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt set_key_classvs cCs|i|d|S(s Deprecated: Please use get_key method. :type key_name: string :param key_name: The name of the key to retrieve :rtype: :class:`boto.s3.key.Key` :returns: A Key object from this bucket. theaders(R0(RR2R=((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytlookups c Cs|tjo7|p|p|otddn|i|Sg}|o|id|n|oGxDti|D]/\}}|id|tii|fq}Wn|i |||\} } | S(s Check to see if a particular key exists within the bucket. This method uses a HEAD request to check for the existence of the key. Returns: An instance of a Key object or None :param key_name: The name of the key to retrieve :type key_name: string :param headers: The headers to send when retrieving the key :type headers: dict :param version_id: :type version_id: string :param response_headers: A dictionary containing HTTP headers/values that will override any headers associated with the stored object in the response. See http://goo.gl/EWOPb for details. :type response_headers: dict :param validate: Verifies whether the key exists. If ``False``, this will not hit the service, constructing an in-memory object. Default is ``True``. :type validate: bool :rtype: :class:`boto.s3.key.Key` :returns: A Key object from this bucket. s1When providing 'validate=False', no other params s are allowed.s versionId=%ss%s=%s( tFalseRtnew_keytappendRt iteritemsRtparsetquotet_get_key_internal( RR2R=t version_idtresponse_headerstvalidatet query_args_ltrktrvtkeytresp((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyR0s  +c Csdi|pd}|iid|i|d|d|}|i|iddjo|i|}|ii}t i i |i ||_ x9tiD].}|i||i|iidduutrueiiit PrefixSkippedtInvalidArguments0Invalid. No delete action taken for this object.tcodetmessageiu%su%su u sutf-8s Content-MD5stext/xmls Content-Typet tPOSTR=RPtdatai('tnextt StopIterationR~RRR1ttupletlenRRR)RFRtreprR terrorsRARRtsaxutilstescapeR?RRRYRZt compute_md5RTt mfa_headerR*RURVRWRRRRRjRk(thdrsRtcountRLR2RFRRterrortfptmd5RlRR(tresulttikeysRRXtquiett mfa_tokenRP(s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt delete_keys2st    #*              (R.R R*RX(RtkeysRRR=R((RRRRRRXRPs2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt delete_keyszs   != c Cs<|ptdn|i|d|d|d|ddS(s Deletes a key from the bucket. If a version_id is provided, only that version of the key will be deleted. :type key_name: string :param key_name: The key name to delete :type version_id: string :param version_id: The version ID (optional) :type mfa_token: tuple or list of strings :param mfa_token: A tuple or list consisting of the serial number from the MFA device and the current value of the six-digit token associated with the device. This value is required anytime you are deleting versioned objects from a bucket that has the MFADelete option on the bucket. :rtype: :class:`boto.s3.key.Key` or subclass :returns: A key object holding information on what was deleted. The Caller can see if a delete_marker was created or removed and what version_id the delete created or removed. sEmpty key names are not allowedR=RFRRIN(Rt_delete_key_internalR1(RR2R=RFR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt delete_keys c Cs|pg}|ii}|o|id|ndi|pd}|o+|p h}ndi|||is   cCs|i|dS(s Returns the current status of website configuration on the bucket. :rtype: dict :returns: A dictionary containing a Python representation of the XML response from S3. The overall structure is: * WebsiteConfiguration * IndexDocument * Suffix : suffix that is appended to request that is for a "directory" on the website endpoint * ErrorDocument * Key : name of object to serve when an error occurs i(t"get_website_configuration_with_xml(RR=((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytget_website_configurationscCsG|id|}ti}ti||}tii|||S(siGet the website configuration as a :class:`boto.s3.website.WebsiteConfiguration` object. R=(tget_website_configuration_xmlRR6RRRRR(RR=t config_xmlR<R((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytget_website_configuration_objs  cCsM|id|}tii}tii|d}|i|||fS(s Returns the current status of website configuration on the bucket as unparsed XML. :rtype: 2-Tuple :returns: 2-tuple containing: 1) A dictionary containing a Python representation of the XML response. The overall structure is: * WebsiteConfiguration * IndexDocument * Suffix : suffix that is appended to request that is for a "directory" on the website endpoint * ErrorDocument * Key : name of object to serve when an error occurs 2) unparsed XML describing the bucket's website configuration R=N(RARYt jsonresponsetElementRR1RC(RR=RteR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyR?s  cCs|iid|iddd|}|iid}tii||idjo%|ii i |i|i |n|S(s!Get raw website configuration xmlRRPRR=sutf-8i( R*RUR)RVR(RYRRRWRXRjRk(RR=RlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyRAs cCsz|iid|iddd|}|i}tii||idjotS|ii i |i|i |dS(sD Removes all website configuration from the bucket. RRPRR=iN( R*RUR)RVRYRRRWRRXRjRk(RR=RlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytdelete_website_configurations  cCs^|ig}|iti|i|idi|iiidddi|S(s Returns the fully qualified hostname to use is you want to access this bucket as a website. This doesn't validate whether the bucket has been correctly configured as a website or not. t.i( R)RARRRRTR*thosttsplit(Rtl((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytget_website_endpoints )cCsj|iid|iddd|}|i}|idjo|S|iii|i|i|dS(s Returns the JSON policy associated with the bucket. The policy is returned as an uninterpreted JSON string. RRPRR=iN(R*RUR)RVRWRXRjRk(RR=RlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt get_policys  c Cs|iid|id|ddd|}|i}|idjo|idjotS|iii|i|i|dS( s Add or replace the JSON policy associated with the bucket. :type policy: str :param policy: The JSON policy as a string. RRRPRR=iiN( R*RUR)RVRWRRXRjRk(RRR=RlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt set_policy(s    c Cs|iid|iddddd|}|i}|idjo|idjotS|iii|i|i|dS( NRRs/?policyRPRR=ii( R*RUR)RVRWRRXRjRk(RR=RlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyt delete_policy:s    c Cst|}tii|}|d jo h}n|d|diiN(R1R*RUR)R?RVR(tfindRRYRRRWR RRR~RRRRRR+ReRfRFt encryptedRXRjRk( RR2t upload_idtxml_bodyR=RPRltcontains_errorRRMRRm((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytcomplete_multipart_uploads4           cCsd|}|iid|i|d|d|}|i}tii||idjo%|iii |i|i |ndS(s To verify that all parts have been removed, so you don't get charged for the part storage, you should call the List Parts operation and ensure the parts list is empty. s uploadId=%sRRPR=iN( R*RUR)RVRYRRRWRXRjRk(RR2R]R=RPRlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytcancel_multipart_uploads    cCs|ii|id|S(NR=(R*t delete_bucketR)(RR=((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyRscCsa|i}t}ti||}t|tp|id}ntii |||S(Nsutf-8( t get_xml_tagsRRRR~RRRRR(RRlttagsR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pytget_tags!s  cCsj|iid|idddd}|i}|idjo|S|iii|i|i|dS(NRRPttaggingR=i( R*RUR)R1RVRWRXRjRk(RRlR((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyRc*s   Rfc Cs|djo h}ntiit|}|d|dRR0RERtRwRyRRRRRRRR@R?RRRRRRRRRRRRRRRRRRR R RRRRR%R/R3R4R5R=R7R>R@RCR?RARGRLRMRNRORRRTRURVRWRZR`RaRReRcRhRiRj(((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyR(Ks       2 %  2 /!    0 3 J  ` c    & $!'      /     !  !        N &    (6RYRtboto.resultsetRtboto.exceptionRt boto.s3.aclRRRt boto.s3.keyRtboto.s3.prefixRtboto.s3.deletemarkerRtboto.s3.multipartR R tboto.s3.multideleteR R tboto.s3.bucketlistresultsetR RRtboto.s3.lifecycleRtboto.s3.taggingRt boto.s3.corsRtboto.s3.bucketloggingRtboto.s3Rtboto.jsonresponset boto.utilstxml.saxRtxml.sax.saxutilsR)tbase64t collectionsRt boto.compatRRRRtobjectRRR((((s2/usr/lib/python2.6/site-packages/boto/s3/bucket.pyts<       "