module SctCore # Abstract super class class Interface ##################################################### # @!group Messaging: show text to the user ##################################################### # Level Error: Can be used to show additional error # information before actually raising an exception # or can be used to just show an error from which # # By default those messages are shown in red def error(_message) not_implemented(__method__) end # Level Important: Can be used to show warnings to the user # not necessarily negative, but something the user should # be aware of. # # By default those messages are shown in yellow def important(_message) not_implemented(__method__) end # Level Success: Show that something was successful # # By default those messages are shown in green def success(_message) not_implemented(__method__) end # Level Message: Show a neutral message to the user # # By default those messages shown in white/black def message(_message) not_implemented(__method__) end # Level Deprecated: Show that a particular function is deprecated # # By default those messages shown in strong blue def deprecated(_message) not_implemented(__method__) end # Level Command: Print out a terminal command that is being # executed. # # By default those messages shown in cyan def command(_message) not_implemented(__method__) end # Level Command Output: Print the output of a command with # this method # # By default those messages shown in magenta def command_output(_message) not_implemented(__method__) end # Level Verbose: Print out additional information for the # users that are interested. Will only be printed when # # By default those messages are shown in white def verbose(_message) not_implemented(__method__) end # Print a header = a text in a box # use this if this message is really important def header(_message) not_implemented(__method__) end # Print lines of content around specific line where # failed to parse. # # This message will be shown as error def content_error(content, error_line) not_implemented(__method__) end ##################################################### # @!group Errors: Inputs ##################################################### # Is is possible to ask the user questions? def interactive? not_implemented(__method__) end # get a standard text input (single line) def input(_message) not_implemented(__method__) end # A simple yes or no question def confirm(_message) not_implemented(__method__) end # Let the user select one out of x items # return value is the value of the option the user chose def select(_message, _options) not_implemented(__method__) end # Password input for the user, text field shouldn't show # plain text def password(_message) not_implemented(__method__) end def user_error!(error_message, options = {}) not_implemented(__method__) end end end