microsoft.dynamics.crm.complex.CanvasAppsDetails Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of odata-client-microsoft-dynamics Show documentation
Show all versions of odata-client-microsoft-dynamics Show documentation
Java client as template for Microsoft Dynamics organisation endpoints
package microsoft.dynamics.crm.complex;
import com.fasterxml.jackson.annotation.JacksonInject;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.github.davidmoten.odata.client.ContextPath;
import com.github.davidmoten.odata.client.ODataType;
import com.github.davidmoten.odata.client.Util;
import com.github.davidmoten.odata.client.annotation.Property;
import com.github.davidmoten.odata.client.internal.ChangedFields;
import com.github.davidmoten.odata.client.internal.Checks;
import com.github.davidmoten.odata.client.internal.UnmappedFields;
import java.util.Optional;
@JsonPropertyOrder({
"@odata.type",
"UniqueName",
"AppId",
"Type",
"PublishConfiguration"})
@JsonInclude(Include.NON_NULL)
public class CanvasAppsDetails implements ODataType {
@JacksonInject
@JsonIgnore
protected ContextPath contextPath;
@JacksonInject
@JsonIgnore
protected UnmappedFields unmappedFields;
@JsonProperty("@odata.type")
protected String odataType;
@JsonProperty("UniqueName")
protected String uniqueName;
@JsonProperty("AppId")
protected String appId;
@JsonProperty("Type")
protected Integer type;
@JsonProperty("PublishConfiguration")
protected String publishConfiguration;
protected CanvasAppsDetails() {
}
@Override
public String odataTypeName() {
return "Microsoft.Dynamics.CRM.CanvasAppsDetails";
}
@Property(name="UniqueName")
@JsonIgnore
public Optional getUniqueName() {
return Optional.ofNullable(uniqueName);
}
public CanvasAppsDetails withUniqueName(String uniqueName) {
Checks.checkIsAscii(uniqueName);
CanvasAppsDetails _x = _copy();
_x.odataType = Util.nvl(odataType, "Microsoft.Dynamics.CRM.CanvasAppsDetails");
_x.uniqueName = uniqueName;
return _x;
}
@Property(name="AppId")
@JsonIgnore
public Optional getAppId() {
return Optional.ofNullable(appId);
}
public CanvasAppsDetails withAppId(String appId) {
CanvasAppsDetails _x = _copy();
_x.odataType = Util.nvl(odataType, "Microsoft.Dynamics.CRM.CanvasAppsDetails");
_x.appId = appId;
return _x;
}
@Property(name="Type")
@JsonIgnore
public Optional getType() {
return Optional.ofNullable(type);
}
public CanvasAppsDetails withType(Integer type) {
CanvasAppsDetails _x = _copy();
_x.odataType = Util.nvl(odataType, "Microsoft.Dynamics.CRM.CanvasAppsDetails");
_x.type = type;
return _x;
}
@Property(name="PublishConfiguration")
@JsonIgnore
public Optional getPublishConfiguration() {
return Optional.ofNullable(publishConfiguration);
}
public CanvasAppsDetails withPublishConfiguration(String publishConfiguration) {
Checks.checkIsAscii(publishConfiguration);
CanvasAppsDetails _x = _copy();
_x.odataType = Util.nvl(odataType, "Microsoft.Dynamics.CRM.CanvasAppsDetails");
_x.publishConfiguration = publishConfiguration;
return _x;
}
@JsonAnySetter
private void setUnmappedField(String name, Object value) {
if (unmappedFields == null) {
unmappedFields = new UnmappedFields();
}
unmappedFields.put(name, value);
}
@Override
@JsonIgnore
public UnmappedFields getUnmappedFields() {
return unmappedFields == null ? new UnmappedFields() : unmappedFields;
}
@Override
public void postInject(boolean addKeysToContextPath) {
// do nothing;
}
/**
* Returns a builder which is used to create a new
* instance of this class (given that this class is immutable).
*
* @return a new Builder for this class
*/
// Suffix used on builder factory method to differentiate the method
// from static builder methods on superclasses
public static Builder builder() {
return new Builder();
}
public static final class Builder {
private String uniqueName;
private String appId;
private Integer type;
private String publishConfiguration;
private ChangedFields changedFields = new ChangedFields();
Builder() {
// prevent instantiation
}
public Builder uniqueName(String uniqueName) {
this.uniqueName = uniqueName;
this.changedFields = changedFields.add("UniqueName");
return this;
}
public Builder appId(String appId) {
this.appId = appId;
this.changedFields = changedFields.add("AppId");
return this;
}
public Builder type(Integer type) {
this.type = type;
this.changedFields = changedFields.add("Type");
return this;
}
public Builder publishConfiguration(String publishConfiguration) {
this.publishConfiguration = publishConfiguration;
this.changedFields = changedFields.add("PublishConfiguration");
return this;
}
public CanvasAppsDetails build() {
CanvasAppsDetails _x = new CanvasAppsDetails();
_x.contextPath = null;
_x.unmappedFields = new UnmappedFields();
_x.odataType = "Microsoft.Dynamics.CRM.CanvasAppsDetails";
_x.uniqueName = uniqueName;
_x.appId = appId;
_x.type = type;
_x.publishConfiguration = publishConfiguration;
return _x;
}
}
private CanvasAppsDetails _copy() {
CanvasAppsDetails _x = new CanvasAppsDetails();
_x.contextPath = contextPath;
_x.unmappedFields = unmappedFields;
_x.odataType = odataType;
_x.uniqueName = uniqueName;
_x.appId = appId;
_x.type = type;
_x.publishConfiguration = publishConfiguration;
return _x;
}
@Override
public String toString() {
StringBuilder b = new StringBuilder();
b.append("CanvasAppsDetails[");
b.append("UniqueName=");
b.append(this.uniqueName);
b.append(", ");
b.append("AppId=");
b.append(this.appId);
b.append(", ");
b.append("Type=");
b.append(this.type);
b.append(", ");
b.append("PublishConfiguration=");
b.append(this.publishConfiguration);
b.append("]");
b.append(",unmappedFields=");
b.append(unmappedFields);
b.append(",odataType=");
b.append(odataType);
return b.toString();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy