Package de.xima.fc.gui.model.portal
Class UserPortalFileViewModel
- java.lang.Object
-
- de.xima.fc.gui.model.portal.UserPortalFileViewModel
-
- All Implemented Interfaces:
Serializable
public final class UserPortalFileViewModel extends Object implements Serializable
A temporary file stored on the file system.- Since:
- 8.2.0
- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description UserPortalFileViewModel(UserPortalFileEntityViewModel entity, Path path, String fileName, long size, String contentType, Instant lastModified)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetContentType()The file's content type.UserPortalFileEntityViewModelgetEntity()The entity associated with the file.StringgetFileName()The file's name.InstantgetLastModified()PathgetPath()The file's path on the file system.longgetSize()intgetSizeInt()The file's size in bytes, as an integer.
-
-
-
Constructor Detail
-
UserPortalFileViewModel
public UserPortalFileViewModel(UserPortalFileEntityViewModel entity, Path path, String fileName, long size, String contentType, Instant lastModified)
-
-
Method Detail
-
getPath
public Path getPath()
The file's path on the file system.- Returns:
- The file's path on the file system.
-
getSizeInt
public int getSizeInt()
The file's size in bytes, as an integer.- Returns:
- The file's size in bytes.
-
getContentType
public String getContentType()
The file's content type.
-
getEntity
public UserPortalFileEntityViewModel getEntity()
The entity associated with the file. This is used to identify the entity with the file in the database.
-
getFileName
public String getFileName()
The file's name. Note that this is not the name of the file on the file system, but the original file name. Therefore, it may not be unique and may use a temporary file name.
-
getLastModified
public Instant getLastModified()
-
getSize
public long getSize()
-
-