*
* @exception AdminException If an error is raised by the administration operation.
* @exception ConnectException If the admin connection is not established.
*/
public Subscription[] getSubscriptions() throws AdminException, ConnectException {
GetSubscriptionsRep reply = (GetSubscriptionsRep) doRequest(new GetSubscriptions(proxyId));
String[] subNames = reply.getSubNames();
String[] topicIds = reply.getTopicIds();
int[] messageCounts = reply.getMessageCounts();
boolean[] durable = reply.getDurable();
Subscription[] res = new Subscription[subNames.length];
for (int i = 0; i < res.length; i++) {
res[i] = new Subscription(subNames[i], topicIds[i], messageCounts[i], durable[i]);
}