public ZippingSerializerDecorator(ISerializer serializer, Zipper zipper, int bodySizeThresholdBytes) { if (serializer == null) throw new ArgumentNullException(nameof(serializer)); if (zipper == null) throw new ArgumentNullException(nameof(zipper)); if (bodySizeThresholdBytes < 0) throw new ArgumentOutOfRangeException(nameof(bodySizeThresholdBytes), bodySizeThresholdBytes, "Body size threshold must be >= 0"); _serializer = serializer; _zipper = zipper; _bodySizeThresholdBytes = bodySizeThresholdBytes; }
protected override void SetUp() { _zipper = new Zipper(); }
/// <summary> /// Message pipeline step that unzips incoming messages if the <see cref="Headers.ContentEncoding"/> is present /// </summary> public UnzipMessagesIncomingStep(Zipper zipper) { _zipper = zipper; }
public UnzippingSerializerDecorator(ISerializer serializer, Zipper zipper) { _serializer = serializer ?? throw new ArgumentNullException(nameof(serializer)); _zipper = zipper ?? throw new ArgumentNullException(nameof(zipper)); }
/// <summary> /// Constructs the step /// </summary> public ZipMessagesOutgoingStep(Zipper zipper, int bodySizeThresholdBytes) { _zipper = zipper; _bodySizeThresholdBytes = bodySizeThresholdBytes; }