本文整理了Java中org.restlet.Application.getConnectorService()
方法的一些代码示例,展示了Application.getConnectorService()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Application.getConnectorService()
方法的具体详情如下:
包路径:org.restlet.Application
类名称:Application
方法名:getConnectorService
[英]Returns the connector service. The service is enabled by default.
[中]返回连接器服务。默认情况下,该服务处于启用状态。
代码示例来源:origin: org.restlet.osgi/org.restlet
/**
* Returns the connector service associated to a request.
*
* @return The connector service associated to a request.
*/
public static org.restlet.service.ConnectorService getConnectorService() {
org.restlet.service.ConnectorService result = null;
org.restlet.Application application = org.restlet.Application
.getCurrent();
if (application != null) {
result = application.getConnectorService();
} else {
result = new org.restlet.service.ConnectorService();
}
return result;
}
代码示例来源:origin: org.restlet.osgi/org.restlet
Application application = (Application) next;
if (application.getConnectorService() != null) {
if (application.getConnectorService()
.getClientProtocols() != null) {
for (Protocol clientProtocol : application
.getConnectorService().getClientProtocols()) {
boolean clientFound = false;
if (application.getConnectorService()
.getServerProtocols() != null) {
for (Protocol serverProtocol : application
.getConnectorService().getServerProtocols()) {
boolean serverFound = false;
代码示例来源:origin: org.restlet/org.restlet
if (getConnectorService() != null) {
getConnectorService().start();
代码示例来源:origin: org.restlet/org.restlet
public synchronized void stop() throws Exception {
if (isStarted()) {
if (getConnectorService() != null) {
getConnectorService().stop();
代码示例来源:origin: org.restlet.osgi/org.restlet
.getChild();
if (!application.getConnectorService().getClientProtocols()
.contains(protocol)) {
getLogger()
内容来源于网络,如有侵权,请联系作者删除!