use of com.mucommander.commons.file.osgi.FileProtocolService in project mucommander by mucommander.
the class Activator method start.
@Override
public void start(BundleContext context) throws Exception {
FileProtocolService service = new FileProtocolService() {
@Override
public String getSchema() {
return "vsphere";
}
@Override
public ProtocolProvider getProtocolProvider() {
return new VSphereProtocolProvider();
}
@Override
public SchemeHandler getSchemeHandler() {
return new DefaultSchemeHandler(new DefaultSchemeParser(true), 443, "/", AuthenticationType.AUTHENTICATION_REQUIRED, null);
}
};
ProtocolPanelProvider panelProvider = new ProtocolPanelProvider() {
@Override
public String getSchema() {
return "vsphere";
}
@Override
public ServerPanel get(ServerPanelListener listener, JFrame mainFrame) {
return new VSpherePanel(listener, mainFrame);
}
@Override
public int priority() {
return 9000;
}
};
serviceRegistration = context.registerService(FileProtocolService.class, service, null);
uiServiceRegistration = context.registerService(ProtocolPanelProvider.class, panelProvider, null);
}
use of com.mucommander.commons.file.osgi.FileProtocolService in project mucommander by mucommander.
the class Activator method start.
@Override
public void start(BundleContext context) throws Exception {
FileProtocolService service = new FileProtocolService() {
@Override
public String getSchema() {
return "http";
}
@Override
public ProtocolProvider getProtocolProvider() {
return new HTTPProtocolProvider();
}
@Override
public SchemeHandler getSchemeHandler() {
return new DefaultSchemeHandler(new DefaultSchemeParser(true), 80, "/", AuthenticationType.AUTHENTICATION_OPTIONAL, null);
}
};
FileProtocolService service2 = new FileProtocolService() {
@Override
public String getSchema() {
return "https";
}
@Override
public ProtocolProvider getProtocolProvider() {
return new HTTPProtocolProvider();
}
@Override
public SchemeHandler getSchemeHandler() {
return new DefaultSchemeHandler(new DefaultSchemeParser(true), 443, "/", AuthenticationType.AUTHENTICATION_OPTIONAL, null);
}
};
ProtocolPanelProvider panelProvider = new ProtocolPanelProvider() {
@Override
public String getSchema() {
return "http";
}
@Override
public ServerPanel get(ServerPanelListener listener, JFrame mainFrame) {
return new HTTPPanel(listener, mainFrame);
}
@Override
public int priority() {
return 6000;
}
@Override
public Class<? extends ServerPanel> getPanelClass() {
return HTTPPanel.class;
}
};
serviceRegistration = context.registerService(FileProtocolService.class, service, null);
service2Registration = context.registerService(FileProtocolService.class, service2, null);
uiServiceRegistration = context.registerService(ProtocolPanelProvider.class, panelProvider, null);
}
use of com.mucommander.commons.file.osgi.FileProtocolService in project mucommander by mucommander.
the class Activator method start.
@Override
public void start(BundleContext context) throws Exception {
FileProtocolService service = new FileProtocolService() {
@Override
public String getSchema() {
return "ovirt";
}
@Override
public ProtocolProvider getProtocolProvider() {
return new OvirtProtocolProvider();
}
@Override
public SchemeHandler getSchemeHandler() {
return new DefaultSchemeHandler(new DefaultSchemeParser(true), 443, "/", AuthenticationType.AUTHENTICATION_REQUIRED, null);
}
};
ProtocolPanelProvider panelProvider = new ProtocolPanelProvider() {
@Override
public String getSchema() {
return "ovirt";
}
@Override
public ServerPanel get(ServerPanelListener listener, JFrame mainFrame) {
return new OvirtPanel(listener, mainFrame);
}
@Override
public int priority() {
return 7000;
}
};
serviceRegistration = context.registerService(FileProtocolService.class, service, null);
uiServiceRegistration = context.registerService(ProtocolPanelProvider.class, panelProvider, null);
}
use of com.mucommander.commons.file.osgi.FileProtocolService in project mucommander by mucommander.
the class Activator method start.
@Override
public void start(BundleContext context) throws Exception {
FileProtocolService service = new FileProtocolService() {
@Override
public String getSchema() {
return "gdrive";
}
@Override
public ProtocolProvider getProtocolProvider() {
return new GoogleDriveProtocolProvider();
}
@Override
public SchemeHandler getSchemeHandler() {
return new DefaultSchemeHandler(new DefaultSchemeParser(), 21, "/", AuthenticationType.NO_AUTHENTICATION, new Credentials("anonymous", "anonymous_coward@mucommander.com"));
}
};
ProtocolPanelProvider panelProvider = new ProtocolPanelProvider() {
@Override
public String getSchema() {
return "gdrive";
}
@Override
public ServerPanel get(ServerPanelListener listener, JFrame mainFrame) {
return new GoogleDrivePanel(listener, mainFrame);
}
@Override
public int priority() {
return 5000;
}
@Override
public Class<? extends ServerPanel> getPanelClass() {
return GoogleDrivePanel.class;
}
};
serviceRegistration = context.registerService(FileProtocolService.class, service, null);
uiServiceRegistration = context.registerService(ProtocolPanelProvider.class, panelProvider, null);
}
use of com.mucommander.commons.file.osgi.FileProtocolService in project mucommander by mucommander.
the class Activator method start.
@Override
public void start(BundleContext context) throws Exception {
FileProtocolService service = new FileProtocolService() {
@Override
public String getSchema() {
return "dropbox";
}
@Override
public ProtocolProvider getProtocolProvider() {
return new DropboxProtocolProvider();
}
@Override
public SchemeHandler getSchemeHandler() {
return new DefaultSchemeHandler(new DefaultSchemeParser(), 21, "/", AuthenticationType.NO_AUTHENTICATION, new Credentials("anonymous", "anonymous_coward@mucommander.com"));
}
};
ProtocolPanelProvider panelProvider = new ProtocolPanelProvider() {
@Override
public String getSchema() {
return "dropbox";
}
@Override
public ServerPanel get(ServerPanelListener listener, JFrame mainFrame) {
return new DropboxPanel(listener, mainFrame);
}
@Override
public int priority() {
return 5000;
}
@Override
public Class<? extends ServerPanel> getPanelClass() {
return DropboxPanel.class;
}
};
serviceRegistration = context.registerService(FileProtocolService.class, service, null);
uiServiceRegistration = context.registerService(ProtocolPanelProvider.class, panelProvider, null);
}
Aggregations