keycloak-federation
公開メンバ関数 | 静的公開メンバ関数 | 関数 | 非公開メンバ関数 | 非公開変数類 | 全メンバ一覧
org.freedesktop.dbus.DBusAsyncReply< ReturnType > クラステンプレート
org.freedesktop.dbus.DBusAsyncReply< ReturnType > 連携図
Collaboration graph

公開メンバ関数

boolean hasReply ()
 
ReturnType getReply () throws DBusExecutionException
 
String toString ()
 

静的公開メンバ関数

static Collection< DBusAsyncReply<? extends Object > > hasReply (Collection< DBusAsyncReply<? extends Object >> replies)
 

関数

 DBusAsyncReply (MethodCall mc, Method me, AbstractConnection conn)
 
Method getMethod ()
 
AbstractConnection getConnection ()
 
MethodCall getCall ()
 

非公開メンバ関数

synchronized void checkReply ()
 

非公開変数類

ReturnType rval = null
 
DBusExecutionException error = null
 
MethodCall mc
 
Method me
 
AbstractConnection conn
 

詳解

A handle to an asynchronous method call.

構築子と解体子

◆ DBusAsyncReply()

org.freedesktop.dbus.DBusAsyncReply< ReturnType >.DBusAsyncReply ( MethodCall  mc,
Method  me,
AbstractConnection  conn 
)
inlinepackage
49  {
50  this.mc = mc;
51  this.me = me;
52  this.conn = conn;
53  }
AbstractConnection conn
Definition: DBusAsyncReply.java:47
Method me
Definition: DBusAsyncReply.java:46
MethodCall mc
Definition: DBusAsyncReply.java:45

関数詳解

◆ checkReply()

synchronized void org.freedesktop.dbus.DBusAsyncReply< ReturnType >.checkReply ( )
inlineprivate
56  {
57  if (mc.hasReply()) {
58  Message m = mc.getReply();
59  if (m instanceof Error)
60  error = ((Error) m).getException();
61  else if (m instanceof MethodReturn) {
62  try {
63  rval = (ReturnType) RemoteInvocationHandler.convertRV(m.getSig(), m.getParameters(), me, conn);
64  } catch (DBusExecutionException DBEe) {
65  error = DBEe;
66  } catch (DBusException DBe) {
67  if (AbstractConnection.EXCEPTION_DEBUG && Debug.debug) Debug.print(Debug.ERR, DBe);
68  error = new DBusExecutionException(DBe.getMessage());
69  }
70  }
71  }
72  }
synchronized boolean hasReply()
Definition: MethodCall.java:93
ReturnType rval
Definition: DBusAsyncReply.java:43
AbstractConnection conn
Definition: DBusAsyncReply.java:47
synchronized Message getReply(long timeout)
Definition: MethodCall.java:103
Method me
Definition: DBusAsyncReply.java:46
MethodCall mc
Definition: DBusAsyncReply.java:45
DBusExecutionException error
Definition: DBusAsyncReply.java:44

◆ getCall()

MethodCall org.freedesktop.dbus.DBusAsyncReply< ReturnType >.getCall ( )
inlinepackage
113  {
114  return mc;
115  }
MethodCall mc
Definition: DBusAsyncReply.java:45

◆ getConnection()

AbstractConnection org.freedesktop.dbus.DBusAsyncReply< ReturnType >.getConnection ( )
inlinepackage
109  {
110  return conn;
111  }
AbstractConnection conn
Definition: DBusAsyncReply.java:47

◆ getMethod()

Method org.freedesktop.dbus.DBusAsyncReply< ReturnType >.getMethod ( )
inlinepackage
105  {
106  return me;
107  }
Method me
Definition: DBusAsyncReply.java:46

◆ getReply()

ReturnType org.freedesktop.dbus.DBusAsyncReply< ReturnType >.getReply ( ) throws DBusExecutionException
inline

Get the reply.

戻り値
The return value from the method.
例外
DBusExecutionExceptionif the reply to the method was an error.
NoReplyif the method hasn't had a reply yet
92  {
93  if (null != rval) return rval;
94  else if (null != error) throw error;
95  checkReply();
96  if (null != rval) return rval;
97  else if (null != error) throw error;
98  else throw new NoReply(getString("asyncCallNoReply"));
99  }
synchronized void checkReply()
Definition: DBusAsyncReply.java:56
ReturnType rval
Definition: DBusAsyncReply.java:43
DBusExecutionException error
Definition: DBusAsyncReply.java:44

◆ hasReply() [1/2]

static Collection<DBusAsyncReply<? extends Object> > org.freedesktop.dbus.DBusAsyncReply< ReturnType >.hasReply ( Collection< DBusAsyncReply<? extends Object >>  replies)
inlinestatic

Check if any of a set of asynchronous calls have had a reply.

引数
repliesA Collection of handles to replies to check.
戻り値
A Collection only containing those calls which have had replies.
35  {
36  Collection<DBusAsyncReply<? extends Object>> c = new ArrayList<DBusAsyncReply<? extends Object>>(replies);
37  Iterator<DBusAsyncReply<? extends Object>> i = c.iterator();
38  while (i.hasNext())
39  if (!i.next().hasReply()) i.remove();
40  return c;
41  }

◆ hasReply() [2/2]

boolean org.freedesktop.dbus.DBusAsyncReply< ReturnType >.hasReply ( )
inline

Check if we've had a reply.

戻り値
True if we have a reply
79  {
80  if (null != rval || null != error) return true;
81  checkReply();
82  return null != rval || null != error;
83  }
synchronized void checkReply()
Definition: DBusAsyncReply.java:56
ReturnType rval
Definition: DBusAsyncReply.java:43
DBusExecutionException error
Definition: DBusAsyncReply.java:44

◆ toString()

String org.freedesktop.dbus.DBusAsyncReply< ReturnType >.toString ( )
inline
101  {
102  return getString("waitingFor") + mc;
103  }
MethodCall mc
Definition: DBusAsyncReply.java:45

メンバ詳解

◆ conn

◆ error

DBusExecutionException org.freedesktop.dbus.DBusAsyncReply< ReturnType >.error = null
private

◆ mc

◆ me

Method org.freedesktop.dbus.DBusAsyncReply< ReturnType >.me
private

◆ rval

ReturnType org.freedesktop.dbus.DBusAsyncReply< ReturnType >.rval = null
private

このクラス詳解は次のファイルから抽出されました: