Package com.microstrategy.web.objects
Class WebFieldShortcutNodeImpl
- java.lang.Object
-
- com.microstrategy.web.objects.WebFieldShortcutNodeImpl
-
- All Implemented Interfaces:
WebFieldShortcutNode
,WebFormatHost
,WebNode
public class WebFieldShortcutNodeImpl extends java.lang.Object implements WebFieldShortcutNode
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
appendChild(WebNode newChild)
Appends the given node to the end of the current node's list of child nodes.void
clear()
Removes all child nodes from the current node.void
clearPlaceHolder()
Deletes the place holder defined on this node.boolean
containsPrompts()
Returns true if this node or any of its children has prompts.WebNodePlaceHolder
createPlaceHolder()
Creates a place holder on this node.void
generateFormatDelta(WebFormat f, WebPropertyObj p)
boolean
getCanExpand()
Returns the value of the can expand property on the node.WebNode
getChild(int index)
Returns the child node with the given (0-based) index in the collection.int
getChildCount()
Returns the number of child nodes of the current node.int
getDataType()
Returns the datatype of the current node.WebDimty
getDimensionality()
Returns an object which can be used to specify the dimensionality of the node.int
getDimensionalityType()
Returns the dimensionality type of the current node.java.lang.String
getDisplayName()
Returns the currently set display name of this node.int
getExpressionType()
Returns the expression type of the current node.WebObjectsFactory
getFactory()
java.lang.String
getFieldKey()
Return the fieldKeyint
getFieldType()
Return the type of fieldWebNode
getFirstChild()
Returns the first child node of the current node, or null if the current node has no child nodes.boolean
getIsIndependentCSI()
Returns whether this node is independent from others.boolean
getIsSpliced()
Returns the value of the Is spliced property This is currently used in custom group elements.int
getKey()
Returns the key of this node.WebNode
getLastChild()
Returns the last child node of the current node, or null if the current node has no child nodes.java.lang.String
getName()
Return the name of fieldWebNode
getNextSibling()
Returns the current node's next sibling.java.lang.String
getNodeKey()
Return the nodeKeyint
getNodeType()
Returns the node type of the current node.WebNode
getParent()
Returns the parent of the current node, or null if this is the root node.WebNodePlaceHolder
getPlaceHolder()
Returns the place holder associated on this node.WebNode
getPreviousSibling()
Returns the current node's previous sibling.java.lang.String
getShortXML()
Return the short xml representation of the node.boolean
getShowChildren()
boolean
getShowParent()
int
getSubExpressionCount()
java.lang.String
getTag()
Returns the tag which is currently set on this node.int
getUCFlag()
Returns the value of ucFlag.boolean
hasChildNodes()
Returns true if this node has child nodes, false if it does not.boolean
hasPlaceHolder()
Returns whether this node has a place holder defined on it.void
insertAfter(WebNode newChild, WebNode refNode)
Adds the given node to the current node's list of child nodes immediately after the reference node.void
insertBefore(WebNode newChild, WebNode refNode)
Adds the given node to the current node's list of child nodes immediately before the reference node.boolean
isCancelledPrompt()
void
removeChild(WebNode childNode)
Removes the given node from the collection of child nodes.void
replaceChild(WebNode newChild, WebNode oldChild)
Replaces the old node with the given new node in the expression.void
setCanExpand(boolean b)
Sets the can expand property.void
setDataType(int _dataType)
Sets the datatype of the current node.void
setDimensionalityType(int dimensionalityType)
Sets the dimensionality type of the current node.void
setDisplayName(java.lang.String _displayName)
Sets the display name of this node to the given value.void
setExpressionType(int _expressionType)
Sets the expression type of the current node to the given type.void
setFieldKey(java.lang.String _fieldKey)
set field keyvoid
setFieldType(int _fieldType)
set field typevoid
setIsIndependentCSI(boolean isIndependentCSI)
Sets the node whether it is independent from others.void
setIsSpliced(boolean b)
Sets the is spliced property.void
setName(java.lang.String _name)
set namevoid
setNodeKey(java.lang.String _nodeKey)
set node keyprotected void
setNodeType(int _nodeType)
Set node typevoid
setShowChildren(boolean value)
void
setShowParent(boolean value)
void
setTag(java.lang.String _tag)
Sets the tag on the node.void
setUCFlag(int flag)
Sets the value of ucFlag.java.lang.String
toString()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.microstrategy.web.objects.WebNode
appendChild, clear, clearPlaceHolder, containsPrompts, createPlaceHolder, getCanExpand, getChild, getChildCount, getDataType, getDimensionality, getDimensionalityType, getDisplayName, getExpressionType, getFirstChild, getIsIndependentCSI, getIsSpliced, getKey, getLastChild, getNextSibling, getNodeType, getParent, getPlaceHolder, getPreviousSibling, getShortXML, getTag, getUCFlag, hasChildNodes, hasPlaceHolder, insertAfter, insertBefore, isCancelledPrompt, removeChild, replaceChild, setCanExpand, setDataType, setDimensionalityType, setDisplayName, setExpressionType, setIsIndependentCSI, setIsSpliced, setTag, setUCFlag
-
-
-
-
Method Detail
-
setNodeKey
public void setNodeKey(java.lang.String _nodeKey)
Description copied from interface:WebFieldShortcutNode
set node key- Specified by:
setNodeKey
in interfaceWebFieldShortcutNode
-
getNodeKey
public java.lang.String getNodeKey()
Description copied from interface:WebFieldShortcutNode
Return the nodeKey- Specified by:
getNodeKey
in interfaceWebFieldShortcutNode
- Returns:
- {String} nodeKey
-
setFieldKey
public void setFieldKey(java.lang.String _fieldKey)
Description copied from interface:WebFieldShortcutNode
set field key- Specified by:
setFieldKey
in interfaceWebFieldShortcutNode
-
getFieldKey
public java.lang.String getFieldKey()
Description copied from interface:WebFieldShortcutNode
Return the fieldKey- Specified by:
getFieldKey
in interfaceWebFieldShortcutNode
- Returns:
- {String} fieldKey
-
setName
public void setName(java.lang.String _name)
Description copied from interface:WebFieldShortcutNode
set name- Specified by:
setName
in interfaceWebFieldShortcutNode
-
getName
public java.lang.String getName()
Description copied from interface:WebFieldShortcutNode
Return the name of field- Specified by:
getName
in interfaceWebFieldShortcutNode
- Returns:
- {String} name
-
setFieldType
public void setFieldType(int _fieldType)
Description copied from interface:WebFieldShortcutNode
set field type- Specified by:
setFieldType
in interfaceWebFieldShortcutNode
-
getFieldType
public int getFieldType()
Description copied from interface:WebFieldShortcutNode
Return the type of field- Specified by:
getFieldType
in interfaceWebFieldShortcutNode
- Returns:
- {int} fieldType
-
getShowChildren
public boolean getShowChildren()
-
setShowChildren
public void setShowChildren(boolean value)
-
getShowParent
public boolean getShowParent()
-
setShowParent
public void setShowParent(boolean value)
-
getTag
public java.lang.String getTag()
Description copied from interface:WebNode
Returns the tag which is currently set on this node. The tag is a user-defined piece of information which can be attached to a node, and will be persisted with the expression's state.
-
isCancelledPrompt
public boolean isCancelledPrompt()
- Specified by:
isCancelledPrompt
in interfaceWebNode
-
setTag
public void setTag(java.lang.String _tag)
Description copied from interface:WebNode
Sets the tag on the node. If this value is null, the current tag will be removed.
-
setExpressionType
public void setExpressionType(int _expressionType)
Description copied from interface:WebNode
Sets the expression type of the current node to the given type.- Specified by:
setExpressionType
in interfaceWebNode
- Parameters:
_expressionType
- The expression type to use for the node, fromEnumDSSXMLExpressionType
.- See Also:
WebNode.getExpressionType()
-
getExpressionType
public int getExpressionType()
Description copied from interface:WebNode
Returns the expression type of the current node.- Specified by:
getExpressionType
in interfaceWebNode
- Returns:
- The expression type of the node, from
EnumDSSXMLExpressionType
. - See Also:
WebNode.setExpressionType(int)
-
getNodeType
public int getNodeType()
Description copied from interface:WebNode
Returns the node type of the current node. This is set upon creation of the node, and cannot be changed.- Specified by:
getNodeType
in interfaceWebNode
- Returns:
- The node type of the node, from
EnumDSSXMLNodeType
.
-
setNodeType
protected void setNodeType(int _nodeType)
Set node type- Parameters:
_nodeType
- node type
-
getDataType
public int getDataType()
Description copied from interface:WebNode
Returns the datatype of the current node.- Specified by:
getDataType
in interfaceWebNode
- Returns:
- The datatype of the current node, from
EnumDSSXMLDataType
. - See Also:
WebNode.setDataType(int)
-
setDataType
public void setDataType(int _dataType)
Description copied from interface:WebNode
Sets the datatype of the current node.- Specified by:
setDataType
in interfaceWebNode
- Parameters:
_dataType
- A value fromEnumDSSXMLDataType
, which will be used as the datatype of the current node.- See Also:
WebNode.getDataType()
-
getDimensionalityType
public int getDimensionalityType()
Description copied from interface:WebNode
Returns the dimensionality type of the current node.- Specified by:
getDimensionalityType
in interfaceWebNode
- Returns:
- The current dimensionality type of this node, from
EnumDSSXMLNodeDimty
. - See Also:
WebNode.setDimensionalityType(int)
-
getUCFlag
public int getUCFlag()
Description copied from interface:WebNode
Returns the value of ucFlag.
-
setUCFlag
public void setUCFlag(int flag)
Description copied from interface:WebNode
Sets the value of ucFlag.- Specified by:
setUCFlag
in interfaceWebNode
- Parameters:
flag
- The value to be set for ucFlag.- See Also:
WebNode.getUCFlag()
-
setDimensionalityType
public void setDimensionalityType(int dimensionalityType)
Description copied from interface:WebNode
Sets the dimensionality type of the current node.- Specified by:
setDimensionalityType
in interfaceWebNode
- Parameters:
dimensionalityType
- The dimensionality type to assign to this node, fromEnumDSSXMLNodeDimty
.- See Also:
WebNode.getDimensionalityType()
-
getDimensionality
public WebDimty getDimensionality()
Description copied from interface:WebNode
Returns an object which can be used to specify the dimensionality of the node. This will only be relevant if the dimensionality type is set to something other than the default (none).- Specified by:
getDimensionality
in interfaceWebNode
- Returns:
- An object of type
WebDimty
, which can then be used to specify dimensionality.
-
getDisplayName
public java.lang.String getDisplayName()
Description copied from interface:WebNode
Returns the currently set display name of this node.- Specified by:
getDisplayName
in interfaceWebNode
- Returns:
- The current display name of this node.
- See Also:
WebNode.setDisplayName(java.lang.String)
-
setDisplayName
public void setDisplayName(java.lang.String _displayName)
Description copied from interface:WebNode
Sets the display name of this node to the given value.- Specified by:
setDisplayName
in interfaceWebNode
- Parameters:
_displayName
- The display name to use when describing the node.- See Also:
WebNode.getDisplayName()
-
hasChildNodes
public boolean hasChildNodes()
Description copied from interface:WebNode
Returns true if this node has child nodes, false if it does not.- Specified by:
hasChildNodes
in interfaceWebNode
- Returns:
- Whether this node has child nodes.
-
getChildCount
public int getChildCount()
Description copied from interface:WebNode
Returns the number of child nodes of the current node.- Specified by:
getChildCount
in interfaceWebNode
- Returns:
- The number of child nodes, or 0 if none exist.
-
getSubExpressionCount
public int getSubExpressionCount()
-
getFirstChild
public WebNode getFirstChild()
Description copied from interface:WebNode
Returns the first child node of the current node, or null if the current node has no child nodes.- Specified by:
getFirstChild
in interfaceWebNode
- Returns:
- A
WebNode
object which is the first child (the index 0 child) of this node, or null if no children are found.
-
getLastChild
public WebNode getLastChild()
Description copied from interface:WebNode
Returns the last child node of the current node, or null if the current node has no child nodes.- Specified by:
getLastChild
in interfaceWebNode
- Returns:
- A
WebNode
object which is the last child (the last index child) of this node, or null if no children are found.
-
getChild
public WebNode getChild(int index) throws java.lang.IndexOutOfBoundsException
Description copied from interface:WebNode
Returns the child node with the given (0-based) index in the collection.
-
getParent
public WebNode getParent()
Description copied from interface:WebNode
Returns the parent of the current node, or null if this is the root node.
-
getPreviousSibling
public WebNode getPreviousSibling()
Description copied from interface:WebNode
Returns the current node's previous sibling. This will be a node with the same parent as the current node, but with 1 less index in the parent node's collection. This method will return null if the parent node does not exist, or if this is the first node in the parent node's collection.- Specified by:
getPreviousSibling
in interfaceWebNode
- Returns:
WebNode
The previous sibling, or null if none exists(i.e. this is the first child of its parent, or this is the root node).
-
getNextSibling
public WebNode getNextSibling()
Description copied from interface:WebNode
Returns the current node's next sibling. This will be a node with the same parent as the current node, but with 1 greater index in the parent node's collection. This method will return null if the parent node does not exist, or if this is the last node in the parent node's collection.- Specified by:
getNextSibling
in interfaceWebNode
- Returns:
WebNode
The next sibling, or null if none exists(i.e. this is the last child of its parent, or this is the root node).
-
appendChild
public void appendChild(WebNode newChild) throws java.lang.IllegalArgumentException
Description copied from interface:WebNode
Appends the given node to the end of the current node's list of child nodes. The node to be appended must be from the same expression as the node it is being appended to.- Specified by:
appendChild
in interfaceWebNode
- Parameters:
newChild
- The node to be appended.- Throws:
java.lang.IllegalArgumentException
- Thrown if the given node is null or if the node being appended is from a different expression.
-
insertBefore
public void insertBefore(WebNode newChild, WebNode refNode) throws java.lang.IllegalArgumentException
Description copied from interface:WebNode
Adds the given node to the current node's list of child nodes immediately before the reference node.- Specified by:
insertBefore
in interfaceWebNode
- Parameters:
newChild
- The node to be appended.refNode
- The node before which the new node is to be inserted.- Throws:
java.lang.IllegalArgumentException
- Thrown if either node is null, if the reference node is not found, or if the node to insert belongs to a different expression.
-
replaceChild
public void replaceChild(WebNode newChild, WebNode oldChild) throws java.lang.IllegalArgumentException
Description copied from interface:WebNode
Replaces the old node with the given new node in the expression.- Specified by:
replaceChild
in interfaceWebNode
- Parameters:
newChild
- The node to be used as the replacement.oldChild
- The node to be replaced.- Throws:
java.lang.IllegalArgumentException
- Signals that one or both input parameters to this method were null, the reference node is not found, or the replacement node is from a different expression.
-
removeChild
public void removeChild(WebNode childNode) throws java.lang.IllegalArgumentException
Description copied from interface:WebNode
Removes the given node from the collection of child nodes.- Specified by:
removeChild
in interfaceWebNode
- Parameters:
childNode
- TheWebNode
object to be removed from the child collection.- Throws:
java.lang.IllegalArgumentException
- Signals that the given node is null or not found.
-
clear
public void clear()
Description copied from interface:WebNode
Removes all child nodes from the current node.
-
getKey
public int getKey()
Description copied from interface:WebNode
Returns the key of this node. Every node in an expression has a unique key, though they are not necessarily in order, or even consecutive.
-
insertAfter
public void insertAfter(WebNode newChild, WebNode refNode) throws java.lang.IllegalArgumentException
Description copied from interface:WebNode
Adds the given node to the current node's list of child nodes immediately after the reference node.- Specified by:
insertAfter
in interfaceWebNode
- Parameters:
newChild
- The node to be appended.refNode
- The node after which the new node is to be inserted.- Throws:
java.lang.IllegalArgumentException
- Thrown if either node is null, if the reference node is not found, or if the node to insert belongs to a different expression.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
- Since:
- MicroStrategy Web 8.0.1
-
generateFormatDelta
public void generateFormatDelta(WebFormat f, WebPropertyObj p)
- Specified by:
generateFormatDelta
in interfaceWebFormatHost
- Since:
- MicroStrategy Web 8.1.0
-
getFactory
public WebObjectsFactory getFactory()
- Specified by:
getFactory
in interfaceWebFormatHost
- Since:
- MicroStrategy Web 8.1.0
-
setCanExpand
public void setCanExpand(boolean b)
Description copied from interface:WebNode
Sets the can expand property. This is currently used in custom group elements.- Specified by:
setCanExpand
in interfaceWebNode
- See Also:
WebNode.getCanExpand()
-
setIsSpliced
public void setIsSpliced(boolean b)
Description copied from interface:WebNode
Sets the is spliced property. This is currently used in custom group elements.- Specified by:
setIsSpliced
in interfaceWebNode
- See Also:
WebNode.getIsSpliced()
-
getCanExpand
public boolean getCanExpand()
Description copied from interface:WebNode
Returns the value of the can expand property on the node. This is currently used in custom group elements.- Specified by:
getCanExpand
in interfaceWebNode
- Returns:
- See Also:
WebNode.setCanExpand(boolean)
-
getIsSpliced
public boolean getIsSpliced()
Description copied from interface:WebNode
Returns the value of the Is spliced property This is currently used in custom group elements.- Specified by:
getIsSpliced
in interfaceWebNode
- Returns:
- See Also:
WebNode.setCanExpand(boolean)
-
containsPrompts
public boolean containsPrompts()
Description copied from interface:WebNode
Returns true if this node or any of its children has prompts.- Specified by:
containsPrompts
in interfaceWebNode
- Returns:
- true if this node or any of its children has prompts.
-
getShortXML
public java.lang.String getShortXML()
Description copied from interface:WebNode
Return the short xml representation of the node.- Specified by:
getShortXML
in interfaceWebNode
- Returns:
-
hasPlaceHolder
public boolean hasPlaceHolder()
Description copied from interface:WebNode
Returns whether this node has a place holder defined on it.- Specified by:
hasPlaceHolder
in interfaceWebNode
- Returns:
- true if it has a place holder
-
getPlaceHolder
public WebNodePlaceHolder getPlaceHolder()
Description copied from interface:WebNode
Returns the place holder associated on this node.- Specified by:
getPlaceHolder
in interfaceWebNode
- Returns:
WebNodePlaceHolder
object. Null if there is no place holder.
-
clearPlaceHolder
public void clearPlaceHolder()
Description copied from interface:WebNode
Deletes the place holder defined on this node.- Specified by:
clearPlaceHolder
in interfaceWebNode
-
createPlaceHolder
public WebNodePlaceHolder createPlaceHolder()
Description copied from interface:WebNode
Creates a place holder on this node.- Specified by:
createPlaceHolder
in interfaceWebNode
- Returns:
- the newly created place holder
-
getIsIndependentCSI
public boolean getIsIndependentCSI()
Description copied from interface:WebNode
Returns whether this node is independent from others. It is used for metric qualifications.- Specified by:
getIsIndependentCSI
in interfaceWebNode
- Returns:
- true if it is independent
-
setIsIndependentCSI
public void setIsIndependentCSI(boolean isIndependentCSI)
Description copied from interface:WebNode
Sets the node whether it is independent from others.- Specified by:
setIsIndependentCSI
in interfaceWebNode
-
-