de.kleopatra.forms.view.builder
Class FormUtils

java.lang.Object
  extended byde.kleopatra.forms.view.builder.FormUtils

public class FormUtils
extends java.lang.Object

A bunch of static utility methods.

Version:
$Revision: 1.5 $ - $Date: 2004/10/04 12:18:34 $
Author:
(C) 2004 Jeanette Winzenburg, Berlin

Constructor Summary
FormUtils()
           
 
Method Summary
static javax.swing.JFrame createFrame(Form form, boolean defaultShow)
          create a JFrame around the Form.
static javax.swing.JFrame createFrame(Form form, java.lang.String title, boolean defaultShow)
          create a JFrame around the Form.
static javax.swing.JFrame createFrame(javax.swing.JComponent content, java.lang.String title, boolean defaultShow)
          create a JFrame with content as contentPane, given title.
static java.util.List installActions(java.util.List actionIDs, java.lang.String resourceID, java.lang.Object handler)
          register actions and callback methods of handler with the ActionFactory, and customize their presentation attributes from the resource.
static java.util.List installActions(java.lang.Object[] actionIDs, java.lang.String resourceID, java.lang.Object handler)
          register actions and callback methods of handler with the ActionFactory, and customize their presentation attributes from the resource.
static void locateOnScreenCenter(java.awt.Component component)
          Locates the given component on the screen's center.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FormUtils

public FormUtils()
Method Detail

createFrame

public static javax.swing.JFrame createFrame(Form form,
                                             boolean defaultShow)
create a JFrame around the Form.

pack and show if defaultShow is true. As a side-effect OptionPane's rootFrame is set to the frame.


createFrame

public static javax.swing.JFrame createFrame(Form form,
                                             java.lang.String title,
                                             boolean defaultShow)
create a JFrame around the Form.

pack and show if defaultShow is true. As a side-effect OptionPane's rootFrame is set to the frame.


createFrame

public static javax.swing.JFrame createFrame(javax.swing.JComponent content,
                                             java.lang.String title,
                                             boolean defaultShow)
create a JFrame with content as contentPane, given title.

pack and show if defaultShow is true. As a side-effect OptionPane's rootFrame is set to the frame.

Parameters:
content -
title -
defaultShow -
Returns:

locateOnScreenCenter

public static void locateOnScreenCenter(java.awt.Component component)
Locates the given component on the screen's center.

Parameters:
component - the component to be centered

installActions

public static java.util.List installActions(java.lang.Object[] actionIDs,
                                            java.lang.String resourceID,
                                            java.lang.Object handler)
register actions and callback methods of handler with the ActionFactory, and customize their presentation attributes from the resource.

Parameters:
actionIDs - an array of actionIDs
resourceID - the name of the resource
handler - an object providing the callback methods
Returns:
a list of all actions registered for the given resourceID

installActions

public static java.util.List installActions(java.util.List actionIDs,
                                            java.lang.String resourceID,
                                            java.lang.Object handler)
register actions and callback methods of handler with the ActionFactory, and customize their presentation attributes from the resource.

Parameters:
actionIDs - a list of actionIDs
resourceID - the name of the resource
handler - an object providing the callback methods
Returns:
a list of all actions registered for the given resourceID


Copyright © 2003, 2004 SwingEmpire Jeanette Winzenburg. All Rights Reserved.