i have dynamic data model.
i binded shape visibility, color and other all properties to my shape.
i manage these properties with a key.
İf active key data is not null in node data then i return active view values(color,boderderColor,stroke,vs…).
example node color binding:
I use geometry string to get the shape I want.
i have a panel and i binding “itemArray”.
Shapes in item array have binding methods.
Suppose that these shapes consist of 5 parts and i have 6 bindings method and diagram in nodes count 1000.
in this case 30.000 function runned.
is it true ?
(shape count) * (binding method count) *(node count)=Runned function count
only for click event or other events runned function count calculated.
It’s hard for me to understand exactly what the performance questions are. Yes, if you have that many objects and bindings, at least at load time there will be that many binding evaluations, if not more. But in your example, 30000 is a small number for 1000 nodes when each node is so complicated.
When might the value of this.getActiveView() change?
User can change it at any time.
At any time after installation.
you can even add a few objects and add a new view to “activeView”.
When you do this, a blank page will welcome you no matter how many nodes are on the diagram
As far as I can tell, “gojs” libraries are running all bind methods in the slightest change.
for example event “select object” or i call “diagram.updateAllTargetBindigs”.
and gojs can run all items binding methods?
It almost sounds as if each view were separate layers or even separate diagrams. If that is the case and you are worried about performance, it might make sense to implement them as separate models shown in a single diagram with a single fixed view.
Regarding binding evaluations: that depends on how you defined the bindings, which is still unclear to me. Normally selection would not affect any bindings.
But yes, you would expect that calling Diagram.updateAllTargetBindings would evaluate all Bindings for all GraphObjects.
I have no idea of what all the dependencies are in your app. So I really cannot say.
Is everything working correctly and efficiently enough with a largest-possible diagram test case? If not, you’ll need to be a lot more detailed describing the relationships of various objects and how those objects and those relationships might change.