Class AddDocumentOptions
java.lang.Object
com.ibm.cloud.sdk.core.service.model.GenericModel
com.ibm.watson.discovery.v1.model.AddDocumentOptions
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel
public class AddDocumentOptions
extends com.ibm.cloud.sdk.core.service.model.GenericModel
The addDocument options.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AddDocumentOptions.Builder
Builder. -
Method Summary
Modifier and Type Method Description String
collectionId()
Gets the collectionId.String
environmentId()
Gets the environmentId.InputStream
file()
Gets the file.String
fileContentType()
Gets the fileContentType.String
filename()
Gets the filename.String
metadata()
Gets the metadata.AddDocumentOptions.Builder
newBuilder()
New builder.Methods inherited from class com.ibm.cloud.sdk.core.service.model.GenericModel
equals, hashCode, toString
-
Method Details
-
newBuilder
New builder.- Returns:
- a AddDocumentOptions builder
-
environmentId
Gets the environmentId.The ID of the environment.
- Returns:
- the environmentId
-
collectionId
Gets the collectionId.The ID of the collection.
- Returns:
- the collectionId
-
file
Gets the file.The content of the document to ingest. The maximum supported file size when adding a file to a collection is 50 megabytes, the maximum supported file size when testing a configuration is 1 megabyte. Files larger than the supported size are rejected.
- Returns:
- the file
-
filename
Gets the filename.The filename for file.
- Returns:
- the filename
-
fileContentType
Gets the fileContentType.The content type of file. Values for this parameter can be obtained from the HttpMediaType class.
- Returns:
- the fileContentType
-
metadata
Gets the metadata.The maximum supported metadata file size is 1 MB. Metadata parts larger than 1 MB are rejected. Example: ``` { "Creator": "Johnny Appleseed", "Subject": "Apples" } ```.
- Returns:
- the metadata
-