Skip to content

Commit

Permalink
Modify code layout.
Browse files Browse the repository at this point in the history
  • Loading branch information
gfinocchiaro committed Sep 19, 2017
1 parent d7a4aec commit 65af264
Showing 1 changed file with 47 additions and 47 deletions.
94 changes: 47 additions & 47 deletions src/main/java/cool/mqtt/hooks/MqttMessage.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,56 +7,56 @@
*/
public interface MqttMessage {

/**
* Gets the name of the topic to which this message is being published.
*
* @return the topic name
*/
String getTopicName();
/**
* Gets the name of the topic to which this message is being published.
*
* @return the topic name
*/
String getTopicName();

/**
* Gets the <i>Application Message</i> carried by this message.
* <p>
* The MQTT Protocol Specifications defines the Application Message as the
* payload of the <code>PUBLISH</code> Control Packet.
*
* @return the byte array containing the <i>Application Message</i> info
*/
byte[] getApplicationMessage();
/**
* Gets the <i>Application Message</i> carried by this message.
* <p>
* The MQTT Protocol Specifications defines the Application Message as the
* payload of the <code>PUBLISH</code> Control Packet.
*
* @return the byte array containing the <i>Application Message</i> info
*/
byte[] getApplicationMessage();

/**
* Gets the Quality of Service level with which this message has been
* delivered.
*
* @return the Quality of Service level
*/
QoS getQos();
/**
* Gets the Quality of Service level with which this message has been
* delivered.
*
* @return the Quality of Service level
*/
QoS getQos();

/**
* Gets the <i>retained</i> flag of this message.
* <p>
* The retain flag specifies whether the MQTT broker must store this
* message, in order to be immediately delivered to future clients as they
* subscribe to matching topics.
*
* @return {@code true} if the <i>retained</i> flag is set, {@code false}
* otherwise
*/
boolean isRetained();
/**
* Gets the <i>retained</i> flag of this message.
* <p>
* The retain flag specifies whether the MQTT broker must store this
* message, in order to be immediately delivered to future clients as they
* subscribe to matching topics.
*
* @return {@code true} if the <i>retained</i> flag is set, {@code false}
* otherwise
*/
boolean isRetained();

/**
* Gets the <i>duplicate</i> flag of this message.
* <p>
* Only for messages with {@code QoS level > 0}, the duplicate flag
* indicates that this message might have been re-sent because not
* acknowledged in an earlier attempt.
* <p>
* In case of {@link QoS#AT_MOST_ONCE} level, this method always returns
* {@code false}.
*
* @return {@code true} if the <i>duplicate</i> flag is set, {@code false}
* otherwise
*/
boolean isDuplicate();
/**
* Gets the <i>duplicate</i> flag of this message.
* <p>
* Only for messages with {@code QoS level > 0}, the duplicate flag
* indicates that this message might have been re-sent because not
* acknowledged in an earlier attempt.
* <p>
* In case of {@link QoS#AT_MOST_ONCE} level, this method always returns
* {@code false}.
*
* @return {@code true} if the <i>duplicate</i> flag is set, {@code false}
* otherwise
*/
boolean isDuplicate();

}

0 comments on commit 65af264

Please sign in to comment.