本文整理汇总了Java中org.omg.PortableServer.CurrentPackage.NoContext类的典型用法代码示例。如果您正苦于以下问题:Java NoContext类的具体用法?Java NoContext怎么用?Java NoContext使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
NoContext类属于org.omg.PortableServer.CurrentPackage包,在下文中一共展示了NoContext类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: has
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
/**
* Check if this Poa has some running threads.
*/
public boolean has(POA poa)
{
synchronized (threads)
{
Iterator iter = threads.entrySet().iterator();
while (iter.hasNext())
{
Map.Entry item = (Map.Entry) iter.next();
try
{
if (((CurrentOperations) item.getValue()).get_POA() == poa)
{
return true;
}
}
catch (NoContext ex)
{
throw new InternalError();
}
}
}
return false;
}
示例2: get_POA
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
public POA get_POA()
throws
NoContext
{
POA poa = (POA)(peekThrowNoContext().oa());
throwNoContextIfNull(poa);
return poa;
}
示例3: get_object_id
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
public byte[] get_object_id()
throws
NoContext
{
byte[] objectid = peekThrowNoContext().id();
throwNoContextIfNull(objectid);
return objectid;
}
示例4: peekThrowNoContext
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
private OAInvocationInfo peekThrowNoContext()
throws
NoContext
{
OAInvocationInfo invocationInfo = null;
try {
invocationInfo = orb.peekInvocationInfo() ;
} catch (EmptyStackException e) {
throw new NoContext();
}
return invocationInfo;
}
示例5: throwNoContextIfNull
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
private void throwNoContextIfNull(Object o)
throws
NoContext
{
if ( o == null ) {
throw new NoContext();
}
}
示例6: this_object
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
/**
* Get the object, exposing the servant.
*/
public Object this_object(Servant a_servant)
{
same(a_servant);
try
{
return poa.aom.get(poa.m_orb.currents.get_object_id()).object;
}
catch (NoContext ex)
{
return object;
}
}
示例7: object_id
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
/**
* Get the Id of the object being currently served.
*/
public byte[] object_id(Servant a_servant)
{
same(a_servant);
try
{
byte[] id = poa.m_orb.currents.get_object_id();
return id;
}
catch (NoContext ex)
{
return object.Id;
}
}
示例8: poa
import org.omg.PortableServer.CurrentPackage.NoContext; //导入依赖的package包/类
/**
* Return the associated POA.
*/
public POA poa(Servant a_servant)
{
same(a_servant);
try
{
return poa.m_orb.currents.get_POA();
}
catch (NoContext ex)
{
return poa;
}
}