Class ImportJobRequest
java.lang.Object
org.xwiki.job.AbstractRequest
org.xwiki.contrib.moccacalendar.importJob.ImportJobRequest
- All Implemented Interfaces:
Serializable,org.xwiki.job.Request
@Unstable
public class ImportJobRequest
extends org.xwiki.job.AbstractRequest
Represents a request to start a import job.
- Since:
- 2.14
- Version:
- $Id$
- See Also:
-
Field Summary
Fields inherited from interface org.xwiki.job.Request
PROPERTY_CONTEXT, PROPERTY_INTERACTIVE, PROPERTY_REMOTE -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.ImportJobRequest(List<String> requestId, byte[] file, String parentRef, org.xwiki.model.reference.DocumentReference userReference) Creates a specific request for the ical file import job. -
Method Summary
Modifier and TypeMethodDescriptionbyte[]getFile()Get the content of the given file.Get the reference to the parent calendar.org.xwiki.model.reference.DocumentReferenceGet the reference to the user who requested the import.Methods inherited from class org.xwiki.job.AbstractRequest
containsProperty, equals, getContext, getId, getProperties, getProperty, getProperty, getPropertyNames, hashCode, isInteractive, isRemote, isStatusLogIsolated, isStatusSerialized, isVerbose, removeProperty, setContext, setId, setId, setId, setInteractive, setProperty, setRemote, setStatusLogIsolated, setStatusSerialized, setVerbose
-
Constructor Details
-
ImportJobRequest
public ImportJobRequest()Default constructor. -
ImportJobRequest
public ImportJobRequest(List<String> requestId, byte[] file, String parentRef, org.xwiki.model.reference.DocumentReference userReference) Creates a specific request for the ical file import job.- Parameters:
requestId- the ID of the request.file- the file to be processed.parentRef- the reference to the parent calendar.userReference- the user who requests the job.
-
-
Method Details
-
getFile
public byte[] getFile()Get the content of the given file.- Returns:
- the content of the file as a
Bytearray.
-
getParentRef
Get the reference to the parent calendar.- Returns:
- the reference to the parent calendar.
-
getUserReference
public org.xwiki.model.reference.DocumentReference getUserReference()Get the reference to the user who requested the import.- Returns:
- the reference to the user.
-