org.flowable.engine.impl.persistence.entity.AttachmentEntityImpl Maven / Gradle / Ivy
/* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* 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 org.flowable.engine.impl.persistence.entity;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
import org.flowable.common.engine.impl.persistence.entity.ByteArrayEntity;
/**
* @author Tom Baeyens
*/
public class AttachmentEntityImpl extends AbstractBpmnEngineEntity implements AttachmentEntity, Serializable {
private static final long serialVersionUID = 1L;
protected String name;
protected String description;
protected String type;
protected String taskId;
protected String processInstanceId;
protected String url;
protected String contentId;
protected ByteArrayEntity content;
protected String userId;
protected Date time;
public AttachmentEntityImpl() {
}
@Override
public Object getPersistentState() {
Map persistentState = new HashMap<>();
persistentState.put("name", name);
persistentState.put("description", description);
return persistentState;
}
@Override
public String getName() {
return name;
}
@Override
public void setName(String name) {
this.name = name;
}
@Override
public String getDescription() {
return description;
}
@Override
public void setDescription(String description) {
this.description = description;
}
@Override
public String getType() {
return type;
}
@Override
public void setType(String type) {
this.type = type;
}
@Override
public String getTaskId() {
return taskId;
}
@Override
public void setTaskId(String taskId) {
this.taskId = taskId;
}
@Override
public String getProcessInstanceId() {
return processInstanceId;
}
@Override
public void setProcessInstanceId(String processInstanceId) {
this.processInstanceId = processInstanceId;
}
@Override
public String getUrl() {
return url;
}
@Override
public void setUrl(String url) {
this.url = url;
}
@Override
public String getContentId() {
return contentId;
}
@Override
public void setContentId(String contentId) {
this.contentId = contentId;
}
@Override
public ByteArrayEntity getContent() {
return content;
}
@Override
public void setContent(ByteArrayEntity content) {
this.content = content;
}
@Override
public void setUserId(String userId) {
this.userId = userId;
}
@Override
public String getUserId() {
return userId;
}
@Override
public Date getTime() {
return time;
}
@Override
public void setTime(Date time) {
this.time = time;
}
}