Package omero.gateway.model
Class FileAnnotationData
- java.lang.Object
-
- omero.gateway.model.DataObject
-
- omero.gateway.model.AnnotationData
-
- omero.gateway.model.FileAnnotationData
-
public class FileAnnotationData extends AnnotationData
Annotation to upload files to the server.- Since:
- OME3.0
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
BULK_ANNOTATIONS_NS
The name space used to indicate that theFileAnnotation
is aBulk Annotations
file.static java.lang.String
COMPANION_FILE_NS
The name space used to indicate that theFileAnnotation
is a companion file.static java.lang.String
CSV
Identifies theCSV
file formats.static java.lang.String
EXPERIMENTER_PHOTO_NS
The name space used to identify the experimenter photo.static java.lang.String
FLIM_NS
Identifies the FLIM namespace.static java.lang.String
HTM
Identifies theHTM
file formats.static java.lang.String
HTML
Identifies theHTML
file formats.static java.lang.String
LOG_FILE_NS
The name space used to indicate that theFileAnnotation
is an import log file.static java.lang.String
MEASUREMENT_NS
The name space used to indicate that theFileAnnotation
is aMeasurement
file.static java.lang.String
MOVIE_NS
The name space used to indicate that theFileAnnotation
is a movie.static java.lang.String
MS_EXCEL
Identifies theExcel
file formats.static java.lang.String
MS_POWER_POINT
Identifies thePower point
file formats.static java.lang.String
MS_POWER_POINT_SHOW
Identifies thePower point
file formats.static java.lang.String
MS_POWER_POINT_X
Identifies thePower point
file formats.static java.lang.String
MS_WORD
Identifies theWord
file formats.static java.lang.String
MS_WORD_X
Identifies theWord
file formats.static java.lang.String
ORIGINAL_METADATA_NAME
The default name for the original metadata file.static java.lang.String
PDF
Identifies thePDF
file formats.static java.lang.String
RTF
Identifies theRTF
file formats.static java.lang.String
TEXT
Identifies theText
file formats.static java.lang.String
UNKNOWN
Indicates that the format is not recognized.static java.lang.String
XML
Identifies theXML
file formats.-
Fields inherited from class omero.gateway.model.AnnotationData
FILE_TRANSFER_NS
-
-
Constructor Summary
Constructors Constructor Description FileAnnotationData(java.io.File file)
Creates a new instance.FileAnnotationData(omero.model.FileAnnotation annotation)
Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.File
getAttachedFile()
Returns the file to upload to the server.java.lang.Object
getContent()
Returns the original file.java.lang.String
getContentAsString()
Returns the absolute path to the filejava.lang.String
getDescription()
Returns the description of the annotation.omero.model.OriginalFile
getFile()
Returns the original file if loaded,null
otherwise.java.lang.String
getFileFormat()
Returns the format of the uploaded file.long
getFileID()
Returns the id of the file.java.lang.String
getFileKind()
Returns a user readable description of the file.java.lang.String
getFileName()
Returns the name of the file.java.lang.String
getFilePath()
Returns the absolute path to the file.long
getFileSize()
Returns the size of the file.java.lang.String
getOriginalMimetype()
Returns the format of the original file.java.lang.String
getServerFileMimetype()
Returns the file format as defined by the specification, corresponding to the file extension.boolean
isMovieFile()
Returnstrue
if it is a movie file.void
setContent(java.lang.Object content)
Sets the text annotation.void
setDescription(java.lang.String description)
Sets the description of the annotation.-
Methods inherited from class omero.gateway.model.AnnotationData
getLastModified, getNameSpace, setNameSpace
-
Methods inherited from class omero.gateway.model.DataObject
asAnnotation, asChannel, asDataset, asExperimenter, asFolder, asGroup, asIAnnotated, asImage, asIObject, asPixels, asPlaneInfo, asPlate, asPojo, asPojos, asPojos, asProject, asScreen, asWell, asWellSample, canAnnotate, canChgrp, canChown, canDelete, canEdit, canLink, getCreated, getDetails, getGroupId, getId, getOwner, getPermissions, getUpdated, getVersion, isDirty, isLoaded, nullDetails, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, nullSafe, setDirty, setId, setValue, setVersion, timeOfEvent, toString
-
-
-
-
Field Detail
-
FLIM_NS
public static final java.lang.String FLIM_NS
Identifies the FLIM namespace.- See Also:
- Constant Field Values
-
EXPERIMENTER_PHOTO_NS
public static final java.lang.String EXPERIMENTER_PHOTO_NS
The name space used to identify the experimenter photo.- See Also:
- Constant Field Values
-
COMPANION_FILE_NS
public static final java.lang.String COMPANION_FILE_NS
The name space used to indicate that theFileAnnotation
is a companion file.- See Also:
- Constant Field Values
-
LOG_FILE_NS
public static final java.lang.String LOG_FILE_NS
The name space used to indicate that theFileAnnotation
is an import log file.- See Also:
- Constant Field Values
-
MOVIE_NS
public static final java.lang.String MOVIE_NS
The name space used to indicate that theFileAnnotation
is a movie.- See Also:
- Constant Field Values
-
MEASUREMENT_NS
public static final java.lang.String MEASUREMENT_NS
The name space used to indicate that theFileAnnotation
is aMeasurement
file.- See Also:
- Constant Field Values
-
BULK_ANNOTATIONS_NS
public static final java.lang.String BULK_ANNOTATIONS_NS
The name space used to indicate that theFileAnnotation
is aBulk Annotations
file.- See Also:
- Constant Field Values
-
ORIGINAL_METADATA_NAME
public static final java.lang.String ORIGINAL_METADATA_NAME
The default name for the original metadata file.- See Also:
- Constant Field Values
-
PDF
public static final java.lang.String PDF
Identifies thePDF
file formats.- See Also:
- Constant Field Values
-
TEXT
public static final java.lang.String TEXT
Identifies theText
file formats.- See Also:
- Constant Field Values
-
CSV
public static final java.lang.String CSV
Identifies theCSV
file formats.- See Also:
- Constant Field Values
-
XML
public static final java.lang.String XML
Identifies theXML
file formats.- See Also:
- Constant Field Values
-
HTML
public static final java.lang.String HTML
Identifies theHTML
file formats.- See Also:
- Constant Field Values
-
HTM
public static final java.lang.String HTM
Identifies theHTM
file formats.- See Also:
- Constant Field Values
-
MS_WORD
public static final java.lang.String MS_WORD
Identifies theWord
file formats.- See Also:
- Constant Field Values
-
MS_WORD_X
public static final java.lang.String MS_WORD_X
Identifies theWord
file formats.- See Also:
- Constant Field Values
-
MS_EXCEL
public static final java.lang.String MS_EXCEL
Identifies theExcel
file formats.- See Also:
- Constant Field Values
-
MS_POWER_POINT
public static final java.lang.String MS_POWER_POINT
Identifies thePower point
file formats.- See Also:
- Constant Field Values
-
MS_POWER_POINT_X
public static final java.lang.String MS_POWER_POINT_X
Identifies thePower point
file formats.- See Also:
- Constant Field Values
-
MS_POWER_POINT_SHOW
public static final java.lang.String MS_POWER_POINT_SHOW
Identifies thePower point
file formats.- See Also:
- Constant Field Values
-
RTF
public static final java.lang.String RTF
Identifies theRTF
file formats.- See Also:
- Constant Field Values
-
UNKNOWN
public static final java.lang.String UNKNOWN
Indicates that the format is not recognized.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
FileAnnotationData
public FileAnnotationData(java.io.File file)
Creates a new instance.- Parameters:
file
- The file to attach.
-
FileAnnotationData
public FileAnnotationData(omero.model.FileAnnotation annotation)
Creates a new instance.- Parameters:
annotation
- The annotation to wrap.
-
-
Method Detail
-
getFile
public omero.model.OriginalFile getFile()
Returns the original file if loaded,null
otherwise.- Returns:
- See above.
-
getOriginalMimetype
public java.lang.String getOriginalMimetype()
Returns the format of the original file.- Returns:
- See above.
-
setDescription
public void setDescription(java.lang.String description)
Sets the description of the annotation.- Overrides:
setDescription
in classAnnotationData
- Parameters:
description
- The value to set.
-
getDescription
public java.lang.String getDescription()
Returns the description of the annotation.- Overrides:
getDescription
in classAnnotationData
- Returns:
- See above.
-
getServerFileMimetype
public java.lang.String getServerFileMimetype()
Returns the file format as defined by the specification, corresponding to the file extension.- Returns:
- See above.
-
getFileFormat
public java.lang.String getFileFormat()
Returns the format of the uploaded file.- Returns:
- See above.
-
getFileKind
public java.lang.String getFileKind()
Returns a user readable description of the file.- Returns:
- See above.
-
getAttachedFile
public java.io.File getAttachedFile()
Returns the file to upload to the server.- Returns:
- See above.
-
getFileName
public java.lang.String getFileName()
Returns the name of the file.- Returns:
- See above.
-
getFilePath
public java.lang.String getFilePath()
Returns the absolute path to the file.- Returns:
- See above.
-
getFileSize
public long getFileSize()
Returns the size of the file.- Returns:
- See above.
-
getFileID
public long getFileID()
Returns the id of the file.- Returns:
- See above.
-
getContent
public java.lang.Object getContent()
Returns the original file.- Specified by:
getContent
in classAnnotationData
- Returns:
- See above.
- See Also:
AnnotationData.getContent()
-
getContentAsString
public java.lang.String getContentAsString()
Returns the absolute path to the file- Specified by:
getContentAsString
in classAnnotationData
- Returns:
- See above
- See Also:
AnnotationData.getContentAsString()
-
isMovieFile
public boolean isMovieFile()
Returnstrue
if it is a movie file.false
otherwise.- Returns:
- See above.
-
setContent
public void setContent(java.lang.Object content)
Sets the text annotation.- Specified by:
setContent
in classAnnotationData
- Parameters:
content
- The value to set.- See Also:
AnnotationData.setContent(Object)
-
-