Check for optimizations when looking for missing updates (#18317)
A recently merged patch leaves out information from hierarchyInfo for
empty connectors with state changes. This must be taken into account
when looking for disappeared connectors that do not cause any hierarchy
change to be sent.
Change-Id: I9ae7150341a83798141d0a2806ee81cafe7c2f9a
Make Vaadin component handling proxy-friendly (#14639)
Comparisons with the ==-operator between a proxy and it's underlying
instance fail, so we should use a custom equals method instead.
Change-Id: Iaa86ae830fecbedfb1f55636e25f5affebf5aba3
Optimizes initial sizes of frequently used Collections. (#14223)
There are a few places in frequently used core classes which could
initialize collection classes with the correct (or slightly oversized)
length.
Maps are initialized with 2x the size due to its load factor.
Change-Id: I3aee5a60602937a8550ca5a200ec2a529ff36fe9
Avoid object creation in getAllChildrenIterable in most cases. (#14142)
API change from:
public static Iterable<ClientConnector> getAllChildrenIterable(final ClientConnector connector)
to
public static Iterable<? extends ClientConnector> getAllChildrenIterable(final ClientConnector connector)
avoids creating wrappers in case the component has either no subcomponents
or no extensions. This covers the vast majority of components.
Change-Id: I48ffd2f26f09c265fae6e1aaabdbaa655d52ffb8
cleanConnectorMap is a hot method.
This change improves multiple code paths:
1) The global resource handler is no longer get()ed from the session for
each connector (was in two loops).
2) The ConnectorTracker is no longer get()ed from the UI for each
connector (was in one loop).
3) values() iterator for ClientConnectors replaces
keySet() iterator + get(key) call
4) use getUI() from ClientConnector instead manual method.
5) moved removeUnregisteredConnectors to ease inlining and readability.
Change-Id: I25ff5bc32d27d30ecd8d354922ec6e4a02b05921
* ConnectorTracker.getConnector() is now DnDService-aware
* Deprecated LCM.getDragAndDropService() is removed
* LCM.getConnector() simply delegates to ConnectorTracker.getConnector()
Change-Id: I9627d50f7386ead8d92ccbba27b4a558c03076c7
Improving performance of ConnectorTracker (#12218)
Swapping the if check in cleanConnectorMap to prevent unnecessary calls to
isComponentVisible when the connector is in uninitializedConnectors set.
Change-Id: If6305a908364f8a7bb51fd7302449c6f54c274a3
Removed CommunicationManager and PortletCommunicationManager
* Moved AbstractCommunicationManager abstract methods
getThemeResourceAsStream and createBootstrapHandler to VaadinService
* Made ACM non-abstract and renamed to LegacyCommunicationManager
* Lifted anonymous inner BootstrapHandler subclasses into named public classes
Change-Id: I31739ce8a506d572e75ca8cd5509be215e01693d
* Move UIDL writing from AbstractCommunicationManager to UidlWriter
* Move request handling from ACM to RequestHandlers
* Move server RPC message handling to ServerRpcHandler
* Move portlet event notifications to PortletListenerNotifier (a RequestHandler)
* Communication handlers reside in c.v.server.communication
Change-Id: I087e923dbdf88c6b3fcaafbdb7f685d9d3dad0c1
Don't remove diffstate data before cleanup (#10532)
* Avoid returning unregistered but not cleaned connectors from e.g.
getDirtyConnectors() and getConnector()
* Add some sanity checks to ensure unregistered connectors are not used
Change-Id: I1103586863d2f299d50af5058233a7b4c967d4c6
Moved StreamVariable handling from AbstractCommunicationManager to
ConnectorTracker to prevent untimely unregistrations through other UIs
within the same session (#10112)
Change-Id: Id04c97970325be65b0b3c63756a2f2e731dd60d2
Serialize and deserialize diff state manually (#9717, #9767)
Extended UISerialization test to both serialize and deserialize and also validate ConnectorTracker (de)serialization
Change-Id: Ifb8228bd56ec3635e4267e78160eef14dd9ff318
Automatic rename in Eclipse of the class Root to UI with all
rename options enabled, rename also embedded "Root" in
variable and method names.
The following classes/methods were excluded in the rename:
- BootstrapHandler.getApplicationCSSClassName()
- ComponentLocator
- ConnectorMap
- ItemClickEvent
- KeepAllItemsVisible
- MenuBarTest
- MenuBarTooltips
- TreeTableTest
- TreeWithIcons
- Trees
- VDebugConsole.printLayoutProblems()