當前位置: 首頁>>代碼示例>>Java>>正文


Java NotBoundException類代碼示例

本文整理匯總了Java中java.rmi.NotBoundException的典型用法代碼示例。如果您正苦於以下問題:Java NotBoundException類的具體用法?Java NotBoundException怎麽用?Java NotBoundException使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


NotBoundException類屬於java.rmi包,在下文中一共展示了NotBoundException類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: destroy

import java.rmi.NotBoundException; //導入依賴的package包/類
/**
 * Unbind the RMI service from the registry on bean factory shutdown.
 */
@Override
public void destroy() throws RemoteException {
	if (logger.isInfoEnabled()) {
		logger.info("Unbinding RMI service '" + this.serviceName +
				"' from registry" + (this.createdRegistry ? (" at port '" + this.registryPort + "'") : ""));
	}
	try {
		this.registry.unbind(this.serviceName);
	}
	catch (NotBoundException ex) {
		if (logger.isWarnEnabled()) {
			logger.warn("RMI service '" + this.serviceName + "' is not bound to registry"
					+ (this.createdRegistry ? (" at port '" + this.registryPort + "' anymore") : ""), ex);
		}
	}
	finally {
		unexportObjectSilently();
	}
}
 
開發者ID:lamsfoundation,項目名稱:lams,代碼行數:23,代碼來源:RmiServiceExporter.java

示例2: setUp

import java.rmi.NotBoundException; //導入依賴的package包/類
protected boolean setUp(){
	try{
		setUpEV3();
		setUpPorts();
		setUpShooter();
		return true;
	} catch(RemoteException | MalformedURLException | NotBoundException e){
		logger.error("Could not open ports " + e.getMessage());
		try{
			closePorts();
		} catch(RemoteException e1){
			logger.error("Error closing ports " + e1.getMessage());
		}
		return false;
	}
}
 
開發者ID:NEStock,項目名稱:Voice_Activated_EV3_Robot,代碼行數:17,代碼來源:EV3Agent.java

示例3: startLocator

import java.rmi.NotBoundException; //導入依賴的package包/類
private static void startLocator(Registry registry) throws IOException, NotBoundException {
  RemoteDUnitVMIF remote = (RemoteDUnitVMIF) registry.lookup("vm" + LOCATOR_VM_NUM);
  final File locatorLogFile =
      LOCATOR_LOG_TO_DISK ? new File("locator-" + locatorPort + ".log") : new File("");
  MethExecutorResult result = remote.executeMethodOnObject(new SerializableCallable() {
    public Object call() throws IOException {
      Properties p = getDistributedSystemProperties();
      // I never want this locator to end up starting a jmx manager
      // since it is part of the unit test framework
      p.setProperty("jmx-manager", "false");
      //Disable the shared configuration on this locator.
      //Shared configuration tests create their own locator
      p.setProperty("enable-cluster-configuration", "false");
      Locator.startLocatorAndDS(locatorPort, locatorLogFile, p);
      return null;
    }
  }, "call");
  if(result.getException() != null) {
    RuntimeException ex = new RuntimeException("Failed to start locator", result.getException());
    ex.printStackTrace();
    throw ex;
  }
}
 
開發者ID:ampool,項目名稱:monarch,代碼行數:24,代碼來源:DUnitLauncher.java

示例4: inheritedChannel

import java.rmi.NotBoundException; //導入依賴的package包/類
public synchronized Channel inheritedChannel() throws IOException {
    System.err.println("SP.inheritedChannel");
    if (channel == null) {
        channel = SocketChannel.open();
        Socket socket = channel.socket();
        System.err.println("socket = " + socket);

        /*
         * Notify test that inherited channel was created.
         */
        try {
            System.err.println("notify test...");
            Registry registry =
                LocateRegistry.getRegistry(TestLibrary.INHERITEDCHANNELNOTSERVERSOCKET_REGISTRY_PORT);
            Callback obj = (Callback) registry.lookup("Callback");
            obj.notifyTest();
        } catch (NotBoundException nbe) {
            throw (IOException)
                new IOException("callback object not bound").
                    initCause(nbe);
        }
    }
    return channel;
}
 
開發者ID:lambdalab-mirror,項目名稱:jdk8u-jdk,代碼行數:25,代碼來源:InheritedChannelNotServerSocket.java

示例5: refresh

import java.rmi.NotBoundException; //導入依賴的package包/類
@Override
public List<? extends IModel> refresh() throws RemoteException,
        ExternalServiceException, IOException, AuthenticationException,
        NotBoundException, InstantiationException, IllegalAccessException {
    List<Vrf> result = new ArrayList<Vrf>();

    List<String> inventoryIds = new ArrayList<String>();
    for (IModel target : getTargets()) {
        inventoryIds.add(target.getId());
    }
    for (String inventoryId : inventoryIds) {
        Vrf vrfModel = VrfModelCreator.createModel(VrfHandler.getVrfIfDto(inventoryId), inventoryId);
        result.add((Vrf) new VplsModelDisplayNameConverter().convertModel(vrfModel));
    }

    return result;
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:18,代碼來源:VrfRefresher.java

示例6: makeListView

import java.rmi.NotBoundException; //導入依賴的package包/類
@Override
public TableInput makeListView() throws RemoteException,
        AuthenticationException, InventoryException,
        ExternalServiceException, IOException, NotBoundException,
        InstantiationException, IllegalAccessException, ParseException {

    List<? extends IModel> vlanLinkList = new ArrayList<IModel>();

    for (String str : getQuery().keySet()) {
        log.debug(str + " : " + getQuery().getMatcher(str).hashCode());
    }

    if (hasMvoIdAsKeyInQuery()) {
        String mvoId = getMvoIdFromQuery();
        vlanLinkList = VlanLinkHandler.getList(mvoId);
    }
    return getConverter().convertList(vlanLinkList);
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:19,代碼來源:VlanLinkListViewMaker.java

示例7: makeListView

import java.rmi.NotBoundException; //導入依賴的package包/類
@Override
public TableInput makeListView() throws RemoteException,
        AuthenticationException, InventoryException,
        ExternalServiceException, IOException, NotBoundException,
        InstantiationException, IllegalAccessException, ParseException {

    List<? extends IModel> subnetList = new ArrayList<IModel>();

    if (hasInventoryIdAsKeyInQuery()) {
        String mvoId = getInventoryIdFromQuery();
        subnetList = SubnetIpHandler.getList(getQuery(), mvoId);
    } else {
        subnetList = SubnetIpHandler.getList(getQuery());
    }
    return getConverter().convertList(subnetList);
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:17,代碼來源:SubnetIpListViewMaker.java

示例8: build

import java.rmi.NotBoundException; //導入依賴的package包/類
public IDiagram build() throws RemoteException, InventoryException, ExternalServiceException, IOException, AuthenticationException, NotBoundException {
    IDiagram diagram = new Diagram();
    List<String> iRefs = new ArrayList<String>();
    diagram.setPropertyValue(IPropertyConstants.PROPERTY_INVENTORY_REFS, iRefs);
    diagram.setText("Whole LSP Topology");

    MplsNmsInventoryConnector conn = MplsNmsInventoryConnector.getInstance();
    for (RsvpLspIdPoolDto pool : conn.getRsvpLspIdPool()) {
        for (RsvpLspDto lsp : pool.getUsers()) {
            if (lsp.getHopSeries1() != null) {
                setModelsOnHopSeries(diagram, lsp.getHopSeries1().getHops(), true);
            }
            if (lsp.getHopSeries2() != null) {
                setModelsOnHopSeries(diagram, lsp.getHopSeries2().getHops(), false);
            }
        }
    }
    for (PhysicalLink link : this.linkCache.values()) {
        setPathStyle(link);
    }
    return diagram;
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:23,代碼來源:WholeRsvpLspDiagramBuilder.java

示例9: Client

import java.rmi.NotBoundException; //導入依賴的package包/類
public Client(String server) throws Exception {
	try {
		sampleCompany = (Company) Naming.lookup("//" + server + "/meganalysis");
	} catch (MalformedURLException malformedException) {
		System.err.println("Bad URL: " + malformedException);
	} catch (NotBoundException notBoundException) {
		System.err.println("Not Bound: " + notBoundException);
	} catch (RemoteException remoteException) {
		System.err.println("Remote Exception: " + remoteException);
	}
	
	demo();
}
 
開發者ID:amritbhat786,項目名稱:DocIT,代碼行數:14,代碼來源:Client.java

示例10: getItfAgteReactRemoto

import java.rmi.NotBoundException; //導入依賴的package包/類
public static ItfUsoAgenteReactivo getItfAgteReactRemoto(String host, String nombreAgente) throws RemoteException, NotBoundException {
//        Registry regCliente = LocateRegistry.getRegistry(ip, 1099);
//        ItfUsoAgenteReactivo agenteRemoto = null;
//        if (regCliente == null) return null;
//        else {
//            agenteRemoto = (ItfUsoAgenteReactivo) regCliente.lookup(nombreAgente);
//            return agenteRemoto;
//        }
        return getItfAgteReactRemoto (host, 1099, nombreAgente);
    }
 
開發者ID:Yarichi,項目名稱:Proyecto-DASI,代碼行數:11,代碼來源:AdaptadorRegRMI.java

示例11: get

import java.rmi.NotBoundException; //導入依賴的package包/類
public static List<Vrf> get(String inventoryId) throws NotBoundException, AuthenticationException, IOException, ExternalServiceException {
    List<Vrf> vrfList = new ArrayList<Vrf>();

    for (VrfIfDto vrf : VrfExtUtil.getVrfIfDtos()) {
        if (InventoryIdUtil.getInventoryId(vrf).equals(inventoryId)) {
            vrfList.add(VrfModelCreator.createModel(vrf, InventoryIdUtil.getInventoryId(vrf)));
        }
    }

    return vrfList;
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:12,代碼來源:VrfHandler.java

示例12: getItfUsoRecursoRemoto

import java.rmi.NotBoundException; //導入依賴的package包/類
public static Remote getItfUsoRecursoRemoto(String identHost, String nombreRecurso) throws RemoteException, NotBoundException {
            Registry regCliente = LocateRegistry.getRegistry(identHost);
            InterfazGestion agenteRemoto = null;
            if (regCliente == null) return null;
         else
//            agenteRemoto = (ItfUsoAgenteReactivo) regCliente.lookup(nombreAgente);
//            return agenteRemoto;
//        }
        return regCliente.lookup(NombresPredefinidos.ITF_USO+nombreRecurso);
    }
 
開發者ID:Yarichi,項目名稱:Proyecto-DASI,代碼行數:11,代碼來源:AdaptadorRegRMI.java

示例13: getList

import java.rmi.NotBoundException; //導入依賴的package包/類
public static List<PhysicalLink> getList(ObjectFilterQuery query) throws NotBoundException, AuthenticationException, IOException, ExternalServiceException {
    List<PhysicalLink> linkList = new ArrayList<PhysicalLink>();

    for (IpSubnetDto link : filterLinks(query, MplsNmsInventoryConnector.getInstance().getActiveIpSubnets())) {
        linkList.add(LinkModelCreator.createModel(link, InventoryIdUtil.getInventoryId(link)));
    }

    return linkList;
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:10,代碼來源:LinkHandler.java

示例14: getListUnderPseudoWire

import java.rmi.NotBoundException; //導入依賴的package包/類
public static List<LabelSwitchedPath> getListUnderPseudoWire(String pwInventoryId) throws AuthenticationException, NotBoundException, IOException, ExternalServiceException {
    List<LabelSwitchedPath> lspList = new ArrayList<LabelSwitchedPath>();

    for (PseudowireDto pw : MplsNmsInventoryConnector.getInstance().getDtoFacade().getPseudowires()) {
        if (PseudoWireRenderer.getPseudoWireID(pw).equals(PseudoWireHandler.parseVcId(pwInventoryId))) {
            appendLSPList(lspList, pw.getRsvpLsps());
        }
    }

    return lspList;
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:12,代碼來源:RsvpLspHandler.java

示例15: getListUpperLsp

import java.rmi.NotBoundException; //導入依賴的package包/類
public static List<PseudoWire> getListUpperLsp(String lspInventoryId) throws AuthenticationException,
        NotBoundException, IOException, ExternalServiceException {
    List<PseudoWire> pwList = new ArrayList<PseudoWire>();

    for (RsvpLspDto lsp : MplsNmsInventoryConnector.getInstance().getDtoFacade().getRsvpLsps()) {
        if (InventoryIdUtil.getInventoryId(lsp).equals(lspInventoryId)) {
            appendPwList(pwList, getPseudoWiresOn(lsp));
        }
    }
    return pwList;
}
 
開發者ID:openNaEF,項目名稱:openNaEF,代碼行數:12,代碼來源:PseudoWireHandler.java


注:本文中的java.rmi.NotBoundException類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。