本文整理了Java中org.apache.coyote.Response.finish
方法的一些代码示例,展示了Response.finish
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Response.finish
方法的具体详情如下:
包路径:org.apache.coyote.Response
类名称:Response
方法名:finish
暂无
代码示例来源:origin: codefollower/Tomcat-Research
private void finish() {
if (!response.isCommitted()) {
response.action(ActionCode.COMMIT, response);
}
if (finished)
return;
finished = true;
response.finish();
}
代码示例来源:origin: org.glassfish.metro/webservices-extra
res.finish();
代码示例来源:origin: com.ovea.tajin.server/tajin-server-tomcat7
/**
* Close the output buffer. This tries to calculate the response size if
* the response has not been committed yet.
*
* @throws IOException An underlying IOException occurred
*/
@Override
public void close()
throws IOException {
if (closed)
return;
if (suspended)
return;
if ((!coyoteResponse.isCommitted())
&& (coyoteResponse.getContentLengthLong() == -1)) {
// If this didn't cause a commit of the response, the final content
// length can be calculated
if (!coyoteResponse.isCommitted()) {
coyoteResponse.setContentLength(bb.getLength());
}
}
doFlush(false);
closed = true;
coyoteResponse.finish();
}
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
/**
* Close the output buffer. This tries to calculate the response size if
* the response has not been committed yet.
*
* @throws IOException An underlying IOException occurred
*/
@Override
public void close()
throws IOException {
if (closed)
return;
if (suspended)
return;
if ((!coyoteResponse.isCommitted())
&& (coyoteResponse.getContentLengthLong() == -1)) {
// If this didn't cause a commit of the response, the final content
// length can be calculated
if (!coyoteResponse.isCommitted()) {
coyoteResponse.setContentLength(bb.getLength());
}
}
doFlush(false);
closed = true;
coyoteResponse.finish();
}
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
/**
* Close the output buffer. This tries to calculate the response size if
* the response has not been committed yet.
*
* @throws IOException An underlying IOException occurred
*/
@Override
public void close()
throws IOException {
if (closed)
return;
if (suspended)
return;
if ((!coyoteResponse.isCommitted())
&& (coyoteResponse.getContentLengthLong() == -1)) {
// If this didn't cause a commit of the response, the final content
// length can be calculated
if (!coyoteResponse.isCommitted()) {
coyoteResponse.setContentLength(bb.getLength());
}
}
doFlush(false);
closed = true;
coyoteResponse.finish();
}
代码示例来源:origin: jboss.remoting/jboss-remoting
closed = true;
coyoteResponse.finish();
代码示例来源:origin: tomcat/catalina
/**
* Close the output buffer. This tries to calculate the response size if
* the response has not been committed yet.
*
* @throws IOException An underlying IOException occurred
*/
public void close()
throws IOException {
if (closed)
return;
if (suspended)
return;
if ((!coyoteResponse.isCommitted())
&& (coyoteResponse.getContentLengthLong() == -1)) {
// Flushing the char buffer
if (state == CHAR_STATE) {
cb.flushBuffer();
state = BYTE_STATE;
}
// If this didn't cause a commit of the response, the final content
// length can be calculated
if (!coyoteResponse.isCommitted()) {
coyoteResponse.setContentLength(bb.getLength());
}
}
doFlush(false);
closed = true;
coyoteResponse.finish();
}
代码示例来源:origin: jboss.web/jbossweb
/**
* Close the output buffer. This tries to calculate the response size if
* the response has not been committed yet.
*
* @throws IOException An underlying IOException occurred
*/
public void close()
throws IOException {
if (closed)
return;
if (suspended)
return;
// If there are chars, flush all of them to the byte buffer now as bytes are used to
// calculate the content-length (if everything fits into the byte buffer, of course).
if (cb.getLength() > 0) {
cb.flushBuffer();
}
if ((!coyoteResponse.isCommitted())
&& (coyoteResponse.getContentLengthLong() == -1)) {
// If this didn't cause a commit of the response, the final content
// length can be calculated
if (!coyoteResponse.isCommitted()) {
coyoteResponse.setContentLength(bb.getLength());
}
}
doFlush(false);
closed = true;
coyoteResponse.finish();
}
代码示例来源:origin: org.apache.catalina/com.springsource.org.apache.catalina
req.inputBuffer.close();
coyoteResponse.finish();
代码示例来源:origin: org.apache.geronimo.ext.tomcat/catalina
req.inputBuffer.close();
coyoteResponse.finish();
代码示例来源:origin: codefollower/Tomcat-Research
req.inputBuffer.close();
coyoteResponse.finish();
代码示例来源:origin: org.jboss.web/jbossweb
closed = true;
coyoteResponse.finish();
代码示例来源:origin: org.apache.coyote.springsource/com.springsource.org.apache.coyote.springsource
res.finish();
内容来源于网络,如有侵权,请联系作者删除!