nstream.adapter.common.ext.RabbitMqIngressSettings Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of nstream-adapter-common Show documentation
Show all versions of nstream-adapter-common Show documentation
General server-side data flow templates with Swim
// Copyright 2015-2024 Nstream, inc.
//
// Licensed under the Redis Source Available License 2.0 (RSALv2) Agreement;
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// https://redis.com/legal/rsalv2-agreement/
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package nstream.adapter.common.ext;
import nstream.adapter.common.AdapterSettings;
import swim.codec.Format;
import swim.codec.Output;
import swim.structure.Form;
import swim.structure.Kind;
import swim.structure.Tag;
import swim.structure.Value;
@Tag("rabbitMqIngressSettings")
public class RabbitMqIngressSettings implements AdapterSettings {
private final String connectionProvisionName;
private final String consumerPropertiesProvisionName;
private final String contentEncodingOverride;
private final String contentTypeOverride;
private final Value valueMolder;
private final Value relaySchema;
public RabbitMqIngressSettings(String connectionProvisionName, String consumerPropertiesProvisionName,
String contentEncodingOverride, String contentTypeOverride,
Value valueMolder, Value relaySchema) {
this.connectionProvisionName = connectionProvisionName;
this.consumerPropertiesProvisionName = consumerPropertiesProvisionName;
this.contentEncodingOverride = contentEncodingOverride;
this.contentTypeOverride = contentTypeOverride;
this.valueMolder = valueMolder;
this.relaySchema = relaySchema;
}
public RabbitMqIngressSettings() {
this("rabbitMqConnection", "consumerProperties", null, null, null, null);
}
public String connectionProvisionName() {
return this.connectionProvisionName;
}
public String consumerPropertiesProvisionName() {
return this.consumerPropertiesProvisionName;
}
public String contentEncodingOverride() {
return this.contentEncodingOverride;
}
public String contentTypeOverride() {
return this.contentTypeOverride;
}
public Value valueMolder() {
return this.valueMolder;
}
public Value relaySchema() {
return this.relaySchema;
}
@Override
public Output debug(Output output) {
output = output.write("RabbitMqIngressSettings").write('.').write("of").write('(').write(')')
.write('.').write("connectionProvisionName").write('(').debug(this.connectionProvisionName).write(')')
.write('.').write("consumerPropertiesProvisionName").write('(').debug(this.consumerPropertiesProvisionName).write(')')
.write('.').write("contentEncodingOverride").write('(').debug(this.contentEncodingOverride).write(')')
.write('.').write("contentTypeOverride").write('(').debug(this.contentTypeOverride).write(')')
.write('.').write("relaySchema").write('(').debug(this.contentTypeOverride).write(')');
return output;
}
@Override
public String toString() {
return Format.debug(this);
}
@Kind
private static Form form;
private static final RabbitMqIngressSettings DEFAULT = new RabbitMqIngressSettings();
public static Form form() {
if (RabbitMqIngressSettings.form == null) {
RabbitMqIngressSettings.form = Form.forClass(RabbitMqIngressSettings.class);
}
return RabbitMqIngressSettings.form;
}
public static RabbitMqIngressSettings defaultSettings() {
return RabbitMqIngressSettings.DEFAULT;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy