com.commercetools.history.models.change.UnpublishChangeBuilder Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of commercetools-sdk-java-history Show documentation
Show all versions of commercetools-sdk-java-history Show documentation
The e-commerce SDK from commercetools Composable Commerce for Java
package com.commercetools.history.models.change;
import java.util.*;
import io.vrap.rmf.base.client.Builder;
import io.vrap.rmf.base.client.utils.Generated;
/**
* UnpublishChangeBuilder
*
* Example to create an instance using the builder pattern
*
*
* UnpublishChange unpublishChange = UnpublishChange.builder()
* .change("{change}")
* .build()
*
*
*/
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen")
public class UnpublishChangeBuilder implements Builder {
private String change;
/**
* set the value to the change
* @param change value to be set
* @return Builder
*/
public UnpublishChangeBuilder change(final String change) {
this.change = change;
return this;
}
/**
* value of change}
* @return change
*/
public String getChange() {
return this.change;
}
/**
* builds UnpublishChange with checking for non-null required values
* @return UnpublishChange
*/
public UnpublishChange build() {
Objects.requireNonNull(change, UnpublishChange.class + ": change is missing");
return new UnpublishChangeImpl(change);
}
/**
* builds UnpublishChange without checking for non-null required values
* @return UnpublishChange
*/
public UnpublishChange buildUnchecked() {
return new UnpublishChangeImpl(change);
}
/**
* factory method for an instance of UnpublishChangeBuilder
* @return builder
*/
public static UnpublishChangeBuilder of() {
return new UnpublishChangeBuilder();
}
/**
* create builder for UnpublishChange instance
* @param template instance with prefilled values for the builder
* @return builder
*/
public static UnpublishChangeBuilder of(final UnpublishChange template) {
UnpublishChangeBuilder builder = new UnpublishChangeBuilder();
builder.change = template.getChange();
return builder;
}
}