Examples of removeHeader()


Examples of net.sf.sahi.response.HttpResponse.removeHeader()

          String redirectedTo = response.getLastSetValueOfHeader("Location");
          if (redirectedTo != null) session.addAjaxRedirect(redirectedTo);
        }
       
        if (isGZIP) {
          response.removeHeader("Content-Encoding", "gzip");
          if (response instanceof StreamingHttpResponse) response.setContentLength(-1);
        }
       
      }catch(IOException uhe){
        if (uhe instanceof SSLHandshakeException)
View Full Code Here

Examples of org.apache.camel.Message.removeHeader()

            exchange.setException(e);
            callback.done(true);
            return true;
        } finally {
            // must remove headers as they were provisional
            in.removeHeader(Exchange.BEAN_MULTI_PARAMETER_ARRAY);
            in.removeHeader(Exchange.BEAN_METHOD_NAME);
        }
        if (invocation == null) {
            throw new IllegalStateException("No method invocation could be created, no matching method could be found on: " + bean);
        }
View Full Code Here

Examples of org.apache.camel.Message.removeHeader()

            callback.done(true);
            return true;
        } finally {
            // must remove headers as they were provisional
            in.removeHeader(Exchange.BEAN_MULTI_PARAMETER_ARRAY);
            in.removeHeader(Exchange.BEAN_METHOD_NAME);
        }
        if (invocation == null) {
            throw new IllegalStateException("No method invocation could be created, no matching method could be found on: " + bean);
        }
View Full Code Here

Examples of org.apache.camel.Message.removeHeader()

    protected String getTopic(Exchange exchange) {
        Message in = exchange.getIn();
        String topic = in.getHeader(EventAdminConstants.EVENTADMIN_TOPIC, String.class);
        if (topic != null) {
            in.removeHeader(EventAdminConstants.EVENTADMIN_TOPIC);
        }
        if (topic == null) {
            topic = endpoint.getTopic();
        }
        return topic;
View Full Code Here

Examples of org.apache.camel.model.AggregateDefinition.removeHeader()

                AggregateDefinition agg =
                        from("direct:joinBrothers").aggregate(header(TYPE_HEADER),
                                brothersAggregator);

                agg.setCompletionTimeout(2000L);
                agg.removeHeader(SURNAME_HEADER)
                        .removeHeader(TYPE_HEADER)
                        .to("mock:result");
            }
        };
    }
View Full Code Here

Examples of org.apache.camel.model.AggregatorType.removeHeader()

                AggregatorType agg =
                        from("direct:joinBrothers").aggregator(header(TYPE_HEADER),
                                brothersAggregator);

                agg.setBatchTimeout(2000L);
                agg.removeHeader(SURNAME_HEADER)
                        .removeHeader(TYPE_HEADER)
                        .to("mock:result");
            }
        };
    }
View Full Code Here

Examples of org.apache.cassandra.net.Message.removeHeader()

            for (Map.Entry<Message, Collection<InetAddress>> messages: entry.getValue().asMap().entrySet())
            {
                Message message = messages.getKey();
                // a single message object is used for unhinted writes, so clean out any forwards
                // from previous loop iterations
                message.removeHeader(RowMutation.FORWARD_HEADER);

                if (dataCenter.equals(localDataCenter) || StorageService.instance.useEfficientCrossDCWrites())
                {
                    // direct writes to local DC or old Cassadra versions
                    for (InetAddress destination : messages.getValue())
View Full Code Here

Examples of org.apache.cassandra.net.Message.removeHeader()

            for (Map.Entry<Message, Collection<InetAddress>> messages: entry.getValue().asMap().entrySet())
            {
                Message message = messages.getKey();
                // a single message object is used for unhinted writes, so clean out any forwards
                // from previous loop iterations
                message.removeHeader(RowMutation.FORWARD_HEADER);

                if (dataCenter.equals(localDataCenter) || StorageService.instance.useEfficientCrossDCWrites())
                {
                    // direct writes to local DC or old Cassadra versions
                    for (InetAddress destination : messages.getValue())
View Full Code Here

Examples of org.apache.http.HttpEntityEnclosingRequest.removeHeader()

        if (msgContext.isSOAP11() && soapAction != null &&
            soapAction.length() > 0) {
            Header existingHeader =
                httpRequest.getFirstHeader(HTTPConstants.HEADER_SOAP_ACTION);
            if (existingHeader != null) {
                httpRequest.removeHeader(existingHeader);
            }
            httpRequest.setHeader(HTTPConstants.HEADER_SOAP_ACTION,
                soapAction);
        }
View Full Code Here

Examples of org.apache.http.HttpMessage.removeHeader()

        headers = message.getAllHeaders();
        assertNotNull(headers);
        assertEquals(1, headers.length);
        assertEquals(null, headers[0].getValue());

        message.removeHeader(message.getFirstHeader("whatever"));
        headers = message.getAllHeaders();
        assertNotNull(headers);
        assertEquals(0, headers.length);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.