public class GroupingHistoryRewriter extends Object implements HistoryRewriter<Location,CLocationMode>
HistoryRewriter gets the current CGroupingBehavior using the key CControl.GROUPING_BEHAVIOR
from its CControl. It then accesses the DockableGrouping of a Dockable to rewrite its history.
This rewriter makes use of another HistoryRewriter called "validation", to make sure that a valid location is
created.CControl will already have
a GroupingHistoryRewriter pre-installed.| Constructor and Description |
|---|
GroupingHistoryRewriter(CControl control,
HistoryRewriter<Location,CLocationMode> validation)
Creates a new
GroupingHistoryRewriter. |
| Modifier and Type | Method and Description |
|---|---|
Location |
rewrite(Dockable dockable,
CLocationMode mode,
Location history)
Checks whether the history object
history is still valid. |
public GroupingHistoryRewriter(CControl control, HistoryRewriter<Location,CLocationMode> validation)
GroupingHistoryRewriter.control - the CControl in whose realm this history rewriter worksvalidation - a rewriter that will be used to validate the location of dockablespublic Location rewrite(Dockable dockable, CLocationMode mode, Location history)
HistoryRewriterhistory is still valid.rewrite in interface HistoryRewriter<Location,CLocationMode>dockable - the element which is about to change its modemode - the mode that is going to be appliedhistory - the history object that will be forwarded to mode, may be nullnullCopyright © 2018. All rights reserved.