WebKnowledgeSource Class

public final class WebKnowledgeSource
extends KnowledgeSource

Knowledge Source targeting web results.

Constructor Summary

Constructor Description
WebKnowledgeSource(String name)

Creates an instance of WebKnowledgeSource class.

Method Summary

Modifier and Type Method and Description
static WebKnowledgeSource fromJson(JsonReader jsonReader)

Reads an instance of WebKnowledgeSource from the JsonReader.

KnowledgeSourceKind getKind()

Get the kind property: The type of the knowledge source.

WebKnowledgeSourceParameters getWebParameters()

Get the webParameters property: The parameters for the web knowledge source.

WebKnowledgeSource setDescription(String description)

Set the description property: Optional user-defined description.

WebKnowledgeSource setEncryptionKey(SearchResourceEncryptionKey encryptionKey)

Set the encryptionKey property: A description of an encryption key that you create in Azure Key Vault.

WebKnowledgeSource setETag(String eTag)

Set the eTag property: The ETag of the knowledge source.

WebKnowledgeSource setWebParameters(WebKnowledgeSourceParameters webParameters)

Set the webParameters property: The parameters for the web knowledge source.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from KnowledgeSource

Methods inherited from java.lang.Object

Constructor Details

WebKnowledgeSource

public WebKnowledgeSource(String name)

Creates an instance of WebKnowledgeSource class.

Parameters:

name - the name value to set.

Method Details

fromJson

public static WebKnowledgeSource fromJson(JsonReader jsonReader)

Reads an instance of WebKnowledgeSource from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of WebKnowledgeSource if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

getKind

public KnowledgeSourceKind getKind()

Get the kind property: The type of the knowledge source.

Overrides:

WebKnowledgeSource.getKind()

Returns:

the kind value.

getWebParameters

public WebKnowledgeSourceParameters getWebParameters()

Get the webParameters property: The parameters for the web knowledge source.

Returns:

the webParameters value.

setDescription

public WebKnowledgeSource setDescription(String description)

Set the description property: Optional user-defined description.

Overrides:

WebKnowledgeSource.setDescription(String description)

Parameters:

description

setEncryptionKey

public WebKnowledgeSource 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:

WebKnowledgeSource.setEncryptionKey(SearchResourceEncryptionKey encryptionKey)

Parameters:

encryptionKey

setETag

public WebKnowledgeSource setETag(String eTag)

Set the eTag property: The ETag of the knowledge source.

Overrides:

WebKnowledgeSource.setETag(String eTag)

Parameters:

eTag

setWebParameters

public WebKnowledgeSource setWebParameters(WebKnowledgeSourceParameters webParameters)

Set the webParameters property: The parameters for the web knowledge source.

Parameters:

webParameters - the webParameters value to set.

Returns:

the WebKnowledgeSource object itself.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

WebKnowledgeSource.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to