当前位置: 首页>>代码示例>>Java>>正文


Java AdapterNonExistent类代码示例

本文整理汇总了Java中org.omg.PortableServer.POAPackage.AdapterNonExistent的典型用法代码示例。如果您正苦于以下问题:Java AdapterNonExistent类的具体用法?Java AdapterNonExistent怎么用?Java AdapterNonExistent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


AdapterNonExistent类属于org.omg.PortableServer.POAPackage包,在下文中一共展示了AdapterNonExistent类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: find_POA

import org.omg.PortableServer.POAPackage.AdapterNonExistent; //导入依赖的package包/类
/**
* Find and optionally activate the child POA with the given name.
*
* @param poa_name the name of the POA to find.
* @param activate_it if the child with the specified name is not found
* or inactive and this parameter is true, the target POA activator is
* invoked to activate that child. If this succeeds, that child POA
* is returned.
*
* @throws AdapterNonExistent if no active child with the given name
* is found and one of the following is true:
* a) the target POA has no associated
* {@link AdapterActivator}. b) that activator fails to activate the
* child POA. c) <code>activate_id</code> = false.
*/
public POA find_POA(String poa_name, boolean activate_it)
             throws AdapterNonExistent
{
  POA child;
  for (int i = 0; i < children.size(); i++)
    {
      child = (POA) children.get(i);
      if (child.the_name().equals(poa_name))
        return child;
    }

  if (activate_it && m_activator != null)
    {
      boolean activated = m_activator.unknown_adapter(this, poa_name);
      if (!activated)
        throw new AdapterNonExistent(poa_name + " activation failed.");

      // Tha activator should add the child to the childrent table.
      for (int i = 0; i < children.size(); i++)
        {
          child = (POA) children.get(i);
          if (child.the_name().equals(poa_name))
            return child;
        }
      throw new AdapterNonExistent(poa_name + " not created. ");
    }
  else
    throw new AdapterNonExistent(poa_name);
}
 
开发者ID:nmldiegues,项目名称:jvm-stm,代码行数:45,代码来源:gnuPOA.java

示例2: findPOA

import org.omg.PortableServer.POAPackage.AdapterNonExistent; //导入依赖的package包/类
/**
 * Finds the POA which corresponds to
 * 
 * @param request.
 *            If the request belongs to another POAManager it is bypassed to
 *            it, returning null.
 * @param request
 *            The queued request to be executed.
 * @returns POAImpl POA where the request must be executed.
 * @exception org.omg.PortableServer.POAPackage.AdapterNonExistent
 *                If it fails finding the POA.
 */
private POAImpl findPOA( QueuedRequest request )
    throws org.omg.PortableServer.POAPackage.AdapterNonExistent
{
    
    POAImpl current_poa;
    
    current_poa = request.getCurrentPOA();
    if( current_poa == null ){
        current_poa = this.m_orb.initPOA();
        request.setCurrentPOA( current_poa );
    }
    
    boolean bypassed = false;
    POAManagerImpl nextPOAManager;
    while ( !( bypassed || request.isFinalPOA() ) ) {
        current_poa = (POAImpl) current_poa.find_POA(
            request.getCurrentChildPOAName(),true
        );
        
        request.nextChildPOA(current_poa);
        
        nextPOAManager = (POAManagerImpl) current_poa.the_POAManager();

        if (nextPOAManager != m_poa_manager) {
            // bypass request to nextPOAManager
            if (m_trace != null) {
                m_trace.print(
                    Trace.DEEP_DEBUG,
                    new String[]{
                       toString(), " bypassing request ", request.toString(), 
                       " to ", current_poa.toString()
                    }
                );
            }
            nextPOAManager.put(request);
            bypassed = true;
        }
    }
    return ( bypassed )?null:current_poa;
}
 
开发者ID:AlvaroVega,项目名称:TIDorbJ,代码行数:53,代码来源:ExecThread.java

示例3: find_POA

import org.omg.PortableServer.POAPackage.AdapterNonExistent; //导入依赖的package包/类
/**
* Find and optionally activate the child POA with the given name.
*
* @param poa_name the name of the POA to find.
* @param activate_it if the child with the specified name is not found
* or inactive and this parameter is true, the target POA activator is
* invoked to activate that child. If this succeeds, that child POA
* is returned.
*
* @throws AdapterNonExistent if no active child with the given name
* is found and one of the following is true:
* a) the target POA has no associated
* {@link AdapterActivator}. b) that activator fails to activate the
* child POA. c) <code>activate_id</code> = false.
*/
POA find_POA(String poa_name, boolean activate_it)
      throws AdapterNonExistent;
 
开发者ID:vilie,项目名称:javify,代码行数:18,代码来源:POAOperations.java


注:本文中的org.omg.PortableServer.POAPackage.AdapterNonExistent类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。