package com.github.helpermethod.membrane.starter.dsl.exchange;

import com.predic8.membrane.core.exchange.Exchange;

import java.util.Map;

public class ExchangeSpecification {
    private final Exchange exchange;

    public ExchangeSpecification(Exchange exchange) {
        this.exchange = exchange;
    }

    public RequestSpecification request() {
        return new RequestSpecification(exchange.getRequest());
    }

    public ResponseSpecification response() {
        return new ResponseSpecification(exchange.getResponse());
    }

    public Map<String, Object> properties() {
        return exchange.getProperties();
    }

    public Object properties(String key) {
        return exchange.getProperty(key);
    }

    public ExchangeSpecification properties(String key, Object value) {
        exchange.setProperty(key, value);

        return this;
    }

    public Exchange get() {
        return exchange;
    }

    @Override
    public String toString() {
        return exchange.toString();
    }
}
@@ -100,32 +100,86 @@
 change.Exchange;
+%0Aimport com.predic8.membrane.core.interceptor.Outcome;
 %0A%0Aimport java.ut
@@ -702,35 +702,33 @@
 c Object propert
-ies
+y
 (String key) %7B%0A 
@@ -815,19 +815,17 @@
  propert
-ies
+y
 (String 

Rename properties method