Package tigase.http.upload.logic
Class DefaultLogic
java.lang.Object
tigase.http.upload.logic.DefaultLogic
- All Implemented Interfaces:
Logic
@Bean(name="logic",
parent=FileUploadComponent.class,
active=true,
exportable=true)
public class DefaultLogic
extends Object
implements Logic
Created by andrzej on 07.08.2016.
-
Nested Class Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
generateURI
(UriFormat format, tigase.xmpp.jid.JID requester, String slotId, String filename) getDownloadURI
(tigase.xmpp.jid.JID requester, String slotId, String filename) long
getUploadURI
(tigase.xmpp.jid.JID requester, String slotId, String filename) void
removeExpired
(Duration expirationTime, int limit) requestSlot
(tigase.xmpp.jid.JID requester, String filename, long filesize, String contentType) void
setDownloadUriFormat
(String format) void
setUploadUriFormat
(String format)
-
Constructor Details
-
DefaultLogic
public DefaultLogic()
-
-
Method Details
-
getUploadUriFormat
-
setUploadUriFormat
-
getDownloadUriFormat
-
setDownloadUriFormat
-
getMaxFileSize
public long getMaxFileSize()- Specified by:
getMaxFileSize
in interfaceLogic
-
requestSlot
public String requestSlot(tigase.xmpp.jid.JID requester, String filename, long filesize, String contentType) throws tigase.component.exceptions.ComponentException - Specified by:
requestSlot
in interfaceLogic
- Throws:
tigase.component.exceptions.ComponentException
-
getUploadURI
- Specified by:
getUploadURI
in interfaceLogic
-
getDownloadURI
- Specified by:
getDownloadURI
in interfaceLogic
-
generateSlotId
- Specified by:
generateSlotId
in interfaceLogic
-
getUploadURIFormat
- Specified by:
getUploadURIFormat
in interfaceLogic
-
getDownloadURIFormat
- Specified by:
getDownloadURIFormat
in interfaceLogic
-
removeExpired
- Specified by:
removeExpired
in interfaceLogic
-
generateURI
-