code: function(context) {
          var node = this.createElementDefaultNS("FormatList");
          for (var i=0, len=context.formats.length; i<len; i++) {
              var format = context.formats[i];
              node.appendChild(this.createElementDefaultNS(
                  "Format",
                  format.value,
                  (format.current && format.current == true) ?
                      {current: "1"} : null
              ));
          }
  
          return node;
      }
docs: Method: write_wmc_FormatList
  Create a FormatList node given a layer context.
  
  Parameters:
  context - {Object} Layer context object.
  
  Returns:
  {Element} A WMC FormatList element node.