MCPcopy Create free account
hub / github.com/OpenSourcePhysics/osp / createTabs

Method createTabs

src/org/opensourcephysics/tools/DataTool.java:507–517  ·  view source on GitHub ↗

Creates a tab for each Data object returned by DataTool.getDataList(source). The tab names will be those of the Data objects in the list if they define a getName() method. @param source the source Data @return a list of new tabs

(Data source)

Source from the content-addressed store, hash-verified

505 * @return a list of new tabs
506 */
507 public ArrayList<DataToolTab> createTabs(Data source) {
508 ArrayList<Data> dataList = getSelfContainedData(source);
509 ArrayList<DataToolTab> tabList = new ArrayList<DataToolTab>();
510 for (Data next : dataList) {
511 DataToolTab tab = createTab(next);
512 if (tab != null) {
513 tabList.add(tab);
514 }
515 }
516 return tabList;
517 }
518
519 /**
520 * Creates a tab for the specified Data object. The tab name will be that of the

Callers 1

DataToolMethod · 0.95

Calls 3

getSelfContainedDataMethod · 0.95
createTabMethod · 0.95
addMethod · 0.45

Tested by

no test coverage detected