org.glassfish.grizzly.http.server.Request.isSecure()方法的使用及代码示例

x33g5p2x  于2022-01-28 转载在 其他  
字(5.8k)|赞(0)|评价(0)|浏览(140)

本文整理了Java中org.glassfish.grizzly.http.server.Request.isSecure方法的一些代码示例,展示了Request.isSecure的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Request.isSecure方法的具体详情如下:
包路径:org.glassfish.grizzly.http.server.Request
类名称:Request
方法名:isSecure

Request.isSecure介绍

[英]Was this request received on a secure connection?
[中]是否通过安全连接收到此请求?

代码示例

代码示例来源:origin: jersey/jersey

  1. @Override
  2. public boolean isSecure() {
  3. return request.isSecure();
  4. }

代码示例来源:origin: org.glassfish.jersey.containers/jersey-container-grizzly2-http

  1. @Override
  2. public boolean isSecure() {
  3. return request.isSecure();
  4. }

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

  1. /**
  2. * {@inheritDoc}
  3. */
  4. @Override
  5. public boolean isSecure() {
  6. if (request == null) {
  7. throw new IllegalStateException("Null request object");
  8. }
  9. return request.isSecure();
  10. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * {@inheritDoc}
  3. */
  4. @Override
  5. public boolean isSecure() {
  6. if (request == null) {
  7. throw new IllegalStateException("Null request object");
  8. }
  9. return request.isSecure();
  10. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * {@inheritDoc}
  3. */
  4. @Override
  5. public boolean isSecure() {
  6. if (request == null) {
  7. throw new IllegalStateException("Null request object");
  8. }
  9. return request.isSecure();
  10. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * {@inheritDoc}
  3. */
  4. @Override
  5. public boolean isSecure() {
  6. if (request == null) {
  7. throw new IllegalStateException("Null request object");
  8. }
  9. return request.isSecure();
  10. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * {@inheritDoc}
  3. */
  4. @Override
  5. public boolean isSecure() {
  6. if (request == null) {
  7. throw new IllegalStateException("Null request object");
  8. }
  9. return request.isSecure();
  10. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * {@inheritDoc}
  3. */
  4. @Override
  5. public boolean isSecure() {
  6. if (request == null) {
  7. throw new IllegalStateException("Null request object");
  8. }
  9. return request.isSecure();
  10. }

代码示例来源:origin: javaee/grizzly

  1. public static void sendFile(final Response response, final File file)
  2. throws IOException {
  3. response.setStatus(HttpStatus.OK_200);
  4. // In case this sendFile(...) is called directly by user - pickup the content-type
  5. pickupContentType(response, file.getPath());
  6. final long length = file.length();
  7. response.setContentLengthLong(length);
  8. response.addDateHeader(Header.Date, System.currentTimeMillis());
  9. if (!response.isSendFileEnabled() || response.getRequest().isSecure()) {
  10. sendUsingBuffers(response, file);
  11. } else {
  12. sendZeroCopy(response, file);
  13. }
  14. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: org.glassfish.grizzly/grizzly-http-server

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: javaee/grizzly

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-http-server

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: org.glassfish.grizzly/grizzly-http-server-core

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

  1. /**
  2. * Configures the given session cookie.
  3. *
  4. * @param cookie The session cookie to be configured
  5. */
  6. protected void configureSessionCookie(final Cookie cookie) {
  7. cookie.setMaxAge(-1);
  8. cookie.setPath("/");
  9. if (isSecure()) {
  10. cookie.setSecure(true);
  11. }
  12. getSessionManager().configureSessionCookie(this, cookie);
  13. }

相关文章

Request类方法