 
+_ = require 'underscore'
 fs = require 'fs'
 url = require 'url'
 http = require 'http'

  handler: (req, res) ->
    {pathname, query} = url.parse req.url, true
    readData req, (data) =>
      
      if @opt.verbose
        s = "[S3Server] #{req.method} #{req.url}"

  
  get: (bucket, k) ->
    @_bucketItems(bucket)[k] or null
  
  keysInBucket: (bucket) ->
    _.keys @_bucketItems(bucket)
  
  list: (bucket, GET) ->
    
