docs: function (date, format, utc) {
          utc = utc || false;
          var fullYear, month, day, d, hour, minute, second, millisecond;
          if (utc) {
              fullYear = date.getUTCFullYear();
              month = date.getUTCMonth();
              day = date.getUTCDay();
              d = date.getUTCDate();
              hour = date.getUTCHours();
              minute = date.getUTCMinutes();
              second = date.getUTCSeconds();
              millisecond = date.getUTCMilliseconds();
          } else {
              fullYear = date.getFullYear();
              month = date.getMonth();
              d = date.getDate();
              day = date.getDay();
              hour = date.getHours();
              minute = date.getMinutes();
              second = date.getSeconds();
              millisecond = date.getMilliseconds();
          }
          return format.replace(/([A-Za-z])\1*/g, function (match, options) {
              var s, pad, h,
                  c = match.charAt(0),
                  l = match.length;
              if (c === 'd') {
                  s = "" + d;
                  pad = true;
              } else if (c === "H" && !s) {
                  s = "" + hour;
                  pad = true;
              } else if (c === 'm' && !s) {
                  s = "" + minute;
                  pad = true;
              } else if (c === 's') {
                  if (!s) {
                      s = "" + second;
                  }
                  pad = true;
              } else if (c === "G") {
                  s = ((l < 4) ? eraAbbr : eraNames)[fullYear < 0 ? 0 : 1];
              } else if (c === "y") {
                  s = fullYear;
                  if (l > 1) {
                      if (l === 2) {
                          s = getString().truncate("" + s, 2, true);
                      } else {
                          pad = true;
                      }
                  }
              } else if (c.toUpperCase() === "Q") {
                  s = ceil((month + 1) / 3);
                  pad = true;
              } else if (c === "M") {
                  if (l < 3) {
                      s = month + 1;
                      pad = true;
                  } else {
                      s = (l === 3 ? monthAbbr : monthNames)[month];
                  }
              } else if (c === "w") {
                  s = getWeekOfYear(date, 0, utc);
                  pad = true;
              } else if (c === "D") {
                  s = getDayOfYear(date, utc);
                  pad = true;
              } else if (c === "E") {
                  if (l < 3) {
                      s = day + 1;
                      pad = true;
                  } else {
                      s = (l === 3 ? dayAbbr : dayNames)[day];
                  }
              } else if (c === 'a') {
                  s = (hour < 12) ? 'AM' : 'PM';
              } else if (c === "h") {
                  s = (hour % 12) || 12;
                  pad = true;
              } else if (c === "K") {
                  s = (hour % 12);
                  pad = true;
              } else if (c === "k") {
                  s = hour || 24;
                  pad = true;
              } else if (c === "S") {
                  s = round(millisecond * pow(10, l - 3));
                  pad = true;
              } else if (c === "z" || c === "v" || c === "Z") {
                  s = getTimezoneName(date);
                  if ((c === "z" || c === "v") && !s) {
                      l = 4;
                  }
                  if (!s || c === "Z") {
                      var offset = date.getTimezoneOffset();
                      var tz = [
                          (offset >= 0 ? "-" : "+"),
                          getString().pad(floor(abs(offset) / 60), 2, "0"),
                          getString().pad(abs(offset) % 60, 2, "0")
                      ];
                      if (l === 4) {
                          tz.splice(0, 0, "GMT");
                          tz.splice(3, 0, ":");
                      }
                      s = tz.join("");
                  }
              } else {
                  s = match;
              }
              if (pad) {
                  s = getString().pad(s, l, '0');
              }
              return s;
          });
      }