Class HTMLUploadImageProcessorImpl
- java.lang.Object
-
- org.exoplatform.social.common.service.impl.HTMLUploadImageProcessorImpl
-
- All Implemented Interfaces:
HTMLUploadImageProcessor
public class HTMLUploadImageProcessorImpl extends Object implements HTMLUploadImageProcessor
-
-
Constructor Summary
Constructors Constructor Description HTMLUploadImageProcessorImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringprocessImages(String content, String locationId, String imagesSubLocationPath)Process the given HTML content, extract temporary uploaded files and replace URLs in the HTML content with the permanent URLsStringprocessImagesForExport(String content)Process the given HTML content, export Files and replace URLs in the HTML content with files nameStringprocessSpaceImages(String content, String spaceGroupId, String imagesSubLocationPath)Process the given HTML content, extract temporary uploaded files and replace URLs in the HTML content with the permanent URLsStringprocessUserImages(String content, String userId, String imagesSubLocationPath)Process the given HTML content, extract temporary uploaded files and replace URLs in the HTML content with the permanent URLsvoiduploadSpaceFile(String filePath, String spaceGroupId, String fileName, String imagesSubLocationPath)voiduploadUserFile(String filePath, String userId, String fileName, String imagesSubLocationPath)
-
-
-
Method Detail
-
processImages
public String processImages(String content, String locationId, String imagesSubLocationPath)
Description copied from interface:HTMLUploadImageProcessorProcess the given HTML content, extract temporary uploaded files and replace URLs in the HTML content with the permanent URLs- Specified by:
processImagesin interfaceHTMLUploadImageProcessor- Parameters:
content- The HTML contentlocationId- The location to store the images.imagesSubLocationPath- The subpath of the folder under parentNode to store the images. If the nodes of this path do not exist, they are automatically created, only if there are images to store.- Returns:
- The updated HTML content with the permanent images URLs
-
processSpaceImages
public String processSpaceImages(String content, String spaceGroupId, String imagesSubLocationPath)
Description copied from interface:HTMLUploadImageProcessorProcess the given HTML content, extract temporary uploaded files and replace URLs in the HTML content with the permanent URLs- Specified by:
processSpaceImagesin interfaceHTMLUploadImageProcessor- Parameters:
content- The HTML contentspaceGroupId- The space group ID to store the image under it's content.imagesSubLocationPath- The subpath of the folder under parentNode to store the images. If the nodes of this path do not exist, they are automatically created, only if there are images to store.- Returns:
- The updated HTML content with the permanent images URLs
-
processUserImages
public String processUserImages(String content, String userId, String imagesSubLocationPath)
Description copied from interface:HTMLUploadImageProcessorProcess the given HTML content, extract temporary uploaded files and replace URLs in the HTML content with the permanent URLs- Specified by:
processUserImagesin interfaceHTMLUploadImageProcessor- Parameters:
content- The HTML contentuserId- The user ID to store the image under he's content.imagesSubLocationPath- The subpath of the folder under parentNode to store the images. If the nodes of this path do not exist, they are automatically created, only if there are images to store.- Returns:
- The updated HTML content with the permanent images URLs
-
processImagesForExport
public String processImagesForExport(String content)
Description copied from interface:HTMLUploadImageProcessorProcess the given HTML content, export Files and replace URLs in the HTML content with files name- Specified by:
processImagesForExportin interfaceHTMLUploadImageProcessor- Parameters:
content- The HTML content- Returns:
- The updated HTML content with the images name
-
uploadSpaceFile
public void uploadSpaceFile(String filePath, String spaceGroupId, String fileName, String imagesSubLocationPath)
- Specified by:
uploadSpaceFilein interfaceHTMLUploadImageProcessor
-
uploadUserFile
public void uploadUserFile(String filePath, String userId, String fileName, String imagesSubLocationPath)
- Specified by:
uploadUserFilein interfaceHTMLUploadImageProcessor
-
-