DB Snippets

From Developer Documents
Jump to navigation Jump to search

Finding all models in the project

Layer0 L0 = Layer0.getInstance(session);
SimulationResource SIMU = SimulationResource.getInstance(session);
Resource project = Simantics.getProject();
Collection<Resource> models = session.syncRequest(
    new ObjectsWithType(project, L0.ConsistsOf, SIMU.Model)
);