Class MessagesImpl
- java.lang.Object
-
- com.fifa.connectservicebus.sdk.api.implementation.MessagesImpl
-
-
Constructor Summary
Constructors Constructor Description MessagesImpl(retrofit2.Retrofit retrofit, FIFAConnectServiceBusV3Impl client)Initializes an instance of Messages.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectdeleteByRequest(String messageId, String lockToken)Deletes a previously locked message (see PeekLock method).rx.Observable<Object>deleteByRequestAsync(String messageId, String lockToken)Deletes a previously locked message (see PeekLock method).com.microsoft.rest.ServiceFuture<Object>deleteByRequestAsync(String messageId, String lockToken, com.microsoft.rest.ServiceCallback<Object> serviceCallback)Deletes a previously locked message (see PeekLock method).rx.Observable<com.microsoft.rest.ServiceResponse<Object>>deleteByRequestWithServiceResponseAsync(String messageId, String lockToken)Deletes a previously locked message (see PeekLock method).ObjectpeekLockByRequest()Gets and locks a message without deleting it from the queue.ObjectpeekLockByRequest(Integer timeout)Gets and locks a message without deleting it from the queue.rx.Observable<Object>peekLockByRequestAsync()Gets and locks a message without deleting it from the queue.com.microsoft.rest.ServiceFuture<Object>peekLockByRequestAsync(com.microsoft.rest.ServiceCallback<Object> serviceCallback)Gets and locks a message without deleting it from the queue.rx.Observable<Object>peekLockByRequestAsync(Integer timeout)Gets and locks a message without deleting it from the queue.com.microsoft.rest.ServiceFuture<Object>peekLockByRequestAsync(Integer timeout, com.microsoft.rest.ServiceCallback<Object> serviceCallback)Gets and locks a message without deleting it from the queue.rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessagePeekLockByRequestHeaders>>peekLockByRequestWithServiceResponseAsync()Gets and locks a message without deleting it from the queue.rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessagePeekLockByRequestHeaders>>peekLockByRequestWithServiceResponseAsync(Integer timeout)Gets and locks a message without deleting it from the queue.ObjectreceiveByRequest()Gets a message from the Message Bus.ObjectreceiveByRequest(Integer timeout)Gets a message from the Message Bus.rx.Observable<Object>receiveByRequestAsync()Gets a message from the Message Bus.com.microsoft.rest.ServiceFuture<Object>receiveByRequestAsync(com.microsoft.rest.ServiceCallback<Object> serviceCallback)Gets a message from the Message Bus.rx.Observable<Object>receiveByRequestAsync(Integer timeout)Gets a message from the Message Bus.com.microsoft.rest.ServiceFuture<Object>receiveByRequestAsync(Integer timeout, com.microsoft.rest.ServiceCallback<Object> serviceCallback)Gets a message from the Message Bus.rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessageReceiveByRequestHeaders>>receiveByRequestWithServiceResponseAsync()Gets a message from the Message Bus.rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessageReceiveByRequestHeaders>>receiveByRequestWithServiceResponseAsync(Integer timeout)Gets a message from the Message Bus.ObjectsendByRecipientAndActionAndProperties(String recipient, byte[] body)Sends a message to a specified recipient via Message Bus.ObjectsendByRecipientAndActionAndProperties(String recipient, byte[] body, String xAction, String xProperties)Sends a message to a specified recipient via Message Bus.rx.Observable<Object>sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body)Sends a message to a specified recipient via Message Bus.com.microsoft.rest.ServiceFuture<Object>sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body, com.microsoft.rest.ServiceCallback<Object> serviceCallback)Sends a message to a specified recipient via Message Bus.rx.Observable<Object>sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body, String xAction, String xProperties)Sends a message to a specified recipient via Message Bus.com.microsoft.rest.ServiceFuture<Object>sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body, String xAction, String xProperties, com.microsoft.rest.ServiceCallback<Object> serviceCallback)Sends a message to a specified recipient via Message Bus.rx.Observable<com.microsoft.rest.ServiceResponse<Object>>sendByRecipientAndActionAndPropertiesWithServiceResponseAsync(String recipient, byte[] body)Sends a message to a specified recipient via Message Bus.rx.Observable<com.microsoft.rest.ServiceResponse<Object>>sendByRecipientAndActionAndPropertiesWithServiceResponseAsync(String recipient, byte[] body, String xAction, String xProperties)Sends a message to a specified recipient via Message Bus.ObjectunlockByRequest(String messageId, String lockToken)Unlocks a previously locked message.rx.Observable<Object>unlockByRequestAsync(String messageId, String lockToken)Unlocks a previously locked message.com.microsoft.rest.ServiceFuture<Object>unlockByRequestAsync(String messageId, String lockToken, com.microsoft.rest.ServiceCallback<Object> serviceCallback)Unlocks a previously locked message.rx.Observable<com.microsoft.rest.ServiceResponse<Object>>unlockByRequestWithServiceResponseAsync(String messageId, String lockToken)Unlocks a previously locked message.
-
-
-
Constructor Detail
-
MessagesImpl
public MessagesImpl(retrofit2.Retrofit retrofit, FIFAConnectServiceBusV3Impl client)Initializes an instance of Messages.- Parameters:
retrofit- the Retrofit instance built from a Retrofit Builder.client- the instance of the service client containing this operation class.
-
-
Method Detail
-
sendByRecipientAndActionAndProperties
public Object sendByRecipientAndActionAndProperties(String recipient, byte[] body)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message body- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
sendByRecipientAndActionAndPropertiesAsync
public com.microsoft.rest.ServiceFuture<Object> sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body, com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesAsyncin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message bodyserviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
sendByRecipientAndActionAndPropertiesAsync
public rx.Observable<Object> sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesAsyncin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message body- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
sendByRecipientAndActionAndPropertiesWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponse<Object>> sendByRecipientAndActionAndPropertiesWithServiceResponseAsync(String recipient, byte[] body)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesWithServiceResponseAsyncin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message body- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
sendByRecipientAndActionAndProperties
public Object sendByRecipientAndActionAndProperties(String recipient, byte[] body, String xAction, String xProperties)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message bodyxAction- Name of the action represented by the message. Optional parameterxProperties- Unencrypted properties of the message. Optional parameter- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
sendByRecipientAndActionAndPropertiesAsync
public com.microsoft.rest.ServiceFuture<Object> sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body, String xAction, String xProperties, com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesAsyncin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message bodyxAction- Name of the action represented by the message. Optional parameterxProperties- Unencrypted properties of the message. Optional parameterserviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
sendByRecipientAndActionAndPropertiesAsync
public rx.Observable<Object> sendByRecipientAndActionAndPropertiesAsync(String recipient, byte[] body, String xAction, String xProperties)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesAsyncin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message bodyxAction- Name of the action represented by the message. Optional parameterxProperties- Unencrypted properties of the message. Optional parameter- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
sendByRecipientAndActionAndPropertiesWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponse<Object>> sendByRecipientAndActionAndPropertiesWithServiceResponseAsync(String recipient, byte[] body, String xAction, String xProperties)
Sends a message to a specified recipient via Message Bus.- Specified by:
sendByRecipientAndActionAndPropertiesWithServiceResponseAsyncin interfaceMessages- Parameters:
recipient- Recipient, usually MA to receive the message.body- Message bodyxAction- Name of the action represented by the message. Optional parameterxProperties- Unencrypted properties of the message. Optional parameter- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
receiveByRequest
public Object receiveByRequest()
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestin interfaceMessages- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
receiveByRequestAsync
public com.microsoft.rest.ServiceFuture<Object> receiveByRequestAsync(com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestAsyncin interfaceMessages- Parameters:
serviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
receiveByRequestAsync
public rx.Observable<Object> receiveByRequestAsync()
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestAsyncin interfaceMessages- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
receiveByRequestWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessageReceiveByRequestHeaders>> receiveByRequestWithServiceResponseAsync()
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestWithServiceResponseAsyncin interfaceMessages- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
receiveByRequest
public Object receiveByRequest(Integer timeout)
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
receiveByRequestAsync
public com.microsoft.rest.ServiceFuture<Object> receiveByRequestAsync(Integer timeout, com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestAsyncin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.serviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
receiveByRequestAsync
public rx.Observable<Object> receiveByRequestAsync(Integer timeout)
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestAsyncin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
receiveByRequestWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessageReceiveByRequestHeaders>> receiveByRequestWithServiceResponseAsync(Integer timeout)
Gets a message from the Message Bus. Message is deleted from the queue.- Specified by:
receiveByRequestWithServiceResponseAsyncin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
peekLockByRequest
public Object peekLockByRequest()
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestin interfaceMessages- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
peekLockByRequestAsync
public com.microsoft.rest.ServiceFuture<Object> peekLockByRequestAsync(com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestAsyncin interfaceMessages- Parameters:
serviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
peekLockByRequestAsync
public rx.Observable<Object> peekLockByRequestAsync()
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestAsyncin interfaceMessages- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
peekLockByRequestWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessagePeekLockByRequestHeaders>> peekLockByRequestWithServiceResponseAsync()
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestWithServiceResponseAsyncin interfaceMessages- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
peekLockByRequest
public Object peekLockByRequest(Integer timeout)
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
peekLockByRequestAsync
public com.microsoft.rest.ServiceFuture<Object> peekLockByRequestAsync(Integer timeout, com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestAsyncin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.serviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
peekLockByRequestAsync
public rx.Observable<Object> peekLockByRequestAsync(Integer timeout)
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestAsyncin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
peekLockByRequestWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponseWithHeaders<Object,MessagePeekLockByRequestHeaders>> peekLockByRequestWithServiceResponseAsync(Integer timeout)
Gets and locks a message without deleting it from the queue. If message is not deleted within configured time it's automatically unlocked and visible for other recipients.- Specified by:
peekLockByRequestWithServiceResponseAsyncin interfaceMessages- Parameters:
timeout- The system will wait N number of seconds before returning "no messages available" message.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
deleteByRequest
public Object deleteByRequest(String messageId, String lockToken)
Deletes a previously locked message (see PeekLock method).- Specified by:
deleteByRequestin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
deleteByRequestAsync
public com.microsoft.rest.ServiceFuture<Object> deleteByRequestAsync(String messageId, String lockToken, com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Deletes a previously locked message (see PeekLock method).- Specified by:
deleteByRequestAsyncin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.serviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
deleteByRequestAsync
public rx.Observable<Object> deleteByRequestAsync(String messageId, String lockToken)
Deletes a previously locked message (see PeekLock method).- Specified by:
deleteByRequestAsyncin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
deleteByRequestWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponse<Object>> deleteByRequestWithServiceResponseAsync(String messageId, String lockToken)
Deletes a previously locked message (see PeekLock method).- Specified by:
deleteByRequestWithServiceResponseAsyncin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
unlockByRequest
public Object unlockByRequest(String messageId, String lockToken)
Unlocks a previously locked message. The message is returned to the queue and can be fetched using PeekLock method.- Specified by:
unlockByRequestin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.- Returns:
- the Object object if successful.
- Throws:
IllegalArgumentException- thrown if parameters fail the validationcom.microsoft.rest.RestException- thrown if the request is rejected by serverRuntimeException- all other wrapped checked exceptions if the request fails to be sent
-
unlockByRequestAsync
public com.microsoft.rest.ServiceFuture<Object> unlockByRequestAsync(String messageId, String lockToken, com.microsoft.rest.ServiceCallback<Object> serviceCallback)
Unlocks a previously locked message. The message is returned to the queue and can be fetched using PeekLock method.- Specified by:
unlockByRequestAsyncin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.serviceCallback- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFutureobject - Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
unlockByRequestAsync
public rx.Observable<Object> unlockByRequestAsync(String messageId, String lockToken)
Unlocks a previously locked message. The message is returned to the queue and can be fetched using PeekLock method.- Specified by:
unlockByRequestAsyncin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
unlockByRequestWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponse<Object>> unlockByRequestWithServiceResponseAsync(String messageId, String lockToken)
Unlocks a previously locked message. The message is returned to the queue and can be fetched using PeekLock method.- Specified by:
unlockByRequestWithServiceResponseAsyncin interfaceMessages- Parameters:
messageId- Message identifier returned by a previously called "peeklock" method.lockToken- Lock token, returned by a previously called "peeklock" method.- Returns:
- the observable to the Object object
- Throws:
IllegalArgumentException- thrown if parameters fail the validation
-
-