/usr/share/doc/libservlet3.0-java/api/javax/servlet/http/HttpServletResponse.html is in libservlet3.0-java-doc 7.0.78-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html>
<head>
<!-- Generated by javadoc -->
<title>HttpServletResponse (Tomcat API Documentation)</title>
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="HttpServletResponse (Tomcat API Documentation)";
}
}
catch(err) {
}
//-->
var methods = {"i0":6,"i1":6,"i2":6,"i3":6,"i4":6,"i5":38,"i6":6,"i7":38,"i8":6,"i9":6,"i10":6,"i11":6,"i12":6,"i13":6,"i14":6,"i15":6,"i16":6,"i17":6,"i18":6,"i19":6,"i20":38};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"],32:["t6","Deprecated Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../javax/servlet/http/HttpServletRequestWrapper.html" title="class in javax.servlet.http"><span class="typeNameLink">Prev Class</span></a></li>
<li><a href="../../../javax/servlet/http/HttpServletResponseWrapper.html" title="class in javax.servlet.http"><span class="typeNameLink">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../index.html?javax/servlet/http/HttpServletResponse.html" target="_top">Frames</a></li>
<li><a href="HttpServletResponse.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary: </li>
<li>Nested | </li>
<li><a href="#field.summary">Field</a> | </li>
<li>Constr | </li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail: </li>
<li><a href="#field.detail">Field</a> | </li>
<li>Constr | </li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">javax.servlet.http</div>
<h2 title="Interface HttpServletResponse" class="title">Interface HttpServletResponse</h2>
</div>
<div class="contentContainer">
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Superinterfaces:</dt>
<dd><a href="../../../javax/servlet/ServletResponse.html" title="interface in javax.servlet">ServletResponse</a></dd>
</dl>
<dl>
<dt>All Known Implementing Classes:</dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponseWrapper.html" title="class in javax.servlet.http">HttpServletResponseWrapper</a></dd>
</dl>
<hr>
<br>
<pre>public interface <span class="typeNameLabel">HttpServletResponse</span>
extends <a href="../../../javax/servlet/ServletResponse.html" title="interface in javax.servlet">ServletResponse</a></pre>
<div class="block">Extends the <a href="../../../javax/servlet/ServletResponse.html" title="interface in javax.servlet"><code>ServletResponse</code></a> interface to provide HTTP-specific
functionality in sending a response. For example, it has methods to access
HTTP headers and cookies.
<p>
The servlet container creates an <code>HttpServletResponse</code> object and
passes it as an argument to the servlet's service methods (<code>doGet</code>, <code>doPost</code>, etc).</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/ServletResponse.html" title="interface in javax.servlet"><code>ServletResponse</code></a></dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.summary">
<!-- -->
</a>
<h3>Field Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd"> </span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_ACCEPTED">SC_ACCEPTED</a></span></code>
<div class="block">Status code (202) indicating that a request was accepted for processing,
but was not completed.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_BAD_GATEWAY">SC_BAD_GATEWAY</a></span></code>
<div class="block">Status code (502) indicating that the HTTP server received an invalid
response from a server it consulted when acting as a proxy or gateway.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_BAD_REQUEST">SC_BAD_REQUEST</a></span></code>
<div class="block">Status code (400) indicating the request sent by the client was
syntactically incorrect.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_CONFLICT">SC_CONFLICT</a></span></code>
<div class="block">Status code (409) indicating that the request could not be completed due
to a conflict with the current state of the resource.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_CONTINUE">SC_CONTINUE</a></span></code>
<div class="block">Status code (100) indicating the client can continue.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_CREATED">SC_CREATED</a></span></code>
<div class="block">Status code (201) indicating the request succeeded and created a new
resource on the server.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_EXPECTATION_FAILED">SC_EXPECTATION_FAILED</a></span></code>
<div class="block">Status code (417) indicating that the server could not meet the
expectation given in the Expect request header.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_FORBIDDEN">SC_FORBIDDEN</a></span></code>
<div class="block">Status code (403) indicating the server understood the request but
refused to fulfill it.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_FOUND">SC_FOUND</a></span></code>
<div class="block">Status code (302) indicating that the resource reside temporarily under a
different URI.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_GATEWAY_TIMEOUT">SC_GATEWAY_TIMEOUT</a></span></code>
<div class="block">Status code (504) indicating that the server did not receive a timely
response from the upstream server while acting as a gateway or proxy.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_GONE">SC_GONE</a></span></code>
<div class="block">Status code (410) indicating that the resource is no longer available at
the server and no forwarding address is known.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_HTTP_VERSION_NOT_SUPPORTED">SC_HTTP_VERSION_NOT_SUPPORTED</a></span></code>
<div class="block">Status code (505) indicating that the server does not support or refuses
to support the HTTP protocol version that was used in the request
message.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_INTERNAL_SERVER_ERROR">SC_INTERNAL_SERVER_ERROR</a></span></code>
<div class="block">Status code (500) indicating an error inside the HTTP server which
prevented it from fulfilling the request.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_LENGTH_REQUIRED">SC_LENGTH_REQUIRED</a></span></code>
<div class="block">Status code (411) indicating that the request cannot be handled without a
defined <code><em>Content-Length</em></code>.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_METHOD_NOT_ALLOWED">SC_METHOD_NOT_ALLOWED</a></span></code>
<div class="block">Status code (405) indicating that the method specified in the
<code><em>Request-Line</em></code> is not allowed for the resource
identified by the <code><em>Request-URI</em></code>.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_MOVED_PERMANENTLY">SC_MOVED_PERMANENTLY</a></span></code>
<div class="block">Status code (301) indicating that the resource has permanently moved to a
new location, and that future references should use a new URI with their
requests.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_MOVED_TEMPORARILY">SC_MOVED_TEMPORARILY</a></span></code>
<div class="block">Status code (302) indicating that the resource has temporarily moved to
another location, but that future references should still use the
original URI to access the resource.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_MULTIPLE_CHOICES">SC_MULTIPLE_CHOICES</a></span></code>
<div class="block">Status code (300) indicating that the requested resource corresponds to
any one of a set of representations, each with its own specific location.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_NO_CONTENT">SC_NO_CONTENT</a></span></code>
<div class="block">Status code (204) indicating that the request succeeded but that there
was no new information to return.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_NON_AUTHORITATIVE_INFORMATION">SC_NON_AUTHORITATIVE_INFORMATION</a></span></code>
<div class="block">Status code (203) indicating that the meta information presented by the
client did not originate from the server.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_NOT_ACCEPTABLE">SC_NOT_ACCEPTABLE</a></span></code>
<div class="block">Status code (406) indicating that the resource identified by the request
is only capable of generating response entities which have content
characteristics not acceptable according to the accept headers sent in
the request.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_NOT_FOUND">SC_NOT_FOUND</a></span></code>
<div class="block">Status code (404) indicating that the requested resource is not
available.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_NOT_IMPLEMENTED">SC_NOT_IMPLEMENTED</a></span></code>
<div class="block">Status code (501) indicating the HTTP server does not support the
functionality needed to fulfill the request.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_NOT_MODIFIED">SC_NOT_MODIFIED</a></span></code>
<div class="block">Status code (304) indicating that a conditional GET operation found that
the resource was available and not modified.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_OK">SC_OK</a></span></code>
<div class="block">Status code (200) indicating the request succeeded normally.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_PARTIAL_CONTENT">SC_PARTIAL_CONTENT</a></span></code>
<div class="block">Status code (206) indicating that the server has fulfilled the partial
GET request for the resource.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_PAYMENT_REQUIRED">SC_PAYMENT_REQUIRED</a></span></code>
<div class="block">Status code (402) reserved for future use.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_PRECONDITION_FAILED">SC_PRECONDITION_FAILED</a></span></code>
<div class="block">Status code (412) indicating that the precondition given in one or more
of the request-header fields evaluated to false when it was tested on the
server.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_PROXY_AUTHENTICATION_REQUIRED">SC_PROXY_AUTHENTICATION_REQUIRED</a></span></code>
<div class="block">Status code (407) indicating that the client <em>MUST</em> first
authenticate itself with the proxy.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_REQUEST_ENTITY_TOO_LARGE">SC_REQUEST_ENTITY_TOO_LARGE</a></span></code>
<div class="block">Status code (413) indicating that the server is refusing to process the
request because the request entity is larger than the server is willing
or able to process.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_REQUEST_TIMEOUT">SC_REQUEST_TIMEOUT</a></span></code>
<div class="block">Status code (408) indicating that the client did not produce a request
within the time that the server was prepared to wait.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_REQUEST_URI_TOO_LONG">SC_REQUEST_URI_TOO_LONG</a></span></code>
<div class="block">Status code (414) indicating that the server is refusing to service the
request because the <code><em>Request-URI</em></code> is longer than the
server is willing to interpret.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_REQUESTED_RANGE_NOT_SATISFIABLE">SC_REQUESTED_RANGE_NOT_SATISFIABLE</a></span></code>
<div class="block">Status code (416) indicating that the server cannot serve the requested
byte range.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_RESET_CONTENT">SC_RESET_CONTENT</a></span></code>
<div class="block">Status code (205) indicating that the agent <em>SHOULD</em> reset the
document view which caused the request to be sent.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_SEE_OTHER">SC_SEE_OTHER</a></span></code>
<div class="block">Status code (303) indicating that the response to the request can be
found under a different URI.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_SERVICE_UNAVAILABLE">SC_SERVICE_UNAVAILABLE</a></span></code>
<div class="block">Status code (503) indicating that the HTTP server is temporarily
overloaded, and unable to handle the request.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_SWITCHING_PROTOCOLS">SC_SWITCHING_PROTOCOLS</a></span></code>
<div class="block">Status code (101) indicating the server is switching protocols according
to Upgrade header.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_TEMPORARY_REDIRECT">SC_TEMPORARY_REDIRECT</a></span></code>
<div class="block">Status code (307) indicating that the requested resource resides
temporarily under a different URI.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_UNAUTHORIZED">SC_UNAUTHORIZED</a></span></code>
<div class="block">Status code (401) indicating that the request requires HTTP
authentication.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_UNSUPPORTED_MEDIA_TYPE">SC_UNSUPPORTED_MEDIA_TYPE</a></span></code>
<div class="block">Status code (415) indicating that the server is refusing to service the
request because the entity of the request is in a format not supported by
the requested resource for the requested method.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#SC_USE_PROXY">SC_USE_PROXY</a></span></code>
<div class="block">Status code (305) indicating that the requested resource <em>MUST</em> be
accessed through the proxy given by the <code><em>Location</em></code>
field.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd"> </span></span><span id="t6" class="tableTab"><span><a href="javascript:show(32);">Deprecated Methods</a></span><span class="tabEnd"> </span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#addCookie-javax.servlet.http.Cookie-">addCookie</a></span>(<a href="../../../javax/servlet/http/Cookie.html" title="class in javax.servlet.http">Cookie</a> cookie)</code>
<div class="block">Adds the specified cookie to the response.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#addDateHeader-java.lang.String-long-">addDateHeader</a></span>(java.lang.String name,
long date)</code>
<div class="block">Adds a response header with the given name and date-value.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#addHeader-java.lang.String-java.lang.String-">addHeader</a></span>(java.lang.String name,
java.lang.String value)</code>
<div class="block">Adds a response header with the given name and value.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#addIntHeader-java.lang.String-int-">addIntHeader</a></span>(java.lang.String name,
int value)</code>
<div class="block">Adds a response header with the given name and integer value.</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#containsHeader-java.lang.String-">containsHeader</a></span>(java.lang.String name)</code>
<div class="block">Returns a boolean indicating whether the named response header has
already been set.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#encodeRedirectUrl-java.lang.String-">encodeRedirectUrl</a></span>(java.lang.String url)</code>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>
<div class="block"><span class="deprecationComment">As of version 2.1, use encodeRedirectURL(String url) instead</span></div>
</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#encodeRedirectURL-java.lang.String-">encodeRedirectURL</a></span>(java.lang.String url)</code>
<div class="block">Encodes the specified URL for use in the <code>sendRedirect</code> method
or, if encoding is not needed, returns the URL unchanged.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#encodeUrl-java.lang.String-">encodeUrl</a></span>(java.lang.String url)</code>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>
<div class="block"><span class="deprecationComment">As of version 2.1, use encodeURL(String url) instead</span></div>
</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#encodeURL-java.lang.String-">encodeURL</a></span>(java.lang.String url)</code>
<div class="block">Encodes the specified URL by including the session ID in it, or, if
encoding is not needed, returns the URL unchanged.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#getHeader-java.lang.String-">getHeader</a></span>(java.lang.String name)</code>
<div class="block">Return the value for the specified header, or <code>null</code> if this
header has not been set.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>java.util.Collection<java.lang.String></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#getHeaderNames--">getHeaderNames</a></span>()</code>
<div class="block">Return an Iterable of all the header names set for this response.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>java.util.Collection<java.lang.String></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#getHeaders-java.lang.String-">getHeaders</a></span>(java.lang.String name)</code>
<div class="block">Return a Collection of all the header values associated with the
specified header name.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#getStatus--">getStatus</a></span>()</code>
<div class="block">Return the HTTP status code associated with this Response.</div>
</td>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#sendError-int-">sendError</a></span>(int sc)</code>
<div class="block">Sends an error response to the client using the specified status code and
clears the buffer.</div>
</td>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#sendError-int-java.lang.String-">sendError</a></span>(int sc,
java.lang.String msg)</code>
<div class="block">Sends an error response to the client using the specified status code and
clears the output buffer.</div>
</td>
</tr>
<tr id="i15" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#sendRedirect-java.lang.String-">sendRedirect</a></span>(java.lang.String location)</code>
<div class="block">Sends a temporary redirect response to the client using the specified
redirect location URL.</div>
</td>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#setDateHeader-java.lang.String-long-">setDateHeader</a></span>(java.lang.String name,
long date)</code>
<div class="block">Sets a response header with the given name and date-value.</div>
</td>
</tr>
<tr id="i17" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#setHeader-java.lang.String-java.lang.String-">setHeader</a></span>(java.lang.String name,
java.lang.String value)</code>
<div class="block">Sets a response header with the given name and value.</div>
</td>
</tr>
<tr id="i18" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#setIntHeader-java.lang.String-int-">setIntHeader</a></span>(java.lang.String name,
int value)</code>
<div class="block">Sets a response header with the given name and integer value.</div>
</td>
</tr>
<tr id="i19" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#setStatus-int-">setStatus</a></span>(int sc)</code>
<div class="block">Sets the status code for this response.</div>
</td>
</tr>
<tr id="i20" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/servlet/http/HttpServletResponse.html#setStatus-int-java.lang.String-">setStatus</a></span>(int sc,
java.lang.String sm)</code>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>
<div class="block"><span class="deprecationComment">As of version 2.1, due to ambiguous meaning of the message
parameter. To set a status code use
<code>setStatus(int)</code>, to send an error with a
description use <code>sendError(int, String)</code>.</span></div>
</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.javax.servlet.ServletResponse">
<!-- -->
</a>
<h3>Methods inherited from interface javax.servlet.<a href="../../../javax/servlet/ServletResponse.html" title="interface in javax.servlet">ServletResponse</a></h3>
<code><a href="../../../javax/servlet/ServletResponse.html#flushBuffer--">flushBuffer</a>, <a href="../../../javax/servlet/ServletResponse.html#getBufferSize--">getBufferSize</a>, <a href="../../../javax/servlet/ServletResponse.html#getCharacterEncoding--">getCharacterEncoding</a>, <a href="../../../javax/servlet/ServletResponse.html#getContentType--">getContentType</a>, <a href="../../../javax/servlet/ServletResponse.html#getLocale--">getLocale</a>, <a href="../../../javax/servlet/ServletResponse.html#getOutputStream--">getOutputStream</a>, <a href="../../../javax/servlet/ServletResponse.html#getWriter--">getWriter</a>, <a href="../../../javax/servlet/ServletResponse.html#isCommitted--">isCommitted</a>, <a href="../../../javax/servlet/ServletResponse.html#reset--">reset</a>, <a href="../../../javax/servlet/ServletResponse.html#resetBuffer--">resetBuffer</a>, <a href="../../../javax/servlet/ServletResponse.html#setBufferSize-int-">setBufferSize</a>, <a href="../../../javax/servlet/ServletResponse.html#setCharacterEncoding-java.lang.String-">setCharacterEncoding</a>, <a href="../../../javax/servlet/ServletResponse.html#setContentLength-int-">setContentLength</a>, <a href="../../../javax/servlet/ServletResponse.html#setContentType-java.lang.String-">setContentType</a>, <a href="../../../javax/servlet/ServletResponse.html#setLocale-java.util.Locale-">setLocale</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.detail">
<!-- -->
</a>
<h3>Field Detail</h3>
<a name="SC_CONTINUE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_CONTINUE</h4>
<pre>static final int SC_CONTINUE</pre>
<div class="block">Status code (100) indicating the client can continue.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_CONTINUE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_SWITCHING_PROTOCOLS">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_SWITCHING_PROTOCOLS</h4>
<pre>static final int SC_SWITCHING_PROTOCOLS</pre>
<div class="block">Status code (101) indicating the server is switching protocols according
to Upgrade header.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_SWITCHING_PROTOCOLS">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_OK">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_OK</h4>
<pre>static final int SC_OK</pre>
<div class="block">Status code (200) indicating the request succeeded normally.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_OK">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_CREATED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_CREATED</h4>
<pre>static final int SC_CREATED</pre>
<div class="block">Status code (201) indicating the request succeeded and created a new
resource on the server.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_CREATED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_ACCEPTED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_ACCEPTED</h4>
<pre>static final int SC_ACCEPTED</pre>
<div class="block">Status code (202) indicating that a request was accepted for processing,
but was not completed.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_ACCEPTED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_NON_AUTHORITATIVE_INFORMATION">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_NON_AUTHORITATIVE_INFORMATION</h4>
<pre>static final int SC_NON_AUTHORITATIVE_INFORMATION</pre>
<div class="block">Status code (203) indicating that the meta information presented by the
client did not originate from the server.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_NON_AUTHORITATIVE_INFORMATION">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_NO_CONTENT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_NO_CONTENT</h4>
<pre>static final int SC_NO_CONTENT</pre>
<div class="block">Status code (204) indicating that the request succeeded but that there
was no new information to return.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_NO_CONTENT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_RESET_CONTENT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_RESET_CONTENT</h4>
<pre>static final int SC_RESET_CONTENT</pre>
<div class="block">Status code (205) indicating that the agent <em>SHOULD</em> reset the
document view which caused the request to be sent.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_RESET_CONTENT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_PARTIAL_CONTENT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_PARTIAL_CONTENT</h4>
<pre>static final int SC_PARTIAL_CONTENT</pre>
<div class="block">Status code (206) indicating that the server has fulfilled the partial
GET request for the resource.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_PARTIAL_CONTENT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_MULTIPLE_CHOICES">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_MULTIPLE_CHOICES</h4>
<pre>static final int SC_MULTIPLE_CHOICES</pre>
<div class="block">Status code (300) indicating that the requested resource corresponds to
any one of a set of representations, each with its own specific location.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_MULTIPLE_CHOICES">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_MOVED_PERMANENTLY">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_MOVED_PERMANENTLY</h4>
<pre>static final int SC_MOVED_PERMANENTLY</pre>
<div class="block">Status code (301) indicating that the resource has permanently moved to a
new location, and that future references should use a new URI with their
requests.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_MOVED_PERMANENTLY">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_MOVED_TEMPORARILY">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_MOVED_TEMPORARILY</h4>
<pre>static final int SC_MOVED_TEMPORARILY</pre>
<div class="block">Status code (302) indicating that the resource has temporarily moved to
another location, but that future references should still use the
original URI to access the resource. This definition is being retained
for backwards compatibility. SC_FOUND is now the preferred definition.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_MOVED_TEMPORARILY">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_FOUND">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_FOUND</h4>
<pre>static final int SC_FOUND</pre>
<div class="block">Status code (302) indicating that the resource reside temporarily under a
different URI. Since the redirection might be altered on occasion, the
client should continue to use the Request-URI for future
requests.(HTTP/1.1) To represent the status code (302), it is recommended
to use this variable.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_FOUND">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_SEE_OTHER">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_SEE_OTHER</h4>
<pre>static final int SC_SEE_OTHER</pre>
<div class="block">Status code (303) indicating that the response to the request can be
found under a different URI.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_SEE_OTHER">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_NOT_MODIFIED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_NOT_MODIFIED</h4>
<pre>static final int SC_NOT_MODIFIED</pre>
<div class="block">Status code (304) indicating that a conditional GET operation found that
the resource was available and not modified.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_NOT_MODIFIED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_USE_PROXY">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_USE_PROXY</h4>
<pre>static final int SC_USE_PROXY</pre>
<div class="block">Status code (305) indicating that the requested resource <em>MUST</em> be
accessed through the proxy given by the <code><em>Location</em></code>
field.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_USE_PROXY">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_TEMPORARY_REDIRECT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_TEMPORARY_REDIRECT</h4>
<pre>static final int SC_TEMPORARY_REDIRECT</pre>
<div class="block">Status code (307) indicating that the requested resource resides
temporarily under a different URI. The temporary URI <em>SHOULD</em> be
given by the <code><em>Location</em></code> field in the response.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_TEMPORARY_REDIRECT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_BAD_REQUEST">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_BAD_REQUEST</h4>
<pre>static final int SC_BAD_REQUEST</pre>
<div class="block">Status code (400) indicating the request sent by the client was
syntactically incorrect.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_BAD_REQUEST">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_UNAUTHORIZED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_UNAUTHORIZED</h4>
<pre>static final int SC_UNAUTHORIZED</pre>
<div class="block">Status code (401) indicating that the request requires HTTP
authentication.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_UNAUTHORIZED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_PAYMENT_REQUIRED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_PAYMENT_REQUIRED</h4>
<pre>static final int SC_PAYMENT_REQUIRED</pre>
<div class="block">Status code (402) reserved for future use.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_PAYMENT_REQUIRED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_FORBIDDEN">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_FORBIDDEN</h4>
<pre>static final int SC_FORBIDDEN</pre>
<div class="block">Status code (403) indicating the server understood the request but
refused to fulfill it.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_FORBIDDEN">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_NOT_FOUND">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_NOT_FOUND</h4>
<pre>static final int SC_NOT_FOUND</pre>
<div class="block">Status code (404) indicating that the requested resource is not
available.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_NOT_FOUND">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_METHOD_NOT_ALLOWED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_METHOD_NOT_ALLOWED</h4>
<pre>static final int SC_METHOD_NOT_ALLOWED</pre>
<div class="block">Status code (405) indicating that the method specified in the
<code><em>Request-Line</em></code> is not allowed for the resource
identified by the <code><em>Request-URI</em></code>.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_METHOD_NOT_ALLOWED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_NOT_ACCEPTABLE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_NOT_ACCEPTABLE</h4>
<pre>static final int SC_NOT_ACCEPTABLE</pre>
<div class="block">Status code (406) indicating that the resource identified by the request
is only capable of generating response entities which have content
characteristics not acceptable according to the accept headers sent in
the request.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_NOT_ACCEPTABLE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_PROXY_AUTHENTICATION_REQUIRED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_PROXY_AUTHENTICATION_REQUIRED</h4>
<pre>static final int SC_PROXY_AUTHENTICATION_REQUIRED</pre>
<div class="block">Status code (407) indicating that the client <em>MUST</em> first
authenticate itself with the proxy.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_PROXY_AUTHENTICATION_REQUIRED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_REQUEST_TIMEOUT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_REQUEST_TIMEOUT</h4>
<pre>static final int SC_REQUEST_TIMEOUT</pre>
<div class="block">Status code (408) indicating that the client did not produce a request
within the time that the server was prepared to wait.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_REQUEST_TIMEOUT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_CONFLICT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_CONFLICT</h4>
<pre>static final int SC_CONFLICT</pre>
<div class="block">Status code (409) indicating that the request could not be completed due
to a conflict with the current state of the resource.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_CONFLICT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_GONE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_GONE</h4>
<pre>static final int SC_GONE</pre>
<div class="block">Status code (410) indicating that the resource is no longer available at
the server and no forwarding address is known. This condition
<em>SHOULD</em> be considered permanent.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_GONE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_LENGTH_REQUIRED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_LENGTH_REQUIRED</h4>
<pre>static final int SC_LENGTH_REQUIRED</pre>
<div class="block">Status code (411) indicating that the request cannot be handled without a
defined <code><em>Content-Length</em></code>.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_LENGTH_REQUIRED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_PRECONDITION_FAILED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_PRECONDITION_FAILED</h4>
<pre>static final int SC_PRECONDITION_FAILED</pre>
<div class="block">Status code (412) indicating that the precondition given in one or more
of the request-header fields evaluated to false when it was tested on the
server.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_PRECONDITION_FAILED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_REQUEST_ENTITY_TOO_LARGE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_REQUEST_ENTITY_TOO_LARGE</h4>
<pre>static final int SC_REQUEST_ENTITY_TOO_LARGE</pre>
<div class="block">Status code (413) indicating that the server is refusing to process the
request because the request entity is larger than the server is willing
or able to process.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_REQUEST_ENTITY_TOO_LARGE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_REQUEST_URI_TOO_LONG">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_REQUEST_URI_TOO_LONG</h4>
<pre>static final int SC_REQUEST_URI_TOO_LONG</pre>
<div class="block">Status code (414) indicating that the server is refusing to service the
request because the <code><em>Request-URI</em></code> is longer than the
server is willing to interpret.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_REQUEST_URI_TOO_LONG">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_UNSUPPORTED_MEDIA_TYPE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_UNSUPPORTED_MEDIA_TYPE</h4>
<pre>static final int SC_UNSUPPORTED_MEDIA_TYPE</pre>
<div class="block">Status code (415) indicating that the server is refusing to service the
request because the entity of the request is in a format not supported by
the requested resource for the requested method.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_UNSUPPORTED_MEDIA_TYPE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_REQUESTED_RANGE_NOT_SATISFIABLE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_REQUESTED_RANGE_NOT_SATISFIABLE</h4>
<pre>static final int SC_REQUESTED_RANGE_NOT_SATISFIABLE</pre>
<div class="block">Status code (416) indicating that the server cannot serve the requested
byte range.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_REQUESTED_RANGE_NOT_SATISFIABLE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_EXPECTATION_FAILED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_EXPECTATION_FAILED</h4>
<pre>static final int SC_EXPECTATION_FAILED</pre>
<div class="block">Status code (417) indicating that the server could not meet the
expectation given in the Expect request header.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_EXPECTATION_FAILED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_INTERNAL_SERVER_ERROR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_INTERNAL_SERVER_ERROR</h4>
<pre>static final int SC_INTERNAL_SERVER_ERROR</pre>
<div class="block">Status code (500) indicating an error inside the HTTP server which
prevented it from fulfilling the request.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_INTERNAL_SERVER_ERROR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_NOT_IMPLEMENTED">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_NOT_IMPLEMENTED</h4>
<pre>static final int SC_NOT_IMPLEMENTED</pre>
<div class="block">Status code (501) indicating the HTTP server does not support the
functionality needed to fulfill the request.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_NOT_IMPLEMENTED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_BAD_GATEWAY">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_BAD_GATEWAY</h4>
<pre>static final int SC_BAD_GATEWAY</pre>
<div class="block">Status code (502) indicating that the HTTP server received an invalid
response from a server it consulted when acting as a proxy or gateway.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_BAD_GATEWAY">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_SERVICE_UNAVAILABLE">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_SERVICE_UNAVAILABLE</h4>
<pre>static final int SC_SERVICE_UNAVAILABLE</pre>
<div class="block">Status code (503) indicating that the HTTP server is temporarily
overloaded, and unable to handle the request.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_SERVICE_UNAVAILABLE">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_GATEWAY_TIMEOUT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SC_GATEWAY_TIMEOUT</h4>
<pre>static final int SC_GATEWAY_TIMEOUT</pre>
<div class="block">Status code (504) indicating that the server did not receive a timely
response from the upstream server while acting as a gateway or proxy.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_GATEWAY_TIMEOUT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="SC_HTTP_VERSION_NOT_SUPPORTED">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>SC_HTTP_VERSION_NOT_SUPPORTED</h4>
<pre>static final int SC_HTTP_VERSION_NOT_SUPPORTED</pre>
<div class="block">Status code (505) indicating that the server does not support or refuses
to support the HTTP protocol version that was used in the request
message.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#javax.servlet.http.HttpServletResponse.SC_HTTP_VERSION_NOT_SUPPORTED">Constant Field Values</a></dd>
</dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="addCookie-javax.servlet.http.Cookie-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addCookie</h4>
<pre>void addCookie(<a href="../../../javax/servlet/http/Cookie.html" title="class in javax.servlet.http">Cookie</a> cookie)</pre>
<div class="block">Adds the specified cookie to the response. This method can be called
multiple times to set more than one cookie.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cookie</code> - the Cookie to return to the client</dd>
</dl>
</li>
</ul>
<a name="containsHeader-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>containsHeader</h4>
<pre>boolean containsHeader(java.lang.String name)</pre>
<div class="block">Returns a boolean indicating whether the named response header has
already been set.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the header name</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the named response header has already been
set; <code>false</code> otherwise</dd>
</dl>
</li>
</ul>
<a name="encodeURL-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>encodeURL</h4>
<pre>java.lang.String encodeURL(java.lang.String url)</pre>
<div class="block">Encodes the specified URL by including the session ID in it, or, if
encoding is not needed, returns the URL unchanged. The implementation of
this method includes the logic to determine whether the session ID needs
to be encoded in the URL. For example, if the browser supports cookies,
or session tracking is turned off, URL encoding is unnecessary.
<p>
For robust session tracking, all URLs emitted by a servlet should be run
through this method. Otherwise, URL rewriting cannot be used with
browsers which do not support cookies.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>url</code> - the url to be encoded.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the encoded URL if encoding is needed; the unchanged URL
otherwise.</dd>
</dl>
</li>
</ul>
<a name="encodeRedirectURL-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>encodeRedirectURL</h4>
<pre>java.lang.String encodeRedirectURL(java.lang.String url)</pre>
<div class="block">Encodes the specified URL for use in the <code>sendRedirect</code> method
or, if encoding is not needed, returns the URL unchanged. The
implementation of this method includes the logic to determine whether the
session ID needs to be encoded in the URL. Because the rules for making
this determination can differ from those used to decide whether to encode
a normal link, this method is separated from the <code>encodeURL</code>
method.
<p>
All URLs sent to the <code>HttpServletResponse.sendRedirect</code> method
should be run through this method. Otherwise, URL rewriting cannot be
used with browsers which do not support cookies.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>url</code> - the url to be encoded.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the encoded URL if encoding is needed; the unchanged URL
otherwise.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#sendRedirect-java.lang.String-"><code>sendRedirect(java.lang.String)</code></a>,
<a href="../../../javax/servlet/http/HttpServletResponse.html#encodeUrl-java.lang.String-"><code>encodeUrl(java.lang.String)</code></a></dd>
</dl>
</li>
</ul>
<a name="encodeUrl-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>encodeUrl</h4>
<pre>java.lang.String encodeUrl(java.lang.String url)</pre>
<div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of version 2.1, use encodeURL(String url) instead</span></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>url</code> - the url to be encoded.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the encoded URL if encoding is needed; the unchanged URL
otherwise.</dd>
</dl>
</li>
</ul>
<a name="encodeRedirectUrl-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>encodeRedirectUrl</h4>
<pre>java.lang.String encodeRedirectUrl(java.lang.String url)</pre>
<div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of version 2.1, use encodeRedirectURL(String url) instead</span></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>url</code> - the url to be encoded.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the encoded URL if encoding is needed; the unchanged URL
otherwise.</dd>
</dl>
</li>
</ul>
<a name="sendError-int-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>sendError</h4>
<pre>void sendError(int sc,
java.lang.String msg)
throws java.io.IOException</pre>
<div class="block">Sends an error response to the client using the specified status code and
clears the output buffer. The server defaults to creating the response to
look like an HTML-formatted server error page containing the specified
message, setting the content type to "text/html", leaving cookies and
other headers unmodified. If an error-page declaration has been made for
the web application corresponding to the status code passed in, it will
be served back in preference to the suggested msg parameter.
<p>
If the response has already been committed, this method throws an
IllegalStateException. After using this method, the response should be
considered to be committed and should not be written to.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>sc</code> - the error status code</dd>
<dd><code>msg</code> - the descriptive message</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code> - If an input or output exception occurs</dd>
<dd><code>java.lang.IllegalStateException</code> - If the response was committed</dd>
</dl>
</li>
</ul>
<a name="sendError-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>sendError</h4>
<pre>void sendError(int sc)
throws java.io.IOException</pre>
<div class="block">Sends an error response to the client using the specified status code and
clears the buffer. This is equivalent to calling <a href="../../../javax/servlet/http/HttpServletResponse.html#sendError-int-java.lang.String-"><code>sendError(int,
String)</code></a> with the same status code and <code>null</code> for the message.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>sc</code> - the error status code</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code> - If an input or output exception occurs</dd>
<dd><code>java.lang.IllegalStateException</code> - If the response was committed before this method call</dd>
</dl>
</li>
</ul>
<a name="sendRedirect-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>sendRedirect</h4>
<pre>void sendRedirect(java.lang.String location)
throws java.io.IOException</pre>
<div class="block">Sends a temporary redirect response to the client using the specified
redirect location URL. This method can accept relative URLs; the servlet
container must convert the relative URL to an absolute URL before sending
the response to the client. If the location is relative without a leading
'/' the container interprets it as relative to the current request URI.
If the location is relative with a leading '/' the container interprets
it as relative to the servlet container root.
<p>
If the response has already been committed, this method throws an
IllegalStateException. After using this method, the response should be
considered to be committed and should not be written to.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>location</code> - the redirect location URL</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code> - If an input or output exception occurs</dd>
<dd><code>java.lang.IllegalStateException</code> - If the response was committed or if a partial URL is given
and cannot be converted into a valid URL</dd>
</dl>
</li>
</ul>
<a name="setDateHeader-java.lang.String-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setDateHeader</h4>
<pre>void setDateHeader(java.lang.String name,
long date)</pre>
<div class="block">Sets a response header with the given name and date-value. The date is
specified in terms of milliseconds since the epoch. If the header had
already been set, the new value overwrites the previous one. The
<code>containsHeader</code> method can be used to test for the presence
of a header before setting its value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the name of the header to set</dd>
<dd><code>date</code> - the assigned date value</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#containsHeader-java.lang.String-"><code>containsHeader(java.lang.String)</code></a>,
<a href="../../../javax/servlet/http/HttpServletResponse.html#addDateHeader-java.lang.String-long-"><code>addDateHeader(java.lang.String, long)</code></a></dd>
</dl>
</li>
</ul>
<a name="addDateHeader-java.lang.String-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addDateHeader</h4>
<pre>void addDateHeader(java.lang.String name,
long date)</pre>
<div class="block">Adds a response header with the given name and date-value. The date is
specified in terms of milliseconds since the epoch. This method allows
response headers to have multiple values.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the name of the header to set</dd>
<dd><code>date</code> - the additional date value</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#setDateHeader-java.lang.String-long-"><code>setDateHeader(java.lang.String, long)</code></a></dd>
</dl>
</li>
</ul>
<a name="setHeader-java.lang.String-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setHeader</h4>
<pre>void setHeader(java.lang.String name,
java.lang.String value)</pre>
<div class="block">Sets a response header with the given name and value. If the header had
already been set, the new value overwrites the previous one. The
<code>containsHeader</code> method can be used to test for the presence
of a header before setting its value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the name of the header</dd>
<dd><code>value</code> - the header value If it contains octet string, it should be
encoded according to RFC 2047
(http://www.ietf.org/rfc/rfc2047.txt)</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#containsHeader-java.lang.String-"><code>containsHeader(java.lang.String)</code></a>,
<a href="../../../javax/servlet/http/HttpServletResponse.html#addHeader-java.lang.String-java.lang.String-"><code>addHeader(java.lang.String, java.lang.String)</code></a></dd>
</dl>
</li>
</ul>
<a name="addHeader-java.lang.String-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addHeader</h4>
<pre>void addHeader(java.lang.String name,
java.lang.String value)</pre>
<div class="block">Adds a response header with the given name and value. This method allows
response headers to have multiple values.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the name of the header</dd>
<dd><code>value</code> - the additional header value If it contains octet string, it
should be encoded according to RFC 2047
(http://www.ietf.org/rfc/rfc2047.txt)</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#setHeader-java.lang.String-java.lang.String-"><code>setHeader(java.lang.String, java.lang.String)</code></a></dd>
</dl>
</li>
</ul>
<a name="setIntHeader-java.lang.String-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setIntHeader</h4>
<pre>void setIntHeader(java.lang.String name,
int value)</pre>
<div class="block">Sets a response header with the given name and integer value. If the
header had already been set, the new value overwrites the previous one.
The <code>containsHeader</code> method can be used to test for the
presence of a header before setting its value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the name of the header</dd>
<dd><code>value</code> - the assigned integer value</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#containsHeader-java.lang.String-"><code>containsHeader(java.lang.String)</code></a>,
<a href="../../../javax/servlet/http/HttpServletResponse.html#addIntHeader-java.lang.String-int-"><code>addIntHeader(java.lang.String, int)</code></a></dd>
</dl>
</li>
</ul>
<a name="addIntHeader-java.lang.String-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addIntHeader</h4>
<pre>void addIntHeader(java.lang.String name,
int value)</pre>
<div class="block">Adds a response header with the given name and integer value. This method
allows response headers to have multiple values.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - the name of the header</dd>
<dd><code>value</code> - the assigned integer value</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#setIntHeader-java.lang.String-int-"><code>setIntHeader(java.lang.String, int)</code></a></dd>
</dl>
</li>
</ul>
<a name="setStatus-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setStatus</h4>
<pre>void setStatus(int sc)</pre>
<div class="block">Sets the status code for this response. This method is used to set the
return status code when there is no error (for example, for the status
codes SC_OK or SC_MOVED_TEMPORARILY). If there is an error, and the
caller wishes to invoke an error-page defined in the web application, the
<code>sendError</code> method should be used instead.
<p>
The container clears the buffer and sets the Location header, preserving
cookies and other headers.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>sc</code> - the status code</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../javax/servlet/http/HttpServletResponse.html#sendError-int-java.lang.String-"><code>sendError(int, java.lang.String)</code></a></dd>
</dl>
</li>
</ul>
<a name="setStatus-int-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setStatus</h4>
<pre>void setStatus(int sc,
java.lang.String sm)</pre>
<div class="block"><span class="deprecatedLabel">Deprecated.</span> <span class="deprecationComment">As of version 2.1, due to ambiguous meaning of the message
parameter. To set a status code use
<code>setStatus(int)</code>, to send an error with a
description use <code>sendError(int, String)</code>.</span></div>
<div class="block">Sets the status code and message for this response.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>sc</code> - the status code</dd>
<dd><code>sm</code> - the status message</dd>
</dl>
</li>
</ul>
<a name="getStatus--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getStatus</h4>
<pre>int getStatus()</pre>
<div class="block">Return the HTTP status code associated with this Response.</div>
<dl>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>Servlet 3.0</dd>
</dl>
</li>
</ul>
<a name="getHeader-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHeader</h4>
<pre>java.lang.String getHeader(java.lang.String name)</pre>
<div class="block">Return the value for the specified header, or <code>null</code> if this
header has not been set. If more than one value was added for this
name, only the first is returned; use <a href="../../../javax/servlet/http/HttpServletResponse.html#getHeaders-java.lang.String-"><code>getHeaders(String)</code></a> to
retrieve all of them.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - Header name to look up</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>Servlet 3.0</dd>
</dl>
</li>
</ul>
<a name="getHeaders-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHeaders</h4>
<pre>java.util.Collection<java.lang.String> getHeaders(java.lang.String name)</pre>
<div class="block">Return a Collection of all the header values associated with the
specified header name.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - Header name to look up</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>Servlet 3.0</dd>
</dl>
</li>
</ul>
<a name="getHeaderNames--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getHeaderNames</h4>
<pre>java.util.Collection<java.lang.String> getHeaderNames()</pre>
<div class="block">Return an Iterable of all the header names set for this response.</div>
<dl>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>Servlet 3.0</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../javax/servlet/http/HttpServletRequestWrapper.html" title="class in javax.servlet.http"><span class="typeNameLink">Prev Class</span></a></li>
<li><a href="../../../javax/servlet/http/HttpServletResponseWrapper.html" title="class in javax.servlet.http"><span class="typeNameLink">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../index.html?javax/servlet/http/HttpServletResponse.html" target="_top">Frames</a></li>
<li><a href="HttpServletResponse.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary: </li>
<li>Nested | </li>
<li><a href="#field.summary">Field</a> | </li>
<li>Constr | </li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail: </li>
<li><a href="#field.detail">Field</a> | </li>
<li>Constr | </li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.</small></p>
</body>
</html>
|