Class GridFsObject.Options
java.lang.Object
org.springframework.data.mongodb.gridfs.GridFsObject.Options
- Enclosing interface:
- GridFsObject<ID,
CONTENT>
Additional, context relevant information.
- Author:
- Christoph Strobl
-
Method Summary
Modifier and TypeMethodDescriptionchunkSize(int chunkSize) contentType(String contentType) Set the associated content type.static GridFsObject.Optionsfrom(GridFSFile gridFSFile) Static factory method to createGridFsObject.Optionsby extracting information from the givenGridFSFile.intstatic GridFsObject.Optionsnone()Static factory to create empty options.static GridFsObject.OptionsStatic factory method to createGridFsObject.Optionswith given content type.
-
Method Details
-
none
Static factory to create empty options.- Returns:
- new instance of
GridFsObject.Options.
-
typed
Static factory method to createGridFsObject.Optionswith given content type.- Parameters:
contentType-- Returns:
- new instance of
GridFsObject.Options.
-
from
Static factory method to createGridFsObject.Optionsby extracting information from the givenGridFSFile.- Parameters:
gridFSFile- can be null, returnsnone()in that case.- Returns:
- new instance of
GridFsObject.Options.
-
contentType
Set the associated content type.- Parameters:
contentType- must not be null.- Returns:
- new instance of
GridFsObject.Options.
-
metadata
- Parameters:
metadata-- Returns:
- new instance of
GridFsObject.Options.
-
chunkSize
- Parameters:
chunkSize- the file chunk size to use.- Returns:
- new instance of
GridFsObject.Options.
-
getMetadata
- Returns:
- never null.
-
getChunkSize
public int getChunkSize()- Returns:
- the chunk size to use.
-