package cz.moneta.test.dsl.messaging;

import cz.moneta.test.dsl.Harness;
import cz.moneta.test.harness.endpoints.messaging.MessagingEndpoint;
import cz.moneta.test.harness.support.messaging.MessagingRequest;

public class Messaging {

    private final Harness harness;

    public Messaging(Harness harness) {
        this.harness = harness;
    }

    public MessagingRequest to(String destinationName) {
        return request().to(destinationName);
    }

    public MessagingRequest from(String destinationName) {
        return request().from(destinationName);
    }

    public MessagingRequest request() {
        return MessagingRequest.builder(harness.getEndpoint(MessagingEndpoint.class));
    }
}
