use of org.onosproject.app.ApplicationDescription in project onos by opennetworkinglab.
the class ApplicationArchiveTest method savePlainApp.
@Test
public void savePlainApp() throws IOException {
InputStream stream = getClass().getResourceAsStream("app.xml");
ApplicationDescription app = aar.saveApplication(stream);
validate(app);
stream.close();
}
use of org.onosproject.app.ApplicationDescription in project onos by opennetworkinglab.
the class ApplicationArchiveTest method saveSelfContainedApp.
@Test
public void saveSelfContainedApp() throws IOException {
InputStream stream = getClass().getResourceAsStream("app.scj");
ApplicationDescription app = aar.saveApplication(stream);
validate(app);
stream.close();
}
use of org.onosproject.app.ApplicationDescription in project onos by opennetworkinglab.
the class ApplicationArchiveTest method loadApp.
@Test
public void loadApp() throws IOException {
saveZippedApp();
ApplicationDescription app = aar.getApplicationDescription(APP_NAME);
validate(app);
}
use of org.onosproject.app.ApplicationDescription in project onos by opennetworkinglab.
the class ApplicationArchiveTest method saveZippedApp.
@Test
public void saveZippedApp() throws IOException {
InputStream stream = getClass().getResourceAsStream("app.zip");
ApplicationDescription app = aar.saveApplication(stream);
validate(app);
stream.close();
}
use of org.onosproject.app.ApplicationDescription in project onos by opennetworkinglab.
the class SimpleApplicationStore method loadFromDisk.
private void loadFromDisk() {
for (String name : getApplicationNames()) {
ApplicationId appId = idStore.registerApplication(name);
ApplicationDescription appDesc = getApplicationDescription(name);
DefaultApplication app = DefaultApplication.builder(appDesc).withAppId(appId).build();
apps.put(appId, app);
states.put(appId, isActive(name) ? INSTALLED : ACTIVE);
// load app permissions
}
}
Aggregations