public class

KnowledgeConfiguration

extends Object
java.lang.Object
   ↳ com.salesforce.android.knowledge.core.KnowledgeConfiguration

Class Overview

Configuration class used in the creation of a KnowledgeClient instance via KnowledgeCore.

Summary

Nested Classes
class KnowledgeConfiguration.Builder Builder for KnowledgeConfiguration instances. 
Public Methods
static KnowledgeConfiguration.Builder builder(String communityUrl)
Instantiate a builder that can be used to customize KnowledgeConfiguration instances.
static KnowledgeConfiguration create(String communityUrl)
Create a new KnowledgeConfiguration instance by providing your Community URL.
AuthTokenProvider getAuthTokenProvider()
Returns the AuthTokenProvider to be used for offline caching and authenticated http requests.
AuthenticatedUser getAuthenticatedUser()
Returns the AuthenticatedUser which provides a unique key identifying the logged in user.
String getCommunityUrl()
The Community URL indicates which community will be accessed by the KnowledgeClient instance.
String getFallbackLocale()
The Locale string to use if the initial locale is not available from the online knowledge base.
String getInitialLocale()
The locale string to use when fetching content from the online knowledge base.
OfflineResourceConfig getOfflineResourceConfig()
The OfflineResourceConfig configures how the KnowledgeClient will treat article resources (e.g.
[Expand]
Inherited Methods
From class java.lang.Object

Public Methods

public static KnowledgeConfiguration.Builder builder (String communityUrl)

Instantiate a builder that can be used to customize KnowledgeConfiguration instances.

Parameters
communityUrl The communityUrl for the community that will be accessed by the KnowledgeClient. Example: https://my.community.force.com. See the developer docs for more information on where to find this value.
Returns

public static KnowledgeConfiguration create (String communityUrl)

Create a new KnowledgeConfiguration instance by providing your Community URL. This is a convenience method for build().

Parameters
communityUrl The communityUrl for the community that will be accessed by the KnowledgeClient. Example: https://my.community.force.com. See the developer docs for more information on where to find this value.
Returns

public AuthTokenProvider getAuthTokenProvider ()

Returns the AuthTokenProvider to be used for offline caching and authenticated http requests.

Returns
  • The AuthTokenProvider to be used.

public AuthenticatedUser getAuthenticatedUser ()

Returns the AuthenticatedUser which provides a unique key identifying the logged in user.

Returns
  • The AuthenticatedUser associated with authenticated http requests.

public String getCommunityUrl ()

The Community URL indicates which community will be accessed by the KnowledgeClient instance.

Returns
  • The Community URL.

public String getFallbackLocale ()

The Locale string to use if the initial locale is not available from the online knowledge base.

Returns
  • The fallback locale.

public String getInitialLocale ()

The locale string to use when fetching content from the online knowledge base.

Returns
  • The locale string.

public OfflineResourceConfig getOfflineResourceConfig ()

The OfflineResourceConfig configures how the KnowledgeClient will treat article resources (e.g. images embedded in the article content) for offline caching purposes. By default this caching is disabled, but it may be enabled by calling offlineResourceConfig(OfflineResourceConfig).

Returns