|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.plumtree.portalpages.common.helpers.ViewHelper
public class ViewHelper
Field Summary | |
---|---|
static int |
INPUTMAXLENGTH_LONG
|
static int |
INPUTMAXLENGTH_SHORT
|
static int |
INPUTSIZE_NONPREFIXED
|
static int |
INPUTSIZE_PREFIXED
|
static java.lang.String |
SPACE
|
static int |
TEXTAREA_COLUMNS
|
static int |
TEXTAREA_ROWS
|
Constructor Summary | |
---|---|
ViewHelper()
|
Method Summary | |
---|---|
static HTMLTableCell |
AddCell(HTMLTableRow myRow,
java.lang.String colspan)
Adds a cell with default view styling to myRow. |
static HTMLTableCell |
AddEditBoxCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String sDefaultValue,
java.lang.String sHTMLID)
|
static HTMLTableCell |
AddEditBoxCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String sDefaultValue,
java.lang.String sHTMLID,
int width)
|
static HTMLTableCell |
AddEditBoxCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String sDefaultValue,
java.lang.String sHTMLID,
int width,
boolean bIsInputDisabled,
java.lang.String sFormID)
|
static HTMLTableCell |
AddEmptyCell(HTMLTableRow myRow,
java.lang.String colspan)
Adds an empty cell with default view styling to myRow. |
static HTMLTableRow |
AddEmptyRow(HTMLTable myTable,
java.lang.String colspan)
Adds an empty row with default view styling to myTable. |
static HTMLTableCell |
AddIconCell(HTMLTableRow myRow,
java.lang.String colspan,
int nCLASSID,
java.lang.String strProviderCLSID,
java.lang.String _strLangID)
Adds a Cell with a single object icon in it. |
static HTMLTableCell |
AddImageCell(HTMLTableRow myRow,
java.lang.String colspan,
AActivitySpace asOwner,
PTImageType imgType)
Adds a simple cell containing an image - centered with no border. |
static HTMLTableCell |
AddIndentCell(HTMLTableRow myRow,
java.lang.String colspan)
|
static HTMLTableCell |
AddLabelAndTextCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String strLabel,
java.lang.String strText)
Adds a cell to a row containing a bolded label followed on a separate line by text. |
static HTMLTableCell |
AddLabelCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String strText)
Returns a Cell suitable for long text descriptions. |
static int |
AddLeftMargin(HTMLTableRow myRow,
int nColCount)
Uses nColCount to determine if there is enough space for margins and a spacer cell. |
static HTMLTable |
AddListTable(HTMLElementCollection result)
Adds a table with default list view styling to HTMLCollection result. |
static HTMLTableCell |
AddPasswordBoxCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String sDefaultValue,
java.lang.String sHTMLID)
|
static HTMLTableCell |
AddPasswordBoxCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String sDefaultValue,
java.lang.String sHTMLID,
int width)
|
static HTMLTableCell |
AddReferencableLabelCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String strText,
java.lang.String txtContainerId)
Returns a Cell suitable for long text descriptions. |
static void |
AddRightMargin(HTMLTableRow myRow,
int nColCount)
Uses nColCount to determine if there is enough space for margins and a spacer cell. |
static HTMLTableRow |
AddRow(HTMLTable myTable)
Adds a row with default view styling to myTable. |
static HTMLTableCell |
AddSelectBoxWithJSHandlerInColumn(HTMLTableRow row,
java.lang.String label,
java.lang.String selectId,
int displaySize,
java.lang.String style,
java.lang.String onChangeHandler,
HTMLOption[] options,
java.lang.String defaultValue,
AActivitySpace asOwner)
|
static HTMLTableRow |
AddSimpleCheckbox(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String strHTMLID,
java.lang.String strValue,
boolean bChecked,
java.lang.String strOnChange)
Adds a row to myTable containing a simple checkbox selection. |
static HTMLTableRow |
AddSimpleCheckbox(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String strHTMLID,
java.lang.String strValue,
boolean bChecked,
java.lang.String strOnChange,
boolean bDisabled)
Adds a row to myTable containing a simple checkbox selection. |
static void |
AddSimpleDurationCombo(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String strHTMLTimeoutInput,
java.lang.String strHTMLTimeoutUnitsSelect,
PTDuration ptdIn,
AActivitySpace asOwner)
Adds a label + PTDurationCombo combination to myTable (spanning a single row). |
static void |
AddSimpleEditBox(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String strPrefix,
java.lang.String sDefaultValue,
java.lang.String sHTMLID)
Adds a label + edit box combination spanning two rows to myTable. |
static void |
AddSimpleLabel(HTMLTable myTable,
int nColCount,
java.lang.String strLabel)
Adds a simple Label - full width of the table (adding margins) |
static void |
AddSimpleNameValue(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String sDefaultValue,
java.lang.String strLang)
Adds a row with a simple label: value listing. |
static HTMLTableRow |
AddSimpleRadio(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String strHTMLID,
java.lang.String strValue,
boolean bChecked)
Adds a row to myTable containing a simple radio selection. |
static HTMLTableRow |
AddSimpleRadio(HTMLTable myTable,
int nColCount,
java.lang.String strLabel,
java.lang.String strHTMLID,
java.lang.String strValue,
boolean bChecked,
java.lang.String strOnChange)
Adds a row to myTable containing a simple radio selection. |
static void |
AddSimpleTableHeader(HTMLTable myTable,
java.lang.String[] arsHeaders)
Adds a simple header (no sorting or whatnot) to an existing table. |
static HTMLTableCell |
AddSpacerCell(HTMLTableRow myRow,
java.lang.String colspan)
Adds a cell with default view styling to myRow. |
static HTMLSpan |
AddSpanToCell(HTMLTableCell myCell)
Adds a span with default view styling to myCell. |
static HTMLTableCell |
AddSubLabelCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String strText)
Returns a Cell suitable for long text descriptions. |
static HTMLTable |
AddTable(HTMLElementCollection result)
Adds a table with default view styling to HTMLCollection result. |
static HTMLTableCell |
AddTextAreaCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String sDefaultValue,
java.lang.String sHTMLID)
|
static HTMLTableCell |
AddTextCell(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String strText)
Returns a Cell suitable for long text descriptions. |
static HTMLTableCell |
AddTextCellReferencable(HTMLTableRow myRow,
java.lang.String colspan,
java.lang.String strText,
java.lang.String spanId)
Returns a Cell suitable for long text descriptions. |
static HTMLTableCell |
AddTypeCell(HTMLTableRow myRow,
java.lang.String colspan,
int nCLASSID,
java.lang.String strProviderCLSID,
java.lang.String _strLangID)
Adds a Cell with a single Type string (Web Service, etc.) in it. |
static java.lang.String |
GetAdminFolderPath(IPTSession ptSession,
int nAdminFolderID)
Returns the String path to the folder with ID nAdminFolderID |
static int |
GetQRValueAsInt(IASQueryResult ptQR,
int nRowIndex,
int nPropID)
Retrieves an int value from a Query Result. |
static java.lang.String |
GetQRValueAsString(IASQueryResult ptQR,
int nRowIndex,
int nPropID)
Retrieves a String value from a QueryResult. |
static HTMLElement |
MakeCreateObjectLink(int nCLASSID,
java.lang.String strProviderCLSID,
int nFolderID,
java.lang.String strLink,
AActivitySpace asOwner,
java.lang.String strArgs,
boolean bCloseWindowOnExit)
Makes a simple link that creates an object in the parent window - passing in the added arguments. |
static HTMLElement |
MakeHiddenInput(java.lang.String strHTMLID,
java.lang.String strvalue)
|
static HTMLTable |
MakeListTable()
Returns a table with the default view styling. |
static HTMLElement |
MakeSimpleButton(java.lang.String strText,
java.lang.String strOnClick)
Makes a simple button with text strText and onClick handler strOnClick. |
static HTMLElement |
MakeSimpleButton(java.lang.String strText,
java.lang.String strOnClick,
java.lang.String strHTML)
Makes a simple button with text strText and onClick handler strOnClick. |
static HTMLElement |
MakeSimpleCheckbox(java.lang.String strLabel,
java.lang.String strHTMLID,
java.lang.String strValue,
boolean bChecked,
java.lang.String strOnChange)
Creates a simple checkbox and returns it. |
static HTMLElement |
MakeSimpleRadio(java.lang.String strLabel,
java.lang.String strHTMLID,
java.lang.String strValue,
boolean bChecked,
java.lang.String strOnChange)
Creates a simple radio selection and returns it. |
static HTMLTable |
MakeTable()
Returns a table with the default view styling. |
static void |
SetRowColor(HTMLTableCell myCell,
boolean bRowColor)
Sets the cell color based on bRowColor. |
static java.lang.String |
ValidateNumericInputJS(java.lang.String strFormName,
java.lang.String strInputName,
java.lang.String strError)
Returns JS for validating that a numeric input is, indeed numeric (and positive) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String SPACE
public static final int INPUTSIZE_PREFIXED
public static final int INPUTSIZE_NONPREFIXED
public static final int TEXTAREA_COLUMNS
public static final int TEXTAREA_ROWS
public static final int INPUTMAXLENGTH_SHORT
public static final int INPUTMAXLENGTH_LONG
Constructor Detail |
---|
public ViewHelper()
Method Detail |
---|
public static HTMLTableCell AddCell(HTMLTableRow myRow, java.lang.String colspan)
myRow
- colspan
-
HTMLException
public static HTMLTableCell AddEditBoxCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String sDefaultValue, java.lang.String sHTMLID)
myRow
- colspan
- sDefaultValue
- sHTMLID
-
HTMLException
public static HTMLTableCell AddEditBoxCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String sDefaultValue, java.lang.String sHTMLID, int width)
public static HTMLTableCell AddEditBoxCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String sDefaultValue, java.lang.String sHTMLID, int width, boolean bIsInputDisabled, java.lang.String sFormID)
public static HTMLTableCell AddEmptyCell(HTMLTableRow myRow, java.lang.String colspan)
myRow
- colspan
-
HTMLException
public static HTMLTableRow AddEmptyRow(HTMLTable myTable, java.lang.String colspan)
myTable
- colspan
-
HTMLException
public static HTMLTableCell AddIconCell(HTMLTableRow myRow, java.lang.String colspan, int nCLASSID, java.lang.String strProviderCLSID, java.lang.String _strLangID)
myRow
- colspan
- nCLASSID
- strProviderCLSID
-
HTMLException
public static HTMLTableCell AddTypeCell(HTMLTableRow myRow, java.lang.String colspan, int nCLASSID, java.lang.String strProviderCLSID, java.lang.String _strLangID)
myRow
- colspan
- nCLASSID
- strProviderCLSID
-
HTMLException
public static HTMLTableCell AddIndentCell(HTMLTableRow myRow, java.lang.String colspan)
myRow
- colspan
-
HTMLException
public static HTMLTableCell AddLabelCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String strText)
myRow
- colspan
- strText
-
HTMLException
public static HTMLTableCell AddReferencableLabelCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String strText, java.lang.String txtContainerId)
myRow
- colspan
- strText
-
HTMLException
public static HTMLTableCell AddLabelAndTextCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String strLabel, java.lang.String strText)
myRow
- colspan
- strLabel
- strText
-
HTMLException
public static HTMLTableCell AddSubLabelCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String strText)
myRow
- colspan
- strText
-
HTMLException
public static HTMLTableCell AddImageCell(HTMLTableRow myRow, java.lang.String colspan, AActivitySpace asOwner, PTImageType imgType)
myRow
- colspan
- asOwner
- imgType
-
HTMLException
public static int AddLeftMargin(HTMLTableRow myRow, int nColCount)
myRow
- nColCount
-
HTMLException
public static HTMLTableCell AddPasswordBoxCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String sDefaultValue, java.lang.String sHTMLID)
myRow
- colspan
- sDefaultValue
- sHTMLID
-
HTMLException
public static HTMLTableCell AddPasswordBoxCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String sDefaultValue, java.lang.String sHTMLID, int width)
public static void AddRightMargin(HTMLTableRow myRow, int nColCount)
myRow
- nColCount
-
HTMLException
public static HTMLTableRow AddRow(HTMLTable myTable)
myTable
-
HTMLException
public static void AddSimpleDurationCombo(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String strHTMLTimeoutInput, java.lang.String strHTMLTimeoutUnitsSelect, PTDuration ptdIn, AActivitySpace asOwner)
myTable
- nColCount
- strLabel
- strHTMLTimeoutInput
- strHTMLTimeoutUnitsSelect
- ptdIn
-
java.lang.Exception
public static HTMLTableCell AddSelectBoxWithJSHandlerInColumn(HTMLTableRow row, java.lang.String label, java.lang.String selectId, int displaySize, java.lang.String style, java.lang.String onChangeHandler, HTMLOption[] options, java.lang.String defaultValue, AActivitySpace asOwner)
public static void AddSimpleEditBox(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String strPrefix, java.lang.String sDefaultValue, java.lang.String sHTMLID)
myTable
- nColCount
- strLabel
- strPrefix
- sDefaultValue
- sHTMLID
-
HTMLException
public static void AddSimpleLabel(HTMLTable myTable, int nColCount, java.lang.String strLabel)
myTable
- nColCount
- strLabel
-
HTMLException
public static void AddSimpleNameValue(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String sDefaultValue, java.lang.String strLang)
public static HTMLTableRow AddSimpleRadio(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String strHTMLID, java.lang.String strValue, boolean bChecked, java.lang.String strOnChange)
myTable
- nColCount
- strLabel
- strHTMLID
- strValue
- bChecked
- strOnChange
-
HTMLException
public static HTMLTableRow AddSimpleCheckbox(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String strHTMLID, java.lang.String strValue, boolean bChecked, java.lang.String strOnChange)
myTable
- nColCount
- strLabel
- strHTMLID
- strValue
- bChecked
- strOnChange
-
HTMLException
public static HTMLTableRow AddSimpleCheckbox(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String strHTMLID, java.lang.String strValue, boolean bChecked, java.lang.String strOnChange, boolean bDisabled)
myTable
- nColCount
- strLabel
- strHTMLID
- strValue
- bChecked
- strOnChange
-
HTMLException
public static HTMLElement MakeHiddenInput(java.lang.String strHTMLID, java.lang.String strvalue)
public static HTMLElement MakeSimpleRadio(java.lang.String strLabel, java.lang.String strHTMLID, java.lang.String strValue, boolean bChecked, java.lang.String strOnChange)
strLabel
- strHTMLID
- strValue
- bChecked
- strOnChange
-
HTMLException
public static HTMLElement MakeSimpleCheckbox(java.lang.String strLabel, java.lang.String strHTMLID, java.lang.String strValue, boolean bChecked, java.lang.String strOnChange)
strLabel
- strHTMLID
- strValue
- bChecked
- strOnChange
-
HTMLException
public static HTMLTableRow AddSimpleRadio(HTMLTable myTable, int nColCount, java.lang.String strLabel, java.lang.String strHTMLID, java.lang.String strValue, boolean bChecked)
myTable
- nColCount
- strLabel
- strHTMLID
- strValue
- bChecked
-
HTMLException
public static void AddSimpleTableHeader(HTMLTable myTable, java.lang.String[] arsHeaders) throws java.lang.Exception
myTable
- arsHeaders
-
java.lang.Exception
public static HTMLTableCell AddSpacerCell(HTMLTableRow myRow, java.lang.String colspan)
myRow
- colspan
-
HTMLException
public static HTMLSpan AddSpanToCell(HTMLTableCell myCell)
myCell
-
HTMLException
public static HTMLTable AddTable(HTMLElementCollection result)
result
-
HTMLException
public static HTMLTable AddListTable(HTMLElementCollection result)
result
-
HTMLException
public static HTMLTable MakeTable()
HTMLException
public static HTMLTable MakeListTable()
HTMLException
public static HTMLTableCell AddTextAreaCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String sDefaultValue, java.lang.String sHTMLID)
myRow
- colspan
- sDefaultValue
- sHTMLID
-
HTMLException
public static HTMLTableCell AddTextCell(HTMLTableRow myRow, java.lang.String colspan, java.lang.String strText)
myRow
- colspan
- strText
-
HTMLException
public static HTMLTableCell AddTextCellReferencable(HTMLTableRow myRow, java.lang.String colspan, java.lang.String strText, java.lang.String spanId)
myRow
- colspan
- strText
-
HTMLException
public static java.lang.String GetAdminFolderPath(IPTSession ptSession, int nAdminFolderID)
public static int GetQRValueAsInt(IASQueryResult ptQR, int nRowIndex, int nPropID)
ptQR
- nRowIndex
- nPropID
-
public static java.lang.String GetQRValueAsString(IASQueryResult ptQR, int nRowIndex, int nPropID)
ptQR
- nRowIndex
- nPropID
-
public static HTMLElement MakeCreateObjectLink(int nCLASSID, java.lang.String strProviderCLSID, int nFolderID, java.lang.String strLink, AActivitySpace asOwner, java.lang.String strArgs, boolean bCloseWindowOnExit)
nCLASSID
- strProviderCLSID
- nFolderID
- strLink
- asOwner
- strArgs
- bCloseWindowOnExit
-
HTMLException
public static HTMLElement MakeSimpleButton(java.lang.String strText, java.lang.String strOnClick)
strText
- strOnClick
-
HTMLException
public static HTMLElement MakeSimpleButton(java.lang.String strText, java.lang.String strOnClick, java.lang.String strHTML)
strText
- strOnClick
- strHTML
-
HTMLException
public static void SetRowColor(HTMLTableCell myCell, boolean bRowColor)
myCell
- bRowColor
- public static java.lang.String ValidateNumericInputJS(java.lang.String strFormName, java.lang.String strInputName, java.lang.String strError)
strFormName
- strInputName
- strError
-
|
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |