Package com.microstrategy.utils.config
Class ClientSideLayouts
- java.lang.Object
-
- com.microstrategy.utils.config.ClientSideLayouts
-
public class ClientSideLayouts extends java.lang.Object
This class provides the front-end from retrieving client-side layout contents for use with the Javascript UI Library (JUIL). It interacts with server-side caches to reduce the number of file accesses. In this respect, it is merely a helper class for client-side layouts.- Since:
- MicroStrategy Web 9.0.0
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
BLOCK_PROPERTY_LAYOUT_CLASS_NAME
The name of the Block Property that we will scan for layout classes.
-
Constructor Summary
Constructors Constructor Description ClientSideLayouts()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String
getLayoutClassName(java.lang.String layoutClass)
Returns the layout class name without the plugin macro.static java.lang.String
getLayoutStatement(java.lang.String layoutClass)
Returns a JavaScript statement which defines the layout for a given layout class.static void
getLayoutStatementsFromBlock(MarkupOutput out, Block block)
Get an entire set of JavaScript layout statements by scanning a Block tree for all layout classes that are defined in a specific named Block Property.static void
getLayoutStatementsFromBlock(MarkupOutput out, Block block, java.lang.String propName)
Get an entire set of JavaScript layout statements by scanning a Block tree for all layout classes that are defined in a specific named Block Property.static java.lang.String
getPlugin(java.lang.String layoutClass)
Returns the plugin macro contained in the layout class property.
-
-
-
Field Detail
-
BLOCK_PROPERTY_LAYOUT_CLASS_NAME
public static final java.lang.String BLOCK_PROPERTY_LAYOUT_CLASS_NAME
The name of the Block Property that we will scan for layout classes.- See Also:
- Constant Field Values
-
-
Method Detail
-
getLayoutStatement
public static java.lang.String getLayoutStatement(java.lang.String layoutClass)
Returns a JavaScript statement which defines the layout for a given layout class.- Parameters:
layoutClass
- The name of the layout class to retrieve.- Returns:
- A JavaScript statement that assigns to the layout class the
textual declaration of the layout. If the layout class does not
exist or is malformed, then
null
is returned.
-
getLayoutStatementsFromBlock
public static void getLayoutStatementsFromBlock(MarkupOutput out, Block block)
Get an entire set of JavaScript layout statements by scanning a Block tree for all layout classes that are defined in a specific named Block Property. The name of the Block Property to inspect is defined inBLOCK_PROPERTY_LAYOUT_CLASS_NAME
.- Parameters:
out
- TheMarkupOutput
to generate the JavaScript statements into.block
- TheBlock
instance to scan for layout classes referenced in a BlockProperty value.- See Also:
getLayoutStatementsFromBlock(MarkupOutput, Block)
-
getLayoutStatementsFromBlock
public static void getLayoutStatementsFromBlock(MarkupOutput out, Block block, java.lang.String propName)
Get an entire set of JavaScript layout statements by scanning a Block tree for all layout classes that are defined in a specific named Block Property.- Parameters:
out
- TheMarkupOutput
to generate the JavaScript statements into.block
- TheBlock
instance to scan for layout classes referenced in a BlockProperty value.propName
- The name of theBlockProperty
to inspect for layout class names.
-
getLayoutClassName
public static java.lang.String getLayoutClassName(java.lang.String layoutClass)
Returns the layout class name without the plugin macro.- Parameters:
layoutClass
- The layout class property value for the block. It may contains a plugin macro, such as "@plugin1:".- Returns:
- the layout class name without the plugin macro.
-
getPlugin
public static java.lang.String getPlugin(java.lang.String layoutClass)
Returns the plugin macro contained in the layout class property.- Parameters:
layoutClass
- The layout class property value for the block. It may contains a plugin macro, such as "@plugin1:".- Returns:
- the plugin macro, such as "@plugin1:".
-
-