Package zendesk.support.guide
Class HelpCenterActivity
- java.lang.Object
- 
- AppCompatActivity
- 
- zendesk.support.guide.HelpCenterActivity
 
 
- 
- All Implemented Interfaces:
- zendesk.support.guide.HelpCenterMvp.View
 
 
 public class HelpCenterActivity extends AppCompatActivity implements zendesk.support.guide.HelpCenterMvp.ViewThis Activity is the main entry point for showing Help Center content in the SDK.This Activity is designed to be started with the HelpCenterActivity.builder()
- 
- 
Constructor SummaryConstructors Constructor and Description HelpCenterActivity()
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidannounceContentLoaded()Announce that the content has loaded, for accessibility purposes.static HelpCenterUiConfig.Builderbuilder()Create a new builder for HelpCenterActivity.voidclearSearchResults()Clears any currently shown search results from the view.voiddismissError()Dismiss the error Snackbar if it is currently displayed.voidexitActivity()Exits the activity immediatelyContextgetContext()Gets the View's context.voidhideLoadingState()Hides the loading statebooleanisShowingHelp()Tells whether the view is currently showing the Help Center, or Search results.protected voidonCreate(Bundle savedInstanceState)booleanonCreateOptionsMenu(Menu menu)booleanonOptionsItemSelected(MenuItem item)protected voidonPause()booleanonPrepareOptionsMenu(Menu menu)protected voidonResume()protected voidonStart()voidsetSearchEnabled(boolean enabled)Set the enabled state of the search menuitemvoidshowContactUsButton()Shows the contact us button as a FABvoidshowContactZendesk()Shows the contact Zendesk componentvoidshowHelp(HelpCenterUiConfig helpCenterUiConfig)Shows Help for the given SDK UI configuration.voidshowLoadArticleErrorWithRetry(zendesk.support.guide.HelpCenterMvp.ErrorType errorType, RetryAction action)Shows a snackbar with an error message and a retry actionvoidshowLoadingState()Shows a loading statevoidshowNoConnectionError()Shows a Snackbar with an error messagevoidshowRequestList()Shows the list of requests that the user has createdvoidshowSearchResults(java.util.List<SearchArticle> searchArticles, java.lang.String query)Shows Help search results for the given query text
 
- 
- 
- 
Method Detail- 
builderpublic static HelpCenterUiConfig.Builder builder() Create a new builder for HelpCenterActivity.
 - 
onCreateprotected void onCreate(Bundle savedInstanceState) 
 - 
onStartprotected void onStart() 
 - 
onResumeprotected void onResume() 
 - 
onPauseprotected void onPause() 
 - 
onCreateOptionsMenupublic boolean onCreateOptionsMenu(Menu menu) 
 - 
onPrepareOptionsMenupublic boolean onPrepareOptionsMenu(Menu menu) 
 - 
onOptionsItemSelectedpublic boolean onOptionsItemSelected(MenuItem item) 
 - 
showContactUsButtonpublic void showContactUsButton() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows the contact us button as a FAB- Specified by:
- showContactUsButtonin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
showHelppublic void showHelp(HelpCenterUiConfig helpCenterUiConfig) Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows Help for the given SDK UI configuration.- Specified by:
- showHelpin interface- zendesk.support.guide.HelpCenterMvp.View
- Parameters:
- helpCenterUiConfig- The HelpCenterUiConfig containing the category and section IDs, label names, and configuration flags to be used in displaying the UI.
 
 - 
showLoadingStatepublic void showLoadingState() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows a loading state- Specified by:
- showLoadingStatein interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
hideLoadingStatepublic void hideLoadingState() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewHides the loading state- Specified by:
- hideLoadingStatein interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
showSearchResultspublic void showSearchResults(java.util.List<SearchArticle> searchArticles, java.lang.String query) Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows Help search results for the given query text- Specified by:
- showSearchResultsin interface- zendesk.support.guide.HelpCenterMvp.View
- Parameters:
- searchArticles- The List of articles returned for the search
- query- The query text that was used in the search
 
 - 
clearSearchResultspublic void clearSearchResults() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewClears any currently shown search results from the view.- Specified by:
- clearSearchResultsin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
setSearchEnabledpublic void setSearchEnabled(boolean enabled) Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewSet the enabled state of the search menuitem- Specified by:
- setSearchEnabledin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
isShowingHelppublic boolean isShowingHelp() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewTells whether the view is currently showing the Help Center, or Search results. While this is the kind of logical decision normally calculated by the presenter, in this case, with state changes etc, the view is the ultimate source of truth.- Specified by:
- isShowingHelpin interface- zendesk.support.guide.HelpCenterMvp.View
- Returns:
- true if the currently displayed view is the Help Center, false if it's search results.
 
 - 
showRequestListpublic void showRequestList() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows the list of requests that the user has created- Specified by:
- showRequestListin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
showContactZendeskpublic void showContactZendesk() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows the contact Zendesk component- Specified by:
- showContactZendeskin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
showLoadArticleErrorWithRetrypublic void showLoadArticleErrorWithRetry(zendesk.support.guide.HelpCenterMvp.ErrorType errorType, RetryAction action)Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows a snackbar with an error message and a retry action- Specified by:
- showLoadArticleErrorWithRetryin interface- zendesk.support.guide.HelpCenterMvp.View
- Parameters:
- errorType- The type of error to display a message for
- action- The retry action to perform
 
 - 
showNoConnectionErrorpublic void showNoConnectionError() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewShows a Snackbar with an error message- Specified by:
- showNoConnectionErrorin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
dismissErrorpublic void dismissError() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewDismiss the error Snackbar if it is currently displayed.- Specified by:
- dismissErrorin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
getContextpublic Context getContext() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewGets the View's context.- Specified by:
- getContextin interface- zendesk.support.guide.HelpCenterMvp.View
- Returns:
- The Context of the View implementation.
 
 - 
exitActivitypublic void exitActivity() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewExits the activity immediately- Specified by:
- exitActivityin interface- zendesk.support.guide.HelpCenterMvp.View
 
 - 
announceContentLoadedpublic void announceContentLoaded() Description copied from interface:zendesk.support.guide.HelpCenterMvp.ViewAnnounce that the content has loaded, for accessibility purposes.- Specified by:
- announceContentLoadedin interface- zendesk.support.guide.HelpCenterMvp.View
 
 
- 
 
-