storeSetMetadata

Sets the metadata on bucket or object.

storeSetMetadata(url,Struct); → returns void

Argument Reference

url string
Required

Amazon S3 URLs (bucket or object).

region struct
Required

Represents the metadata. See Standard keys for a list of standard keys in metadata. You can also have custom metadata apart from the standard ones.

Examples
Sample code invoking the storeSetMetadata function

<cfscript>
	mydate = #now()#;
	hello = structNew();
	hello.color = 'grey';
</cfscript>
<cfset dir = 's3://mycfbucket'>
<cffile action='write' file='#dir#/hello5.txt' output='Sample s3 text'>
<cfset storeSetMetadata('#dir#/hello5.txt','#hello#')>
<cfset test = storeGetMetadata('#dir#/hello5.txt')>
<cfdump var='#test#'>

Signup for cfbreak to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.

Fork me on GitHub