UgiUiUtil Class Reference

Overview


UgiUiUtil is a collection of static UI utilities for showing alerts.

It is used by UgiDefaultConfigurationUi to show UI for configuration

Class Methods

(UIColor *) + DEFAULT_THEME_COLOR
 Default color (a constant) More...
 
(UIColor *) + DEFAULT_TEXT_COLOR_ON_THEME_COLOR
 Default text color when on a background of the theme color (a constant) More...
 
(UIColor *) + DEFAULT_BUTTON_COLOR
 Default color for buttons (a constant) More...
 
(UIColor *) + DEFAULT_BUTTON_PRESSED_COLOR
 Default color for buttons when pressed (a constant) More...
 
(UIColor *) + DEFAULT_TEXT_COLOR_ON_BACKGROUND
 Default text color (a constant) More...
 
(UIColor *) + themeColor
 Default color for the app, defaults to DEFAULT_THEME_COLOR. More...
 
(void) + setThemeColor:
 Default color for the app, defaults to DEFAULT_THEME_COLOR. More...
 
(UIColor *) + textColorOnThemeColor
 Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_THEME_COLOR. More...
 
(void) + setTextColorOnThemeColor:
 Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_THEME_COLOR. More...
 
(UIColor *) + buttonColor
 Default color for buttons for the app, defaults to DEFAULT_BUTTON_COLOR. More...
 
(void) + setButtonColor:
 Default color for buttons for the app, defaults to DEFAULT_BUTTON_COLOR. More...
 
(UIColor *) + buttonPressedColor
 Default color for the app, defaults to DEFAULT_BUTTON_PRESSED_COLOR. More...
 
(void) + setButtonPressedColor:
 Default color for the app, defaults to DEFAULT_BUTTON_PRESSED_COLOR. More...
 
(UIColor *) + textColorOnBackground
 Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_BACKGROUND. More...
 
(void) + setTextColorOnBackground:
 Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_BACKGROUND. More...
 
(UIColor *) + themeColorToUse
 Color for the currently active UgiViewController. More...
 
(UIColor *) + textColorOnThemeColorToUse
 Color for the currently active UgiViewController. More...
 
(UIColor *) + buttonColorToUse
 Color for the currently active UgiViewController. More...
 
(UIColor *) + buttonPressedColorToUse
 Color for the currently active UgiViewController. More...
 
(UIColor *) + textColorOnBackgroundToUse
 Color for the currently active UgiViewController. More...
 
(CGSize) + screenSizeConsideringOrientation
 
Get the screen size, accounting for rotation More...
 
(nonnull id) + performCancellableBlockAfterSeconds:block:
 
Perform a cancellable block after a delay More...
 
(void) + cancelBlock:
 
Cancel a block scheduled with performCancellableBlockAfterSeconds:block: More...
 
(void) + hideUI:
 Hide UI shown with any of the showXXX methods. More...
 
(void) + updateAlert:withTitle:
 Update an alert's title. More...
 
(void) + updateAlert:withMessage:
 Update an alert's message. More...
 
(NSObject *_Nonnull) + showCancel:message:withCompletion:
 
Show an alert with a cancel button More...
 
(NSObject *_Nonnull) + showOk:message:
 
Show an alert with an ok button More...
 
(NSObject *_Nonnull) + showOk:message:withCompletion:
 
Show an alert with an ok button More...
 
(NSObject *_Nonnull) + showOk:message:okButtonTitle:withCompletion:
 
Show an alert with an ok button More...
 
(NSObject *_Nonnull) + showOkCancel:message:withCompletion:
 
Show an alert with ok and cancel buttons More...
 
(NSObject *_Nonnull) + showOkCancel:message:okButtonTitle:cancelButtonTitle:withCompletion:
 
Show an alert with ok and cancel buttons More...
 
(NSObject *_Nonnull) + showOkCancel:message:okButtonTitle:cancelButtonTitle:withCompletion:withCancelCompletion:
 
Show an alert with ok and cancel buttons More...
 
(NSObject *_Nonnull) + showTextInput:message:actionButtonTitle:initialText:allowAutoCorrection:keyboardType:switchText:switchInitialValue:withCompletion:withCancelCompletion:withShouldEnableForTextCompletion:
 
Input a text string from the user More...
 
(NSObject *_Nonnull) + show3ButtonAlert:message:button1Title:button2Title:cancelButtonTitle:button1Completion:button2Completion:withCancelCompletion:
 
Show an alert with three buttons More...
 
(NSObject *_Nonnull) + showManyButtonAlert:message:buttonTitles:cancelButtonTitle:withCompletion:
 
Show an alert with many buttons More...
 
(NSObject *_Nonnull) + showChoices:withInitialSelectedIndex:withTitle:withMessage:withActionButtonTitle:withCanCancel:withCompletion:withConfirmationCompletion:withCancelCompletion:
 
Show UI to choose from a list of choices More...
 
(NSObject *_Nonnull) + showMenuWithTitle:withCancelCompletion:withItems:
 
Show a menu of possible actions More...
 
(void) + showWaiting:withCancelCompletion:
 
Show "waiting" alert, call completion if cancelled More...
 
(void) + showWaiting:
 
Show "waiting" alert without cancel More...
 
(void) + hideWaiting
 
Hide "waiting" alert
 
(void) + updateWaiting:
 
Update the "waiting" alert More...
 
(BOOL) + isWaitingShown
 See if the waiting alert is shown. More...
 
(void) + showToast:message:
 
Show a "toast" (a temporary message) for the default time More...
 
(void) + showToast:message:forTimeInterval:
 
Show a "toast" (a temporary message) More...
 
(NSObject *_Nonnull) + showVersionAlertWithTitle:withShowExtraInfo:
 
Show an alert with version information More...
 
(void) + stopInventoryWithCompletionShowWaiting:
 
Call stop inventory while displaying a waiting dialog More...
 
(void) + stopInventoryWithShownAlert:withCompletion:
 Stop running inventory, showing a waiting dialog if the given dialog is dismissed before inventory stops. More...
 
(void) + startDisconnectedAlert:
 
Show an alert if the Grokker is not connected More...
 
(void) + stopDisconnectedAlert
 
Stop showing the disconnected alert
 
(BOOL) + isDisconnectedAlertActive
 See if the disconnected alert is active. More...
 
(NSString *_Nullable) + inventoryErrorMessageForResult:
 
Get the description of an intentory error More...
 
(NSString *_Nullable) + tagAccessErrorMessageForTagAccessReturnValue:
 
Get the description of a tag access error More...
 
(NSObject *_Nonnull) + showInventoryError:
 
Show an alert with a message about an inventory error More...
 
(NSObject *_Nonnull) + showInventoryError:withCompletion:
 
Show an alert with a message about an inventory error More...
 
(NSString *_Nonnull) + barcodeScanErrorMessage
 
Get the appropriate error message if barcode scan failed More...
 
(NSObject *_Nonnull) + showBarcodeErrorWithCompletion:
 
Show an alert with a message after barcode scan failed More...
 

Types

typedef BOOL(^ UgiShowTextInputShouldEnableForTextCompletion) (NSString *_Nonnull text)
 completion for showTextInput, return YES to enable the action button
 
typedef void(^ UgiShowTextInputCompletionWithText) (NSString *_Nonnull text, BOOL switchValue)
 completion for showTextInput
 
typedef void(^ UgiAlertCompletionWithIndex) (NSInteger buttonIndex)
 Completion for showManyButtonAlert.
 
typedef void(^ UgiShowChoicesAlertCompletion) (int index, NSString *_Nonnull name)
 Completion for showChoices:
 
typedef void(^ UgiShowChoicesAlertConfirmationCompletion) (int index, NSString *_Nonnull name, VoidBlock _Nonnull completion)
 Completion for showChoices:
 

Instance Method Documentation

◆ DEFAULT_THEME_COLOR()

+ (UIColor *) DEFAULT_THEME_COLOR

Default color (a constant)

Returns
default color

◆ DEFAULT_TEXT_COLOR_ON_THEME_COLOR()

+ (UIColor *) DEFAULT_TEXT_COLOR_ON_THEME_COLOR

Default text color when on a background of the theme color (a constant)

Returns
default text color when on a background of the theme color

◆ DEFAULT_BUTTON_COLOR()

+ (UIColor *) DEFAULT_BUTTON_COLOR

Default color for buttons (a constant)

Returns
default color for buttons

◆ DEFAULT_BUTTON_PRESSED_COLOR()

+ (UIColor *) DEFAULT_BUTTON_PRESSED_COLOR

Default color for buttons when pressed (a constant)

Returns
default color for buttons when pressed

◆ DEFAULT_TEXT_COLOR_ON_BACKGROUND()

+ (UIColor *) DEFAULT_TEXT_COLOR_ON_BACKGROUND

Default text color (a constant)

Returns
default text color

◆ themeColor()

+ (UIColor *) themeColor

Default color for the app, defaults to DEFAULT_THEME_COLOR.

Returns
default color for the app

◆ setThemeColor:()

+ (void) setThemeColor: (UIColor *)  color

Default color for the app, defaults to DEFAULT_THEME_COLOR.

Parameters
colordefault color for the app

◆ textColorOnThemeColor()

+ (UIColor *) textColorOnThemeColor

Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_THEME_COLOR.

Returns
default text color when on a background of the theme color for the app

◆ setTextColorOnThemeColor:()

+ (void) setTextColorOnThemeColor: (UIColor *)  color

Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_THEME_COLOR.

Parameters
colordefault text color when on a background of the theme color for the app

◆ buttonColor()

+ (UIColor *) buttonColor

Default color for buttons for the app, defaults to DEFAULT_BUTTON_COLOR.

Returns
default color for buttons for buttons for the app

◆ setButtonColor:()

+ (void) setButtonColor: (UIColor *)  color

Default color for buttons for the app, defaults to DEFAULT_BUTTON_COLOR.

Parameters
colordefault color for buttons for the app

◆ buttonPressedColor()

+ (UIColor *) buttonPressedColor

Default color for the app, defaults to DEFAULT_BUTTON_PRESSED_COLOR.

Returns
default color for buttons when pressed for the app

◆ setButtonPressedColor:()

+ (void) setButtonPressedColor: (UIColor *)  color

Default color for the app, defaults to DEFAULT_BUTTON_PRESSED_COLOR.

Parameters
colordefault color for buttons when pressed for the app

◆ textColorOnBackground()

+ (UIColor *) textColorOnBackground

Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_BACKGROUND.

Returns
default text color for the app

◆ setTextColorOnBackground:()

+ (void) setTextColorOnBackground: (UIColor *)  color

Default color for the app, defaults to DEFAULT_TEXT_COLOR_ON_BACKGROUND.

Parameters
colordefault text color for the app

◆ themeColorToUse()

+ (UIColor *) themeColorToUse

Color for the currently active UgiViewController.

Returns
color to use (for the current view controller)

◆ textColorOnThemeColorToUse()

+ (UIColor *) textColorOnThemeColorToUse

Color for the currently active UgiViewController.

Returns
text color when on a background of the theme color to use (for the current view controller)

◆ buttonColorToUse()

+ (UIColor *) buttonColorToUse

Color for the currently active UgiViewController.

Returns
color for buttons to use (for the current view controller)

◆ buttonPressedColorToUse()

+ (UIColor *) buttonPressedColorToUse

Color for the currently active UgiViewController.

Returns
color for buttons when pressed to use (for the current view controller)

◆ textColorOnBackgroundToUse()

+ (UIColor *) textColorOnBackgroundToUse

Color for the currently active UgiViewController.

Returns
text color to use (for the current view controller)

◆ screenSizeConsideringOrientation()

+ (CGSize) screenSizeConsideringOrientation


Get the screen size, accounting for rotation

Returns
screen size

◆ performCancellableBlockAfterSeconds:block:()

+ (nonnull id) performCancellableBlockAfterSeconds: (double)  seconds
block: (nonnull VoidBlock)  block 


Perform a cancellable block after a delay

Parameters
secondsDelay befire executing block
blockCode to run
Returns
id to use to cancel the block

◆ cancelBlock:()

+ (void) cancelBlock: (nonnull id)  blockId


Cancel a block scheduled with performCancellableBlockAfterSeconds:block:

Parameters
blockIdid returned from performCancellableBlockAfterSeconds:

◆ hideUI:()

+ (void) hideUI: (NSObject *_Nonnull)  o

Hide UI shown with any of the showXXX methods.

Parameters
oObject returned by the showXXX method

◆ updateAlert:withTitle:()

+ (void) updateAlert: (NSObject *_Nonnull)  alert
withTitle: (NSString *_Nullable)  title 

Update an alert's title.

Parameters
alertObject returned by the showXXX method
titleNew title

◆ updateAlert:withMessage:()

+ (void) updateAlert: (NSObject *_Nonnull)  alert
withMessage: (NSString *_Nullable)  message 

Update an alert's message.

Parameters
alertObject returned by the showXXX method
messageNew message

◆ showCancel:message:withCompletion:()

+ (NSObject * _Nonnull) showCancel: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
withCompletion: (nullable VoidBlock)  completion 


Show an alert with a cancel button

Parameters
titleTitle for the alert
messageText for the body of the alert
completionBlock to execute for "ok"
Returns
Object to pass to hideAlert:

◆ showOk:message:()

+ (NSObject * _Nonnull) showOk: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message 


Show an alert with an ok button

Parameters
titleTitle for the alert
messageText for the body of the alert
Returns
The alert

◆ showOk:message:withCompletion:()

+ (NSObject * _Nonnull) showOk: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
withCompletion: (nullable VoidBlock)  completion 


Show an alert with an ok button

Parameters
titleTitle for the alert
messageText for the body of the alert
completionBlock to execute for "ok"
Returns
The alert

◆ showOk:message:okButtonTitle:withCompletion:()

+ (NSObject * _Nonnull) showOk: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
okButtonTitle: (NSString *_Nullable)  okButtonTitle
withCompletion: (nullable VoidBlock)  completion 


Show an alert with an ok button

Parameters
titleTitle for the alert
messageText for the body of the alert
okButtonTitleText for the "ok" button, or "" for the default, or nil for no ok button
completionBlock to execute for "ok"
Returns
The alert

◆ showOkCancel:message:withCompletion:()

+ (NSObject * _Nonnull) showOkCancel: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
withCompletion: (nullable VoidBlock)  completion 


Show an alert with ok and cancel buttons

Parameters
titleTitle for the alert
messageText for the body of the alert
completionBlock to execute for "ok"
Returns
The alert

◆ showOkCancel:message:okButtonTitle:cancelButtonTitle:withCompletion:()

+ (NSObject * _Nonnull) showOkCancel: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
okButtonTitle: (NSString *_Nullable)  okButtonTitle
cancelButtonTitle: (NSString *_Nullable)  cancelButtonTitle
withCompletion: (nullable VoidBlock)  completion 


Show an alert with ok and cancel buttons

Parameters
titleTitle for the alert
messageText for the body of the alert
okButtonTitleText for the "ok" button, or "" for the default, or nil for no ok button
cancelButtonTitleText for the "cancel" button, or "" for the default, or nil for no cancel button
completionBlock to execute for "ok"
Returns
The alert

◆ showOkCancel:message:okButtonTitle:cancelButtonTitle:withCompletion:withCancelCompletion:()

+ (NSObject * _Nonnull) showOkCancel: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
okButtonTitle: (NSString *_Nullable)  okButtonTitle
cancelButtonTitle: (NSString *_Nullable)  cancelButtonTitle
withCompletion: (nullable VoidBlock)  completion
withCancelCompletion: (nullable VoidBlock)  cancelCompletion 


Show an alert with ok and cancel buttons

Parameters
titleTitle for the alert
messageText for the body of the alert
okButtonTitleText for the "ok" button, or "" for the default, or nil for no ok button
cancelButtonTitleText for the "cancel" button, or "" for the default, or nil for no cancel button
completionBlock to execute for "ok"
cancelCompletionBlock to execute for "cancel"
Returns
The alert

◆ showTextInput:message:actionButtonTitle:initialText:allowAutoCorrection:keyboardType:switchText:switchInitialValue:withCompletion:withCancelCompletion:withShouldEnableForTextCompletion:()

+ (NSObject * _Nonnull) showTextInput: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
actionButtonTitle: (NSString *_Nullable)  actionButtonTitle
initialText: (NSString *_Nullable)  initialText
allowAutoCorrection: (BOOL)  allowAutoCorrection
keyboardType: (UIKeyboardType)  keyboardType
switchText: (NSString *_Nullable)  switchText
switchInitialValue: (BOOL)  switchInitialValue
withCompletion: (nonnull UgiShowTextInputCompletionWithText completion
withCancelCompletion: (nullable VoidBlock)  cancelCompletion
withShouldEnableForTextCompletion: (nullable UgiShowTextInputShouldEnableForTextCompletion shouldEnableForTextCompletion 


Input a text string from the user

Parameters
titleTitle for the alert
messageMessage for the alert
actionButtonTitleText for the "ok" button, or "" for the default, or nil for no ok button
initialTextInitial text
allowAutoCorrectionYES to allow auto correct
keyboardTypeType of keyboard
switchTextText for an on/off switch (if nil then no switch)
switchInitialValueInitial value for the switch
completionBlock to execute for "ok"
cancelCompletionBlock to execute for "cancel"
shouldEnableForTextCompletionCode to determine whether the action button should be enabled
Returns
The alert

◆ show3ButtonAlert:message:button1Title:button2Title:cancelButtonTitle:button1Completion:button2Completion:withCancelCompletion:()

+ (NSObject * _Nonnull) show3ButtonAlert: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
button1Title: (NSString *_Nullable)  button1Title
button2Title: (NSString *_Nullable)  button2Title
cancelButtonTitle: (NSString *_Nullable)  cancelButtonTitle
button1Completion: (nullable VoidBlock)  button1Completion
button2Completion: (nullable VoidBlock)  button2Completion
withCancelCompletion: (nullable VoidBlock)  cancelCompletion 


Show an alert with three buttons

Parameters
titleTitle for the alert
messageText for the body of the alert
button1TitleText for button 1
button2TitleText for button 2
cancelButtonTitleText for the "cancel" button, or "" for the default, or nil for no cancel button
button1CompletionBlock to execute for button 1
button2CompletionBlock to execute for button 2
cancelCompletionBlock to execute for "cancel"
Returns
The alert

◆ showManyButtonAlert:message:buttonTitles:cancelButtonTitle:withCompletion:()

+ (NSObject * _Nonnull) showManyButtonAlert: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
buttonTitles: (NSArray< NSString * > *_Nonnull)  buttonTitles
cancelButtonTitle: (NSString *_Nullable)  cancelButtonTitle
withCompletion: (nonnull UgiAlertCompletionWithIndex completion 


Show an alert with many buttons

Parameters
titleTitle for the alert
messageText for the body of the alert
buttonTitlesArray of button titles
cancelButtonTitleText for the "cancel" button, or "" for the default, or nil for no cancel button
completionBlock to execute for when a button is selected
Returns
The alert

◆ showChoices:withInitialSelectedIndex:withTitle:withMessage:withActionButtonTitle:withCanCancel:withCompletion:withConfirmationCompletion:withCancelCompletion:()

+ (NSObject * _Nonnull) showChoices: (NSArray< NSString * > *_Nonnull)  choices
withInitialSelectedIndex: (int)  initialSelectedIndex
withTitle: (NSString *_Nullable)  title
withMessage: (NSString *_Nullable)  message
withActionButtonTitle: (NSString *_Nullable)  actionButtonTitle
withCanCancel: (BOOL)  canCancel
withCompletion: (nonnull UgiShowChoicesAlertCompletion completion
withConfirmationCompletion: (nullable UgiShowChoicesAlertConfirmationCompletion confirmationCompletion
withCancelCompletion: (nullable VoidBlock)  cancelCompletion 


Show UI to choose from a list of choices

Parameters
choicesChoices to choose from
initialSelectedIndexChoice to select initially
titleTitle for the alert
messageText for the body of the alert
actionButtonTitleText for the "ok" button, or "" for the default, or nil for no ok button
canCanceltrue if the user can cancel
completionBlock to execute for "ok"
confirmationCompletionBlock to execute before "ok"
cancelCompletionBlock to execute for "cancel"
Returns
The alert

◆ showMenuWithTitle:withCancelCompletion:withItems:()

+ (NSObject * _Nonnull) showMenuWithTitle: (NSString *_Nullable)  title
withCancelCompletion: (nullable VoidBlock)  cancelCompletion
withItems: (NSArray< UgiMenuItem * > *_Nonnull)  items 


Show a menu of possible actions

Parameters
titleTitle for the menu
cancelCompletionBlock to execute for "cancel"
itemsArray of menu items
Returns
The alert

◆ showWaiting:withCancelCompletion:()

+ (void) showWaiting: (NSString *_Nonnull)  message
withCancelCompletion: (nullable VoidBlock)  completion 


Show "waiting" alert, call completion if cancelled

Parameters
messageText for the body of the alert
completionBlock to execute for "cancel" (or nil if cancel is not an option)

◆ showWaiting:()

+ (void) showWaiting: (NSString *_Nonnull)  message


Show "waiting" alert without cancel

Parameters
messageText for the body of the alert

◆ updateWaiting:()

+ (void) updateWaiting: (NSString *_Nonnull)  message


Update the "waiting" alert

Parameters
messageNew message

◆ isWaitingShown()

+ (BOOL) isWaitingShown

See if the waiting alert is shown.

Returns
YES if a waiting alert is shown

◆ showToast:message:()

+ (void) showToast: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message 


Show a "toast" (a temporary message) for the default time

Parameters
titleTitle for the toast
messageText for the body of the toast

◆ showToast:message:forTimeInterval:()

+ (void) showToast: (NSString *_Nullable)  title
message: (NSString *_Nullable)  message
forTimeInterval: (NSTimeInterval)  interval 


Show a "toast" (a temporary message)

Parameters
titleTitle for the toast
messageText for the body of the toast
intervalDuration to display the toast

◆ showVersionAlertWithTitle:withShowExtraInfo:()

+ (NSObject * _Nonnull) showVersionAlertWithTitle: (NSString *_Nullable)  title
withShowExtraInfo: (BOOL)  showExtraInfo 


Show an alert with version information

Parameters
titleTitle fot the alert (or nil to use the app name and version)
showExtraInfoYES to display additional (debugging) info
Returns
The alert

◆ stopInventoryWithCompletionShowWaiting:()

+ (void) stopInventoryWithCompletionShowWaiting: (nullable StopInventoryCompletion)  completion


Call stop inventory while displaying a waiting dialog

Parameters
completionCode to run after inventory is stopped

◆ stopInventoryWithShownAlert:withCompletion:()

+ (void) stopInventoryWithShownAlert: (NSObject *_Nonnull)  alert
withCompletion: (nullable StopInventoryCompletion)  completion 

Stop running inventory, showing a waiting dialog if the given dialog is dismissed before inventory stops.

Parameters
alertAlert being shown
completionCompletion to run after inventory stops and the alert is dismissed

◆ startDisconnectedAlert:()

+ (void) startDisconnectedAlert: (nullable VoidBlock)  cancelCompletion


Show an alert if the Grokker is not connected

Parameters
cancelCompletionBlock to execute if the user cancels

◆ isDisconnectedAlertActive()

+ (BOOL) isDisconnectedAlertActive

See if the disconnected alert is active.

Returns
true if disconnected alert is active

◆ inventoryErrorMessageForResult:()

+ (NSString * _Nullable) inventoryErrorMessageForResult: (UgiInventoryCompletedReturnValues)  result


Get the description of an intentory error

Parameters
resultThe error
Returns
Description

◆ tagAccessErrorMessageForTagAccessReturnValue:()

+ (NSString * _Nullable) tagAccessErrorMessageForTagAccessReturnValue: (UgiTagAccessReturnValues)  result


Get the description of a tag access error

Parameters
resultThe error
Returns
Description

◆ showInventoryError:()

+ (NSObject * _Nonnull) showInventoryError: (UgiInventoryCompletedReturnValues)  result


Show an alert with a message about an inventory error

Parameters
resultThe error
Returns
The alert

◆ showInventoryError:withCompletion:()

+ (NSObject * _Nonnull) showInventoryError: (UgiInventoryCompletedReturnValues)  result
withCompletion: (nullable VoidBlock)  completion 


Show an alert with a message about an inventory error

Parameters
resultThe error
completionBlock to execute when the alert is completed
Returns
The alert

◆ barcodeScanErrorMessage()

+ (NSString * _Nonnull) barcodeScanErrorMessage


Get the appropriate error message if barcode scan failed

Returns
Error message

◆ showBarcodeErrorWithCompletion:()

+ (NSObject * _Nonnull) showBarcodeErrorWithCompletion: (nullable VoidBlock)  completion


Show an alert with a message after barcode scan failed

Parameters
completionBlock to execute when the alert is completed
Returns
The alert
UgiMenuItem Class Reference

Overview

Objects passed to showMenu.

Class Methods

(UgiMenuItem *_Nonnull) + itemWithTitle:withHandler:
 
Create a menu item More...
 

Properties

NSString * title
 Title for the menu item.
 
VoidBlock handler
 Handler for the menu item.
 

Instance Method Documentation

◆ itemWithTitle:withHandler:()

+ (UgiMenuItem * _Nonnull) itemWithTitle: (NSString *_Nonnull)  title
withHandler: (nonnull VoidBlock)  handler 


Create a menu item

Parameters
titleTitle for the menu item
handlerHandler for the menu item
Returns
Menu item