congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
QoS.values
Code IndexAdd Tabnine to your IDE (free)

How to use
values
method
in
org.fusesource.mqtt.client.QoS

Best Java code snippets using org.fusesource.mqtt.client.QoS.values (Showing top 17 results out of 315)

origin: fusesource/mqtt-client

protected QoS qos() {
  return QoS.values()[((header & 0x06) >>> 1)];
}
protected HeaderBase qos(QoS qos) {
origin: fusesource/mqtt-client

public QoS willQos() {
  return QoS.values()[willQos];
}
origin: fusesource/mqtt-client

public SUBSCRIBE decode(MQTTFrame frame) throws ProtocolException {
  assert(frame.buffers.length == 1);
  header(frame.header());
  DataByteArrayInputStream is = new DataByteArrayInputStream(frame.buffers[0]);
  QoS qos = qos();
  if(qos != QoS.AT_MOST_ONCE) {
    messageId = is.readShort();
  }
  ArrayList<Topic> list = new ArrayList<Topic>();
  while(is.available() > 0) {
    Topic topic = new Topic(MessageSupport.readUTF(is), QoS.values()[is.readByte()]);
    list.add(topic);
  }
  topics = list.toArray(new Topic[list.size()]);
  return this;
}

origin: fusesource/mqtt-client

} else if ("--will-qos".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  main.mqtt.setWillQos(QoS.values()[v]);
} else if ("--will-retain".equals(arg)) {
  main.mqtt.setWillRetain(true);
} else if ("-q".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  qos = QoS.values()[v]; 
} else if ("-t".equals(arg)) {
  main.topics.add(new Topic(shift(argl), qos));
origin: fusesource/mqtt-client

} else if ("--will-qos".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  main.mqtt.setWillQos(QoS.values()[v]);
} else if ("--will-retain".equals(arg)) {
  main.mqtt.setWillRetain(true);
} else if ("-q".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  main.qos = QoS.values()[v];
} else if ("-r".equals(arg)) {
  main.retain = true;
origin: org.fusesource.mqtt-client/mqtt-client

protected QoS qos() {
  return QoS.values()[((header & 0x06) >>> 1)];
}
protected HeaderBase qos(QoS qos) {
origin: org.fusesource.mqtt-client/mqtt-client

public QoS willQos() {
  return QoS.values()[willQos];
}
origin: apache/activemq-artemis

@Override
public void publish(String topic, byte[] payload, int qos, boolean retained) throws Exception {
 connection.publish(topic, payload, QoS.values()[qos], retained);
}
origin: org.fusesource.mqtt-client/mqtt-client

public SUBSCRIBE decode(MQTTFrame frame) throws ProtocolException {
  assert(frame.buffers.length == 1);
  header(frame.header());
  DataByteArrayInputStream is = new DataByteArrayInputStream(frame.buffers[0]);
  QoS qos = qos();
  if(qos != QoS.AT_MOST_ONCE) {
    messageId = is.readShort();
  }
  ArrayList<Topic> list = new ArrayList<Topic>();
  while(is.available() > 0) {
    Topic topic = new Topic(MessageSupport.readUTF(is), QoS.values()[is.readByte()]);
    list.add(topic);
  }
  topics = list.toArray(new Topic[list.size()]);
  return this;
}

origin: org.fusesource.mqtt-client/mqtt-client

} else if ("--will-qos".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  main.mqtt.setWillQos(QoS.values()[v]);
} else if ("--will-retain".equals(arg)) {
  main.mqtt.setWillRetain(true);
} else if ("-q".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  main.qos = QoS.values()[v];
} else if ("-r".equals(arg)) {
  main.retain = true;
origin: org.fusesource.mqtt-client/mqtt-client

} else if ("--will-qos".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  main.mqtt.setWillQos(QoS.values()[v]);
} else if ("--will-retain".equals(arg)) {
  main.mqtt.setWillRetain(true);
} else if ("-q".equals(arg)) {
  int v = Integer.parseInt(shift(argl));
  if( v > QoS.values().length ) {
    stderr("Invalid qos value : " + v);
    displayHelpAndExit(1);
  qos = QoS.values()[v]; 
} else if ("-t".equals(arg)) {
  main.topics.add(new Topic(shift(argl), qos));
origin: apache/activemq-artemis

@Override
public void subscribe(String topic, int qos) throws Exception {
 Topic[] topics = {new Topic(utf8(topic), QoS.values()[qos])};
 connection.subscribe(topics);
}
origin: org.apache.activemq/activemq-all

if (message.propertyExists(QOS_PROPERTY_NAME)) {
  int ordinal = message.getIntProperty(QOS_PROPERTY_NAME);
  qoS = QoS.values()[ordinal];
origin: io.fabric8.jube.images.fabric8/fabric8-mq

if (message.propertyExists(QOS_PROPERTY_NAME)) {
  int ordinal = message.getIntProperty(QOS_PROPERTY_NAME);
  qoS = QoS.values()[ordinal];
origin: io.fabric8.ipaas.apps/fabric8mq

if (message.propertyExists(QOS_PROPERTY_NAME)) {
  int ordinal = message.getIntProperty(QOS_PROPERTY_NAME);
  qoS = QoS.values()[ordinal];
origin: org.apache.activemq/activemq-osgi

if (message.propertyExists(QOS_PROPERTY_NAME)) {
  int ordinal = message.getIntProperty(QOS_PROPERTY_NAME);
  qoS = QoS.values()[ordinal];
origin: org.apache.activemq/activemq-mqtt

if (message.propertyExists(QOS_PROPERTY_NAME)) {
  int ordinal = message.getIntProperty(QOS_PROPERTY_NAME);
  qoS = QoS.values()[ordinal];
org.fusesource.mqtt.clientQoSvalues

Popular methods of QoS

  • ordinal
  • compareTo
  • equals
  • valueOf
  • hashCode

Popular in Java

  • Making http post requests using okhttp
  • getApplicationContext (Context)
  • requestLocationUpdates (LocationManager)
  • setScale (BigDecimal)
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • Response (javax.ws.rs.core)
    Defines the contract between a returned instance and the runtime when an application needs to provid
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now