Renders with {"code": int}.

@param code the specified code
@return this context
760921
public RequestContext renderCode(final int code) {
        if (renderer instanceof JsonRenderer) {
            final JsonRenderer r = (JsonRenderer) renderer;

            final JSONObject ret = r.getJSONObject();
            ret.put(Keys.CODE, code);
        }

        return this;
    }
250747
public function renderCode($code, $semicolon = true, $newLine = true)
    {
        if ($semicolon) {
            $code .= ';';
        }

        return $this->renderLine($code, $newLine);
    }
104669
public static HttpResponseStatus valueOf(int code) {
    switch (code) {
      case 100:
        return CONTINUE;
      case 101:
        return SWITCHING_PROTOCOLS;
      case 102:
        return PROCESSING;
      case 200:
        return OK;
      case 201:
        return CREATED;
      case 202:
        return ACCEPTED;
      case 203:
        return NON_AUTHORITATIVE_INFORMATION;
      case 204:
        return NO_CONTENT;
      case 205:
        return RESET_CONTENT;
      case 206:
        return PARTIAL_CONTENT;
      case 207:
        return MULTI_STATUS;
      case 300:
        return MULTIPLE_CHOICES;
      case 301:
        return MOVED_PERMANENTLY;
      case 302:
        return FOUND;
      case 303:
        return SEE_OTHER;
      case 304:
        return NOT_MODIFIED;
      case 305:
        return USE_PROXY;
      case 307:
        return TEMPORARY_REDIRECT;
      case 400:
        return BAD_REQUEST;
      case 401:
        return UNAUTHORIZED;
      case 402:
        return PAYMENT_REQUIRED;
      case 403:
        return FORBIDDEN;
      case 404:
        return NOT_FOUND;
      case 405:
        return METHOD_NOT_ALLOWED;
      case 406:
        return NOT_ACCEPTABLE;
      case 407:
        return PROXY_AUTHENTICATION_REQUIRED;
      case 408:
        return REQUEST_TIMEOUT;
      case 409:
        return CONFLICT;
      case 410:
        return GONE;
      case 411:
        return LENGTH_REQUIRED;
      case 412:
        return PRECONDITION_FAILED;
      case 413:
        return REQUEST_ENTITY_TOO_LARGE;
      case 414:
        return REQUEST_URI_TOO_LONG;
      case 415:
        return UNSUPPORTED_MEDIA_TYPE;
      case 416:
        return REQUESTED_RANGE_NOT_SATISFIABLE;
      case 417:
        return EXPECTATION_FAILED;
      case 422:
        return UNPROCESSABLE_ENTITY;
      case 423:
        return LOCKED;
      case 424:
        return FAILED_DEPENDENCY;
      case 425:
        return UNORDERED_COLLECTION;
      case 426:
        return UPGRADE_REQUIRED;
      case 500:
        return INTERNAL_SERVER_ERROR;
      case 501:
        return NOT_IMPLEMENTED;
      case 502:
        return BAD_GATEWAY;
      case 503:
        return SERVICE_UNAVAILABLE;
      case 504:
        return GATEWAY_TIMEOUT;
      case 505:
        return HTTP_VERSION_NOT_SUPPORTED;
      case 506:
        return VARIANT_ALSO_NEGOTIATES;
      case 507:
        return INSUFFICIENT_STORAGE;
      case 510:
        return NOT_EXTENDED;
    }

    final String reasonPhrase;

    if (code < 100) {
      reasonPhrase = "Unknown Status";
    } else if (code < 200) {
      reasonPhrase = "Informational";
    } else if (code < 300) {
      reasonPhrase = "Successful";
    } else if (code < 400) {
      reasonPhrase = "Redirection";
    } else if (code < 500) {
      reasonPhrase = "Client Error";
    } else if (code < 600) {
      reasonPhrase = "Server Error";
    } else {
      reasonPhrase = "Unknown Status";
    }

    return new HttpResponseStatus(code, reasonPhrase + " (" + code + ')');
  }
1227228
def render_code(self):
        
        tmp_dir = os.environ.get('TMP','')
        view_code = os.path.join(tmp_dir,'view.enaml')
        if os.path.exists(view_code):
            try:
                with open(view_code) as f:
                    return f.read()
            except:
                pass
        return DEFAULT_CODE
841245
private static void renderExpr(boolean first, CodeBlock.Builder code, Node<PluralType> expr) {
    Iterator<Node<PluralType>> iter = expr.asStruct().nodes().iterator();

    // Parse out the two forms of operand expressions we support:
    //
    //    n = <rangelist>
    //    n % m = <rangelist>
    //
    Atom<PluralType> operand = iter.next().asAtom();
    Atom<PluralType> modop = null;
    Atom<PluralType> relop = iter.next().asAtom();
    if (relop.type() == PluralType.MODOP) {
      modop = relop;
      relop = iter.next().asAtom();
    }

    String var = (String)operand.value();
    List<Node<PluralType>> rangeList = iter.next().asStruct().nodes();

    boolean decimalsZero = false;
    if (var.equals("n") && modop != null) {
      // We're applying mod to the 'n' operand, we must also ensure that
      // decimal value == 0.
      decimalsZero = true;
    }
    
    // If this is the first expression, define the variable; otherwise reuse it.
    String fmt = "zz = o.$L()";
    if (first) {
      fmt = "long " + fmt;
    }

    // Mod operations modify the operand before assignment.
    if (modop != null) {
      fmt += " % $LL";
    }

    // Emit the expression.
    if (modop != null) {
      code.addStatement(fmt, var, (int)modop.value());
    } else {
      code.addStatement(fmt, var);
    }

    renderExpr(code, rangeList, relop.value().equals("="), decimalsZero);
  }
36728
public String render(String content, RenderContext context) {
    init();
    FilterContext filterContext = new BaseFilterContext();
    filterContext.setRenderContext(context);
    return fp.filter(content, filterContext);
  }
1026981
function evaluate(code) {
  const context = {
    module: {
      exports: {},
    },
  };

  // eslint-disable-next-line no-new-func
  const renderFunction = new Function('module', code);
  renderFunction(context.module);

  const template = context.module.exports;

  return template;
}
892968
function(code)
  {
    var lineNumbers = [],
        lines = this.lines,
        firstLine = parseInt(this.opts.firstLine || 1),
        i,
        l
        ;

    for (i = 0, l = lines.length; i < l; i++)
      lineNumbers.push(i + firstLine);

    return lineNumbers;
  }
570649
public StringBuilder relatedTo(HttpCode<TRANS, ?> code, StringBuilder sb) {
			boolean first = true;
			for(Pair<String, Pair<HttpCode<TRANS, ?>, List<Pair<String, Object>>>> pair : types) {
				if(code==null || pair.y.x == code) {
					if(first) {
						first = false;
					} else {
						sb.append(',');
					}
					sb.append(pair.x);
					for(Pair<String,Object> prop : pair.y.y) {
						// Don't print "Q".  it's there for internal use, but it is only meaningful for "Accepts"
						if(!prop.x.equals(Q) || !prop.y.equals(1f) ) {
							sb.append(';');
							sb.append(prop.x);
							sb.append('=');
							sb.append(prop.y);
						}
					}
				}
			}
			return sb;
		}
1064752
function renderWithIntl (node, { context, childContextTypes } = {}) {
    const intlProvider = new IntlProvider({locale: locale, messages }, {});
    const { intl } = intlProvider.getChildContext();
    return render(React.cloneElement(node, { intl }), {
        context: Object.assign({}, context, {intl}),
        childContextTypes: Object.assign({}, { intl: intlShape }, childContextTypes)
    });
}
481172
private ImageFormat getImageFormatForCode(String code) {
        if (code == null || imageFormats == null) {
            return null;
        }
        for (ImageFormat oneImageFormat : imageFormats) {
            if (code.equalsIgnoreCase(oneImageFormat.getCode())) {
                return oneImageFormat;
            }
        }
        return null;
    }
498415
public static JsScopeUiDatePickerOnChangeEvent quickScope(final CharSequence javascriptCode)
	{
		return new JsScopeUiDatePickerOnChangeEvent()
		{
			private static final long serialVersionUID = 1L;

			@Override
			protected void execute(JsScopeContext scopeContext)
			{
				scopeContext.append(javascriptCode);
			}

		};
	}
868471
def render(self, code):
        
        if self._callbacks['initialize'] is not None:
            self._callbacks['initialize'](code)
        ypos = 1.0
        for cc, line in enumerate(code):
            """
            Pack line to list give better gfx result, otherwise in can
            result in aliasing gaps
            '11010111' -> [2, -1, 1, -1, 3]
            """
            line += ' '
            c = 1
            mlist = []
            for i in range(0, len(line) - 1):
                if line[i] == line[i+1]:
                    c += 1
                else:
                    if line[i] == "1":
                        mlist.append(c)
                    else:
                        mlist.append(-c)
                    c = 1
            # Left quiet zone is x startposition
            xpos = self.quiet_zone
            bxs = xpos  # x start of barcode
            for mod in mlist:
                if mod < 1:
                    color = self.background
                else:
                    color = self.foreground
                # remove painting for background colored tiles?
                self._callbacks['paint_module'](
                    xpos, ypos, self.module_width * abs(mod), color
                )
                xpos += self.module_width * abs(mod)
            bxe = xpos
            # Add right quiet zone to every line, except last line,
            # quiet zone already provided with background,
            # should it be removed complety?
            if (cc + 1) != len(code):
                self._callbacks['paint_module'](
                    xpos, ypos, self.quiet_zone, self.background
                )
            ypos += self.module_height
        if self.text and self._callbacks['paint_text'] is not None:
            ypos += self.text_distance
            if self.center_text:
                # better center position for text
                xpos = bxs + ((bxe - bxs) / 2.0)
            else:
                xpos = bxs
            self._callbacks['paint_text'](xpos, ypos)
        return self._callbacks['finish']()
666545
private void drawString(Graphics2D g, String code) {
		// 抗锯齿
		g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
		// 创建字体
		g.setFont(this.font);

		// 文字
		int minY = GraphicsUtil.getMinY(g);
		if(minY < 0) {
			minY = this.height -1;
		}
		
		final int len = this.generator.getLength();
		int charWidth = width / len;
		for (int i = 0; i < len; i++) {
			// 产生随机的颜色值，让输出的每个字符的颜色值都将不同。
			g.setColor(ImgUtil.randomColor());
			g.drawString(String.valueOf(code.charAt(i)), i * charWidth, RandomUtil.randomInt(minY, this.height));
		}
	}
977078
public PropertyComponent getProperty(String code) {
    for (PropertyComponent pd : getProperty()) {
      if (pd.getCode().equalsIgnoreCase(code))
        return pd;
    }
    return null;
  }
1255889
@NotNull
    @ObjectiveCName("validateCodeCommand:")
    public Command<AuthState> validateCode(final String code) {
        return modules.getAuthModule().requestValidateCode(code);
    }
1337189
public JsStatement append(CharSequence javascriptCode)
	{
		JsStatement statement = new JsStatement();
		statements.add(statement);
		return statement.append(javascriptCode);
	}