FileKnowledgeSource Class
- java.
lang. Object - com.
azure. search. documents. indexes. models. KnowledgeSource - com.
azure. search. documents. indexes. models. FileKnowledgeSource
- com.
- com.
public final class FileKnowledgeSource
extends KnowledgeSource
Configuration for File knowledge source that supports direct file upload and indexing.
Constructor Summary
| Constructor | Description |
|---|---|
| FileKnowledgeSource(String name, FileKnowledgeSourceParameters fileParameters) |
Creates an instance of File |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
static
File |
fromJson(JsonReader jsonReader)
Reads an instance of File |
|
Cors |
getCorsOptions()
Get the cors |
|
File |
getFileParameters()
Get the file |
|
Knowledge |
getKind()
Get the kind property: The type of the knowledge source. |
|
File |
setCorsOptions(CorsOptions corsOptions)
Set the cors |
|
File |
setDescription(String description)
Set the description property: Optional user-defined description. |
|
File |
setEncryptionKey(SearchResourceEncryptionKey encryptionKey)
Set the encryption |
|
File |
setETag(String eTag)
Set the e |
|
Json |
toJson(JsonWriter jsonWriter) |
Methods inherited from KnowledgeSource
Methods inherited from java.lang.Object
Constructor Details
FileKnowledgeSource
public FileKnowledgeSource(String name, FileKnowledgeSourceParameters fileParameters)
Creates an instance of FileKnowledgeSource class.
Parameters:
Method Details
fromJson
public static FileKnowledgeSource fromJson(JsonReader jsonReader)
Reads an instance of FileKnowledgeSource from the JsonReader.
Parameters:
Returns:
Throws:
getCorsOptions
public CorsOptions getCorsOptions()
Get the corsOptions property: Options to control Cross-Origin Resource Sharing (CORS) for the File knowledge source's file endpoints (upload, list, update, delete).
Returns:
getFileParameters
public FileKnowledgeSourceParameters getFileParameters()
Get the fileParameters property: The parameters for the File knowledge source.
Returns:
getKind
public KnowledgeSourceKind getKind()
Get the kind property: The type of the knowledge source.
Overrides:
FileKnowledgeSource.getKind()Returns:
setCorsOptions
public FileKnowledgeSource setCorsOptions(CorsOptions corsOptions)
Set the corsOptions property: Options to control Cross-Origin Resource Sharing (CORS) for the File knowledge source's file endpoints (upload, list, update, delete).
Parameters:
Returns:
setDescription
public FileKnowledgeSource setDescription(String description)
Set the description property: Optional user-defined description.
Overrides:
FileKnowledgeSource.setDescription(String description)Parameters:
setEncryptionKey
public FileKnowledgeSource setEncryptionKey(SearchResourceEncryptionKey encryptionKey)
Set the encryptionKey property: A description of an encryption key that you create in Azure Key Vault. This key is used to provide an additional level of encryption-at-rest for your knowledge source definition when you want full assurance that no one, not even Microsoft, can decrypt them. Once you have encrypted your knowledge source definition, it will always remain encrypted. The search service will ignore attempts to set this property to null. You can change this property as needed if you want to rotate your encryption key; Your knowledge source definition will be unaffected. Encryption with customer-managed keys is not available for free search services, and is only available for paid services created on or after January 1, 2019.
Overrides:
FileKnowledgeSource.setEncryptionKey(SearchResourceEncryptionKey encryptionKey)Parameters:
setETag
public FileKnowledgeSource setETag(String eTag)
Set the eTag property: The ETag of the knowledge source.
Overrides:
FileKnowledgeSource.setETag(String eTag)Parameters:
toJson
public JsonWriter toJson(JsonWriter jsonWriter)
Overrides:
FileKnowledgeSource.toJson(JsonWriter jsonWriter)Parameters:
Throws: