# ScreenBeanInfo

Import: `import com.install4j.api.beaninfo.ScreenBeanInfo;`

```java
public class ScreenBeanInfo extends Install4JBeanInfo
```

Base class for screen bean infos.

Using this class is not strictly required. In principle, you could also set values for the `ATTRIBUTE_*` constants in the bean descriptor
of an unrelated bean info class.

## Inherited from

- [Install4JBeanInfo](Install4JBeanInfo.md) — 28 methods, 23 fields

## Methods

| Signature | Returns | Description |
|---|---|---|
| [`setDefaultQuitAfterScreen(boolean)`](#setdefaultquitafterscreen-boolean) | `void` | Configures the default value for the "Quit after screen" property of the screen. |
| [`setFormComponentCustomizerPlacement(CustomizerPlacement)`](#setformcomponentcustomizerplacement-customizerplacement) | `void` |  |
| [`setAssociatedAction(String, String)`](#setassociatedaction-string-string) | `void` | Same as [`ScreenBeanInfo.setAssociatedAction`](ScreenBeanInfo.md#setassociatedaction-string-string-boolean-string-actioninitializer) with first set to `false`, conditionExpression set to `null` and actionInitializer set to `null`. |
| [`setAssociatedAction(String, String, boolean, String, ActionInitializer)`](#setassociatedaction-string-string-boolean-string-actioninitializer) | `void` | Configures an associated action. |
| [`setDefaultStyleName(String)`](#setdefaultstylename-string) | `void` | Sets a default screen style name. |
| [`setDefaultPreActivationScript(String)`](#setdefaultpreactivationscript-string) | `void` | Configures the default value for the "Pre-activation script" property of the bean. |
| [`setDefaultPostActivationScript(String)`](#setdefaultpostactivationscript-string) | `void` | Configures the default value for the "Post-activation script" property of the bean. |

### setDefaultQuitAfterScreen(boolean)

```java
public void setDefaultQuitAfterScreen(boolean defaultQuitAfterScreen)
```

Configures the default value for the "Quit after screen" property of the screen.


**Parameters:**

- `defaultQuitAfterScreen` — the default value

### setFormComponentCustomizerPlacement(CustomizerPlacement)

```java
@Deprecated public void setFormComponentCustomizerPlacement(CustomizerPlacement customizerPlacement)
```

> **⚠ Deprecated.** no longer used


**Deprecated.** no longer used

### setAssociatedAction(String, String)

```java
public void setAssociatedAction(String actionClassName, String targetScreenClassName)
```

Same as [`ScreenBeanInfo.setAssociatedAction`](ScreenBeanInfo.md#setassociatedaction-string-string-boolean-string-actioninitializer) with first set to `false`,
conditionExpression set to `null` and actionInitializer set to `null`.

### setAssociatedAction(String, String, boolean, String, ActionInitializer)

```java
public void setAssociatedAction(String actionClassName, String targetScreenClassName, boolean addFirst, String conditionExpression, ActionInitializer actionInitializer)
```

Configures an associated action. If set, and the user adds the screen, the install4j GUI checks if
an instance of the specified action is present in the list of configured actions. If
`targetScreenClassName` is `null`, it will remind the user to add such an action to any other screen
if it is not present on any screen. Otherwise, it will propose to add the action to the target screen if it is
not already present there.


**Parameters:**

- `actionClassName` — the class of the associated action
- `targetScreenClassName` — the target screen. If non-null, the install4j GUI will propose to add the
associated action to the target screen if it is not already present on the target screen.
- `addFirst` — If targetScreenClassName is non-null, and the action is inserted, it will be inserted as the first action
- `conditionExpression` — the condition expression for the added action, may be `null`
- `actionInitializer` — an initializer that configures the added action

### setDefaultStyleName(String)

```java
public void setDefaultStyleName(String defaultStyleName)
```

Sets a default screen style name. If set, the install4j GUI checks if a style with the corresponding name is
available and sets that screen style for the screen.


**Parameters:**

- `defaultStyleName` — the default screen style name

### setDefaultPreActivationScript(String)

```java
public void setDefaultPreActivationScript(String defaultPreActivationScript)
```

Configures the default value for the "Pre-activation script" property of the bean.


**Parameters:**

- `defaultPreActivationScript` — the default value

**See also:**

- [ScreenBeanInfo.ATTRIBUTE_DEFAULT_PRE_ACTIVATION_SCRIPT](ScreenBeanInfo.md#attribute-default-pre-activation-script)

### setDefaultPostActivationScript(String)

```java
public void setDefaultPostActivationScript(String defaultPostActivationScript)
```

Configures the default value for the "Post-activation script" property of the bean.


**Parameters:**

- `defaultPostActivationScript` — the default value

**See also:**

- [ScreenBeanInfo.ATTRIBUTE_DEFAULT_POST_ACTIVATION_SCRIPT](ScreenBeanInfo.md#attribute-default-post-activation-script)

## Constructors

| Signature | Description |
|---|---|
| [`ScreenBeanInfo(String, String, String, boolean, boolean, Integer, Class<? extends Screen>, Class)`](#screenbeaninfo-string-string-string-boolean-boolean-integer-class-extends-screen-class) | Same as [`Install4JBeanInfo.Install4JBeanInfo`](Install4JBeanInfo.md#install4jbeaninfo-string-string-string-boolean-boolean-integer-class-extends-bean-class). |
| [`ScreenBeanInfo(String, String, String, boolean, boolean, Integer, Class<? extends Screen>)`](#screenbeaninfo-string-string-string-boolean-boolean-integer-class-extends-screen) | Same as [`Install4JBeanInfo.Install4JBeanInfo`](Install4JBeanInfo.md#install4jbeaninfo-string-string-string-boolean-boolean-integer-class-extends-bean). |

### ScreenBeanInfo(String, String, String, boolean, boolean, Integer, Class<? extends Screen>, Class)

```java
public ScreenBeanInfo(String displayName, String shortDescription, String category, boolean multipleInstancesSupported, boolean installedFilesRequired, Integer sortKey, Class<? extends Screen> beanClass, Class customizerClass)
```

Same as [`Install4JBeanInfo.Install4JBeanInfo`](Install4JBeanInfo.md#install4jbeaninfo-string-string-string-boolean-boolean-integer-class-extends-bean-class).

### ScreenBeanInfo(String, String, String, boolean, boolean, Integer, Class<? extends Screen>)

```java
public ScreenBeanInfo(String displayName, String shortDescription, String category, boolean multipleInstancesSupported, boolean installedFilesRequired, Integer sortKey, Class<? extends Screen> beanClass)
```

Same as [`Install4JBeanInfo.Install4JBeanInfo`](Install4JBeanInfo.md#install4jbeaninfo-string-string-string-boolean-boolean-integer-class-extends-bean).

## Fields

| Field | Type | Description |
|---|---|---|
| [ATTRIBUTE_DEFAULT_QUIT_AFTER_SCREEN](#attribute-default-quit-after-screen) | `String` |  |
| [ATTRIBUTE_FORM_COMPONENT_CUSTOMIZER_PLACEMENT](#attribute-form-component-customizer-placement) | `String` |  |
| [ATTRIBUTE_ASSOCIATED_ACTION](#attribute-associated-action) | `String` |  |
| [ATTRIBUTE_ASSOCIATED_ACTION_TARGET_SCREEN](#attribute-associated-action-target-screen) | `String` |  |
| [ATTRIBUTE_ASSOCIATED_ACTION_INSERT_FIRST](#attribute-associated-action-insert-first) | `String` |  |
| [ATTRIBUTE_ASSOCIATED_ACTION_INITIALIZER](#attribute-associated-action-initializer) | `String` |  |
| [ATTRIBUTE_ASSOCIATED_ACTION_CONDITION_EXPRESSION](#attribute-associated-action-condition-expression) | `String` |  |
| [ATTRIBUTE_DEFAULT_STYLE_NAME](#attribute-default-style-name) | `String` |  |
| [ATTRIBUTE_DEFAULT_PRE_ACTIVATION_SCRIPT](#attribute-default-pre-activation-script) | `String` |  |
| [ATTRIBUTE_DEFAULT_POST_ACTIVATION_SCRIPT](#attribute-default-post-activation-script) | `String` |  |

### ATTRIBUTE_DEFAULT_QUIT_AFTER_SCREEN

```java
public static final String ATTRIBUTE_DEFAULT_QUIT_AFTER_SCREEN = "defaultQuitAfterScreen"
```

### ATTRIBUTE_FORM_COMPONENT_CUSTOMIZER_PLACEMENT

```java
@Deprecated public static final String ATTRIBUTE_FORM_COMPONENT_CUSTOMIZER_PLACEMENT = "formComponentCustomizerPlacement"
```

> **⚠ Deprecated.** no longer used

### ATTRIBUTE_ASSOCIATED_ACTION

```java
public static final String ATTRIBUTE_ASSOCIATED_ACTION = "associatedAction"
```

### ATTRIBUTE_ASSOCIATED_ACTION_TARGET_SCREEN

```java
public static final String ATTRIBUTE_ASSOCIATED_ACTION_TARGET_SCREEN = "associatedActionTargetScreen"
```

### ATTRIBUTE_ASSOCIATED_ACTION_INSERT_FIRST

```java
public static final String ATTRIBUTE_ASSOCIATED_ACTION_INSERT_FIRST = "associatedActionInsertFirst"
```

### ATTRIBUTE_ASSOCIATED_ACTION_INITIALIZER

```java
public static final String ATTRIBUTE_ASSOCIATED_ACTION_INITIALIZER = "associatedActionInitializer"
```

### ATTRIBUTE_ASSOCIATED_ACTION_CONDITION_EXPRESSION

```java
public static final String ATTRIBUTE_ASSOCIATED_ACTION_CONDITION_EXPRESSION = "associatedActionConditionExpression"
```

### ATTRIBUTE_DEFAULT_STYLE_NAME

```java
public static final String ATTRIBUTE_DEFAULT_STYLE_NAME = "defaultStyleName"
```

### ATTRIBUTE_DEFAULT_PRE_ACTIVATION_SCRIPT

```java
public static final String ATTRIBUTE_DEFAULT_PRE_ACTIVATION_SCRIPT = "defaultPreActivationScript"
```

### ATTRIBUTE_DEFAULT_POST_ACTIVATION_SCRIPT

```java
public static final String ATTRIBUTE_DEFAULT_POST_ACTIVATION_SCRIPT = "defaultPostActivationScript"
```

