How To : Setting up Logging
Contents |
[edit] Description
This document describes how to set up logging in Bungee Builder.[edit] Prerequisites
Understanding Logging
Overview : Building a Bungee-powered Application
Introduction to Bungee Builder
Adding a Class to a Project
Adding a Function to a Class
Working with Bungee Logic
[edit] Procedure
To implement logging in your application:
- Open a code view of your class or function (double-click on the class or function).
- From the Toolbox, drag log message into your code where you would like to enable logging.
- In the Property Editor, set the properties:
- Comment Out Select this option if you want to comment out the logging statement.
- Type Select either Dialog, Log, or Both.
- Dialog Opens a dialog box during runtime.
- Log Creates a log entry (default). When Log is selected, a checkbox for Throw Event is available. Select Throw Event to have the log entry appear in the Event Viewer.
- Both Opens a dialog box and creates a log entry.
- Dialog Type Select between Message, Confirmation, and Prompt.
- Message Displays the message (that's assigned in the Message property) along with an OK button (for closing the dialog box).
- Confirmation Displays the message (that's assigned in the Message property) along with OK and Cancel buttons.
- Prompt Displays the message (that's assigned in the Message property) along with a TextEdit field (for typing a note) and OK and Cancel buttons.
- Log Type Lets you assign a severity to the log message. Select between (the icons are used in the Event Viewer to help identify the type of message):
- Debug
- Information
- Warning
- Error
- Fatal
- Message Lets you assign an object to act as a message that's displayed when Dialog is selected as the Type (see above). For example, you can use the Message property to display the value of a field. If you set Message to Expression and add something like: "This is the firstName field: " + firstName, the log entry will show the text in quotes and the value of firstName.
- Confirmation Lets you assign an object to act as a confirmation. This is used when Confirmation is selected as the Dialog Type (see above).
- Prompt Lets you assign an object to act as a prompt. This is used when Prompt is selected as the Dialog Type (see above).
[edit] Error Handling
[edit] Examples
[edit] Next Steps
Posting Your Application
Deploying Your Application
Managing a Deployed Application
[edit] Tags