Package org.gjt.sp.jedit.manager
Class ViewManagerImpl
- java.lang.Object
-
- org.gjt.sp.jedit.manager.ViewManagerImpl
-
- All Implemented Interfaces:
ViewManager
public class ViewManagerImpl extends java.lang.Object implements ViewManager
This class contains view management code, those methods are not public and must only be used by jEdit. The public interface isViewManager
- Since:
- 5.6pre1
-
-
Field Summary
Fields Modifier and Type Field Description static View[]
EMPTY_VIEW_ARRAY
-
Constructor Summary
Constructors Constructor Description ViewManagerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addViewToList(View view)
void
forEach(java.util.function.Consumer<? super View> action)
Performs the given action for each view.View
getActiveView()
Returns the currently focused view.View
getActiveViewInternal()
Returns the internal active view, which might be null.View
getFirst()
View
getLast()
java.util.List<View>
getViews()
Returns an array of all open views.void
remove(View view)
void
setActiveView(View view)
int
size()
Returns the number of open views.
-
-
-
Field Detail
-
EMPTY_VIEW_ARRAY
public static final View[] EMPTY_VIEW_ARRAY
-
-
Method Detail
-
getViews
public java.util.List<View> getViews()
Returns an array of all open views.- Specified by:
getViews
in interfaceViewManager
-
forEach
public void forEach(java.util.function.Consumer<? super View> action)
Performs the given action for each view.- Specified by:
forEach
in interfaceViewManager
- Parameters:
action
- The action to be performed for each element- Throws:
java.lang.NullPointerException
- if the specified action is null
-
size
public int size()
Returns the number of open views.- Specified by:
size
in interfaceViewManager
-
getFirst
public View getFirst()
- Specified by:
getFirst
in interfaceViewManager
-
getLast
public View getLast()
- Specified by:
getLast
in interfaceViewManager
-
getActiveView
public View getActiveView()
Returns the currently focused view.- Specified by:
getActiveView
in interfaceViewManager
-
setActiveView
public void setActiveView(View view)
- Specified by:
setActiveView
in interfaceViewManager
-
getActiveViewInternal
@Nullable public View getActiveViewInternal()
Returns the internal active view, which might be null.- Specified by:
getActiveViewInternal
in interfaceViewManager
-
addViewToList
public void addViewToList(View view)
-
remove
public void remove(View view)
-
-