Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions components/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,6 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-rest</artifactId>
</dependency>

<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
package org.folio.rest.workflow.dto;

import jakarta.validation.constraints.NotNull;
import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
public class Comparison {

@NotNull
Expand All @@ -18,4 +14,32 @@ public Comparison() {
super();
}

/**
* @return the sourceProperty
*/
public String getSourceProperty() {
return sourceProperty;
}

/**
* @return the targetProperty
*/
public String getTargetProperty() {
return targetProperty;
}

/**
* @param sourceProperty the sourceProperty to set
*/
public void setSourceProperty(String sourceProperty) {
this.sourceProperty = sourceProperty;
}

/**
* @param targetProperty the targetProperty to set
*/
public void setTargetProperty(String targetProperty) {
this.targetProperty = targetProperty;
}

}
46 changes: 42 additions & 4 deletions components/src/main/java/org/folio/rest/workflow/dto/Mapping.java
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
package org.folio.rest.workflow.dto;

import jakarta.validation.constraints.NotNull;
import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
public class Mapping {

@NotNull
Expand All @@ -23,4 +19,46 @@ public Mapping() {
multiple = false;
}

/**
* @return the toProperty
*/
public String getToProperty() {
return toProperty;
}

/**
* @return the fromProperty
*/
public String getFromProperty() {
return fromProperty;
}

/**
* @return the multiple
*/
public boolean isMultiple() {
return multiple;
}

/**
* @param toProperty the toProperty to set
*/
public void setToProperty(String toProperty) {
this.toProperty = toProperty;
}

/**
* @param fromProperty the fromProperty to set
*/
public void setFromProperty(String fromProperty) {
this.fromProperty = fromProperty;
}

/**
* @param multiple the multiple to set
*/
public void setMultiple(boolean multiple) {
this.multiple = multiple;
}

}
116 changes: 112 additions & 4 deletions components/src/main/java/org/folio/rest/workflow/dto/Request.java
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
package org.folio.rest.workflow.dto;

import jakarta.validation.constraints.NotNull;
import lombok.Getter;
import lombok.Setter;
import org.springframework.http.HttpMethod;
import org.springframework.http.MediaType;

@Getter
@Setter
public class Request {

@NotNull
Expand Down Expand Up @@ -38,4 +34,116 @@ public Request() {
iterable = false;
}

/**
* @return the url
*/
public String getUrl() {
return url;
}

/**
* @return the method
*/
public HttpMethod getMethod() {
return method;
}

/**
* @return the contentType
*/
public String getContentType() {
return contentType;
}

/**
* @return the accept
*/
public String getAccept() {
return accept;
}

/**
* @return the bodyTemplate
*/
public String getBodyTemplate() {
return bodyTemplate;
}

/**
* @return the iterable
*/
public boolean isIterable() {
return iterable;
}

/**
* @return the iterableKey
*/
public String getIterableKey() {
return iterableKey;
}

/**
* @return the responseKey
*/
public String getResponseKey() {
return responseKey;
}

/**
* @param url the url to set
*/
public void setUrl(String url) {
this.url = url;
}

/**
* @param method the method to set
*/
public void setMethod(HttpMethod method) {
this.method = method;
}

/**
* @param contentType the contentType to set
*/
public void setContentType(String contentType) {
this.contentType = contentType;
}

/**
* @param accept the accept to set
*/
public void setAccept(String accept) {
this.accept = accept;
}

/**
* @param bodyTemplate the bodyTemplate to set
*/
public void setBodyTemplate(String bodyTemplate) {
this.bodyTemplate = bodyTemplate;
}

/**
* @param iterable the iterable to set
*/
public void setIterable(boolean iterable) {
this.iterable = iterable;
}

/**
* @param iterableKey the iterableKey to set
*/
public void setIterableKey(String iterableKey) {
this.iterableKey = iterableKey;
}

/**
* @param responseKey the responseKey to set
*/
public void setResponseKey(String responseKey) {
this.responseKey = responseKey;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,17 @@
import jakarta.persistence.PrePersist;
import java.util.ArrayList;
import java.util.List;
import lombok.Getter;
import lombok.Setter;
import org.folio.rest.workflow.enums.Direction;
import org.folio.rest.workflow.model.components.Gateway;
import org.folio.rest.workflow.model.has.HasNodes;

@MappedSuperclass
public abstract class AbstractGateway extends Node implements Gateway, HasNodes {

@Getter
@Setter
@Column(nullable = false)
@Enumerated(EnumType.STRING)
private Direction direction;

@Getter
@Setter
@OneToMany
@OrderColumn
private List<Node> nodes;
Expand All @@ -51,4 +45,24 @@ public void prePersist() {
}
}

@Override
public Direction getDirection() {
return direction;
}

@Override
public void setDirection(Direction direction) {
this.direction = direction;
}

@Override
public List<Node> getNodes() {
return nodes;
}

@Override
public void setNodes(List<Node> nodes) {
this.nodes = nodes;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
import jakarta.persistence.PrePersist;
import java.util.ArrayList;
import java.util.List;
import lombok.Getter;
import lombok.Setter;
import org.folio.rest.workflow.model.has.HasAsync;
import org.folio.rest.workflow.model.has.HasNodes;
import org.hibernate.annotations.ColumnDefault;
Expand All @@ -21,20 +19,14 @@
@MappedSuperclass
public abstract class AbstractProcess extends Node implements HasAsync, HasNodes {

@Getter
@Setter
@Column(nullable = false)
@ColumnDefault("false")
private Boolean asyncAfter;

@Getter
@Setter
@Column(nullable = false)
@ColumnDefault("false")
private Boolean asyncBefore;

@Getter
@Setter
@OneToMany
@OrderColumn
private List<Node> nodes;
Expand Down Expand Up @@ -65,4 +57,34 @@ public void prePersist() {
}
}

@Override
public List<Node> getNodes() {
return nodes;
}

@Override
public void setNodes(List<Node> nodes) {
this.nodes = nodes;
}

@Override
public Boolean getAsyncAfter() {
return asyncAfter;
}

@Override
public Boolean getAsyncBefore() {
return asyncBefore;
}

@Override
public void setAsyncAfter(Boolean asyncAfter) {
this.asyncAfter = asyncAfter;
}

@Override
public void setAsyncBefore(Boolean asyncBefore) {
this.asyncBefore = asyncBefore;
}

}
Loading
Loading