Interface MindMap
- All Superinterfaces:
- MindMapRO
- All Known Subinterfaces:
- Map,- Proxy.Map,- Proxy.MindMap
node.map - read-write.- 
Method SummaryModifier and TypeMethodDescriptionvoidaddListener(NodeChangeListener listener) booleanclose(boolean force, boolean allowInteraction) closes a map.voidcopyConditionalStylesFrom(MindMap source, String styleName) Copies a style and its conditional style rules from another mind map into this mind map.voidcopyStyleFrom(MindMap source, String styleName) Copies a style from another mind map into this mind map.copyUserStylesFrom(MindMap source) Copies all user styles and their conditional style rules from another mind map into this one.copyUserStylesFrom(MindMap source, boolean includeConditionalRules) Copies all user styles from another mind map into this one.copyUserStylesFrom(MindMap source, boolean includeConditionalRules, String... styleNameFilters) Copies one or more user styles from another mind map into this one.copyUserStylesFrom(MindMap source, boolean includeConditionalRules, ArrayList<String> styleNameFilters) Copies one or more user styles from another mind map into this one.copyUserStylesFrom(MindMap source, String... styleNameFilters) Copies one or more user styles and their conditional style rules from another mind map into this one.copyUserStylesFrom(MindMap source, ArrayList<String> styleNameFilters) Copies one or more user styles and their conditional style rules from another mind map into this one.voidEvaluate all formulas in the map.voidEvaluate probably changed formulas in the map.voidfilter(boolean showAncestors, boolean showDescendants, NodeCondition condition) install a lambda as the current filter in this map.voidfilter(NodeCondition condition) Withfilter(boolean, boolean, NodeCondition)neither ancestors not descendants of the visible nodes are shown.returns an accessor to the map specific storage.voidhide(boolean hideAncestors, boolean hideDescendants, NodeCondition condition) Hides nodes matching given condition.voidreinstalls the previously undone filter if there is any.voidremoveListener(NodeChangeListener listener) booleansave(boolean allowInteraction) saves the map to disk.booleansaves the map to disk.voidsetAssociatedTemplate(URI uri) Setsurias Associated Template, template-normalizing it first if the location is in User- or Standard-Templates Directory, i.e.voidsetBackgroundColor(Color color) voidsetBackgroundColorCode(String rgbString) voidsetFilter(boolean showAncestors, boolean showDescendants, NodeCondition condition) Deprecated.use filtervoidsetFilter(NodeCondition condition) alias forfilter(NodeCondition).voidsetFollowedMap(URI uri) Setsurias Followed Map, template-normalizing it first if the location is in User- or Standard-Templates Directory, e.g.voidSets the map (frame/tab) title.voidsetSaved(boolean isSaved) voidremoves the current filter and reinstalls the previous filter if there is any.Methods inherited from interface org.freeplane.api.MindMapROgetAssociatedTemplate, getAssociatedTemplateFile, getBackgroundColor, getBackgroundColorCode, getConditionalStyles, getFile, getFollowedMap, getFollowedMapFile, getName, getRoot, getRootNode, getUserDefinedStylesNames, isSaved, node
- 
Method Details- 
closeboolean close(boolean force, boolean allowInteraction) closes a map. Note that there is no undo for this method!- Parameters:
- force- close map even if there are unsaved changes.
- allowInteraction-- if (allowInteraction && ! force)a saveAs dialog will be opened if there are unsaved changes.
- Returns:
- false if the saveAs was cancelled by the user and true otherwise.
- Throws:
- RuntimeException- if the map contains changes and parameter force is false.
- Since:
- 1.2
 
- 
saveboolean save(boolean allowInteraction) saves the map to disk. Note that there is no undo for this method.- Parameters:
- allowInteraction- if a saveAs dialog should be opened if the map has no assigned URL so far.
- Returns:
- false if the saveAs was cancelled by the user and true otherwise.
- Throws:
- RuntimeException- if the map has no assigned URL and parameter allowInteraction is false.
- Since:
- 1.2
 
- 
saveAssaves the map to disk. Note that there is no undo for this method.- Parameters:
- file- the location of the file to be saved.
- Returns:
- false if the saveAs was cancelled by the user and true otherwise.
- Throws:
- RuntimeException- if the map has no assigned URL and parameter allowInteraction is false.
- Since:
- 1.2
 
- 
setSavedvoid setSaved(boolean isSaved) - Since:
- 1.2
 
- 
setNameSets the map (frame/tab) title. Note that there is no undo for this method!- Since:
- 1.2
 
- 
setBackgroundColor- Since:
- 1.2
 
- 
setBackgroundColorCode- Parameters:
- rgbString- a HTML color spec like #ff0000 (red) or #222222 (darkgray).
- Since:
- 1.2
 
- 
filterWithfilter(boolean, boolean, NodeCondition)neither ancestors not descendants of the visible nodes are shown.- Since:
- 1.2
- See Also:
 
- 
setFilteralias forfilter(NodeCondition). Enables assignment to thefilterproperty.- Since:
- 1.2
 
- 
filterinstall a lambda as the current filter in this map. Ifconditionis null then filtering will be disabled. The filter state of a node can be checked byNodeRO.isVisible().
 To undo filtering use Tools → Undo. After execution of the following you have to use it seven times to return to the initial filter state.// show only matching nodes node.map.filter{ it.text.contains("todo") } // equivalent: node.map.filter = { it.text.contains("todo") } // show ancestors of matching nodes node.map.filter(true, false){ it.text.contains("todo") } // equivalent: node.map.setFilter(true, false, { it.text.contains("todo") }) // show descendants of matching nodes node.map.filter(false, true){ it.text.contains("todo") } // equivalent: node.map.setFilter(false, true, { it.text.contains("todo") }) // remove filter node.map.filter = null- Parameters:
- showAncestors- whether to show ancestors or not.
- showDescendants- whether to show descendant or not.
- condition- filter the map using this lamda.
- Since:
- 1.2
 
- 
hideHides nodes matching given condition.- Parameters:
- hideAncestors- whether to hide ancestors or not.
- hideDescendants- whether to hide descendant or not.
- condition- filter the map using this lamda.
- Since:
- 1.8.1
- See Also:
 
- 
setFilterDeprecated.use filteralias forfilter(boolean, boolean, NodeCondition)- Since:
- 1.2
- See Also:
 
- 
redoFiltervoid redoFilter()reinstalls the previously undone filter if there is any. Note: undo/redo for filters is separate to the undo/redo for other map state.- Since:
- 1.2
 
- 
undoFiltervoid undoFilter()removes the current filter and reinstalls the previous filter if there is any. Note: undo/redo for filters is separate to the undo/redo for other map state.- Since:
- 1.2
 
- 
getStorageProperties getStorage()returns an accessor to the map specific storage. The value is never null- Since:
- 1.3.6
 
- 
evaluateAllFormulasvoid evaluateAllFormulas()Evaluate all formulas in the map. Each formula in the map is evaluated not depending on if it was already cached.- Since:
- 1.7.2
 
- 
evaluateOutdatedFormulasvoid evaluateOutdatedFormulas()Evaluate probably changed formulas in the map. Each formula not having valid result in the cache is evaluated.- Since:
- 1.7.2
 
- 
addListener
- 
removeListener
- 
getListenersList<NodeChangeListener> getListeners()
- 
copyStyleFromCopies a style from another mind map into this mind map.- Since:
- 1.9.8
 
- 
copyConditionalStylesFromCopies a style and its conditional style rules from another mind map into this mind map.- Since:
- 1.9.8
 
- 
copyUserStylesFromList<String> copyUserStylesFrom(MindMap source, boolean includeConditionalRules, String... styleNameFilters) Copies one or more user styles from another mind map into this one.- Parameters:
- source- mind map containing the desired style(s)
- includeConditionalRules- whether to include conditional style rules or not.
- styleNameFilters- one or more strings to indicate which styles should be copied (REGEX match)
- Returns:
- list with the names of the copied styles
- Since:
- 1.11.9
 
- 
copyUserStylesFromList<String> copyUserStylesFrom(MindMap source, boolean includeConditionalRules, ArrayList<String> styleNameFilters) Copies one or more user styles from another mind map into this one.- Parameters:
- source- mind map containing the desired style(s)
- includeConditionalRules- whether to include conditional style rules or not.
- styleNameFilters- ArrayList of strings to indicate which styles should be copied (REGEX match)
- Returns:
- list with the names of the copied styles
- Since:
- 1.11.9
- See Also:
 
- 
copyUserStylesFromCopies all user styles and their conditional style rules from another mind map into this one.Note: equivalent to: copyUserStylesFrom(source, true, ".*")- Parameters:
- source- mind map containing the desired style(s)
- Returns:
- list with the names of the copied styles
- Since:
- 1.11.9
- See Also:
 
- 
copyUserStylesFromCopies one or more user styles and their conditional style rules from another mind map into this one.Note: equivalent to: copyUserStylesFrom(source, true, styleNameFilters)- Parameters:
- source- mind map containing the desired style(s)
- styleNameFilters- one or more strings to indicate which styles should be copied (REGEX match)
- Returns:
- list with the names of the copied styles
- Since:
- 1.11.9
- See Also:
 
- 
copyUserStylesFromCopies one or more user styles and their conditional style rules from another mind map into this one.Note: equivalent to: copyUserStylesFrom(source, true, styleNameFilters)- Parameters:
- source- mind map containing the desired style(s)
- styleNameFilters- ArrayList of strings to indicate which styles should be copied (REGEX match)
- Returns:
- list with the names of the copied styles
- Since:
- 1.11.9
- See Also:
 
- 
copyUserStylesFromCopies all user styles from another mind map into this one.Note: equivalent to: copyUserStylesFrom(source, includeConditionalRules, ".*")- Parameters:
- source- mind map containing the desired style(s)
- includeConditionalRules- whether to include conditional style rules or not.
- Returns:
- list with the names of the copied styles
- Since:
- 1.11.9
- See Also:
 
- 
setFollowedMapSets urias Followed Map, template-normalizing it first if the location is in User- or Standard-Templates Directory, e.g.
 fromfile:/home/macmarrum/.config/freeplane/1.11.x/templates/the-file.mm
 totemplate:/the-file.mm// Unfollows a mind map node.mindMap.followedMap = null // Follows a mind map, using an absolute path - a standard string is used, therefore backslashes (path separators) must be escaped node.mindMap.followedMap = new File('c:\\Users\\macmarrum\\Documents\\My top-level mind map.mm').toURI() // Follows a template, using an absolute path - a slashy string is used, therefore backslashes (path separators) mustn't be escaped node.mindMap.followedMap = new File(/c:\Users\macmarrum\AppData\Roaming\Freeplane\1.11.x\templates\My template.mm/).toURI() // Follows a template, using atemplate:URI node.mindMap.followedMap = new URI('template:/My%20template.mm')- Parameters:
- uri- Followed-Map URI or- nullto unfollow
- Since:
- 1.11.11
 
- 
setAssociatedTemplateSets urias Associated Template, template-normalizing it first if the location is in User- or Standard-Templates Directory, i.e.
 fromfile:/home/macmarrum/.config/freeplane/1.11.x/templates/the-file.mm
 totemplate:/the-file.mm// Clears the template association node.mindMap.associatedTemplate = null // Associates a template with the mind map, using an absolute path - a slashy string is used, therefore backslashes (path separators) mustn't be escaped node.mindMap.associatedTemplate = new File(/c:\Users\macmarrum\AppData\Roaming\Freeplane\1.11.x\templates\My template.mm/).toURI() // Associates a template with the mind map, using a template:URI node.mindMap.associatedTemplate = new URI('template:/My%20template.mm')- Parameters:
- uri- Associated-Template URI or- nullto remove it
- Since:
- 1.11.11
 
 
-