Class UIHints
java.lang.Object
com.streambase.sb.operator.parameter.UIHints
A
UIHints
may be associated with a SBPropertyDescriptor
in order
to provide the Studio environment with additional hints regarding how to display
a property.
If you wish to toggle the UI widget enablement state for a property, see Parameterizable
.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
Used to request a font style for String-based propertiesstatic enum
Used to request a particular width for text-field like controls (including but not limited to text fields and combo/drop-downs). -
Field Summary
Modifier and TypeFieldDescriptionboolean
Set a hint for String[] properties to request that Studio display a field chooser out of schemas managed by the operator.boolean
Set a hint for the associated property to mask displayed characters when presented to the end-user.int
Set a hint for the associated property to be displayed as a multiline editable box of height (number of lines)size
.String[]
Set a hint for an associated String property to propose to the user the following values.Name to give the tab in which the associated property will be created in, when displayed in the Properties View of StreamBase Studio.String[]
Set a hint for the associated table property to be displayed with the following column names.Set a hint for text-field like properties to use a different font style.Set a hint for text-field like properties to have a relative width. -
Method Summary
Modifier and TypeMethodDescriptionstatic UIHints
create()
Creates a newUIHints
with all values initialized to defaultsetAssociateFieldPicker
(boolean associate) ForString[]
properties only, instructs Studio to display a schema field picker.setMaskStringDisplay
(boolean maskStringDisplay) Sets the mask hint, applicable to String property types.setNumLines
(int numLines) Sets the number of lines to display this property as, applicable to String property types.setProposals
(String... proposals) Set string proposals that will be offered to the user when editing an associated String propertySets the tab name hint.setTableColumnNames
(String... tableColumnNames) Set column names to use for properties displayed in a user interface TableSet the desired font hint for text-field-like controlsSet the desired width hint for text-field-like controls
-
Field Details
-
tab
Name to give the tab in which the associated property will be created in, when displayed in the Properties View of StreamBase Studio. Ignored forSchema
properties.This string will be used as-is as the tab title. All properties sharing the same tab name will be placed together.
By default, Studio will place all properties in one common tab.
-
maskStringDisplay
public boolean maskStringDisplaySet a hint for the associated property to mask displayed characters when presented to the end-user. Applies only to a String property, otherwise this call will have no effect.This hint may be ignored under certain circumstances, and should not be seen as a security feature.
By default, this hint is
false
. -
numLines
public int numLinesSet a hint for the associated property to be displayed as a multiline editable box of height (number of lines)size
. Valid only for a String property.By default, this hint is
1
. -
tableColumnNames
Set a hint for the associated table property to be displayed with the following column names. As of 7.3.5, there is support for at most two columns (for Map and String[][] types).- Since:
- 7.1
-
proposals
Set a hint for an associated String property to propose to the user the following values. The user is not limited to just these values; for that purpose, use anEnumPropertyDescriptor
orJavaEnumPropertyDescriptor
.- Since:
- 7.3.1
-
textWidthHint
Set a hint for text-field like properties to have a relative width.- Since:
- 7.5.1
- See Also:
-
associateFieldPicker
public boolean associateFieldPickerSet a hint for String[] properties to request that Studio display a field chooser out of schemas managed by the operator.- Since:
- 7.2.3
- See Also:
-
textFontHint
Set a hint for text-field like properties to use a different font style.- Since:
- 7.7.3
- See Also:
-
-
Method Details
-
create
Creates a newUIHints
with all values initialized to default- Returns:
- a new
UIHints
-
setTab
Sets the tab name hint. Do not use the&
character in the String. Note thatSchema
properties are always placed in a special tab.- Parameters:
tab
- the tab name- Returns:
- this, useful for chaining method calls
- See Also:
-
setMaskStringDisplay
Sets the mask hint, applicable to String property types.- Parameters:
maskStringDisplay
- whether to set the string mask hint or not- Returns:
- this, useful for chaining method calls
- See Also:
-
setNumLines
Sets the number of lines to display this property as, applicable to String property types.- Parameters:
numLines
- the number of lines desired- Returns:
- this, useful for chaining method calls
- See Also:
-
setTableColumnNames
Set column names to use for properties displayed in a user interface Table- Parameters:
tableColumnNames
- the names of the columns, from first to last- Returns:
- this, useful for chaining method calls
- Since:
- 7.1
- See Also:
-
setProposals
Set string proposals that will be offered to the user when editing an associated String property- Parameters:
proposals
- string values that will be proposed to the user- Returns:
- this, useful for chaining method calls
- Since:
- 7.3.1
- See Also:
-
setTextWidth
Set the desired width hint for text-field-like controls- Parameters:
width
- the desired width- Returns:
- this, useful for chaining method calls
- Since:
- 7.5.1
-
setAssociateFieldPicker
ForString[]
properties only, instructs Studio to display a schema field picker. The operator may participate in this interaction viaStudioAssistSchemaFieldPicker.getSchemasForFieldPicker(String, Schema[])
- Parameters:
associate
-- Returns:
- this, useful for chaining method calls
- Since:
- 7.2.3
- See Also:
-
setTextFont
Set the desired font hint for text-field-like controls- Parameters:
hint
- the font hint- Returns:
- this, useful for chaining method calls
- Since:
- 7.7.3
-