当前位置: 首页>>代码示例>>Java>>正文


Java ActiveMQBuffer.readString方法代码示例

本文整理汇总了Java中org.apache.activemq.artemis.api.core.ActiveMQBuffer.readString方法的典型用法代码示例。如果您正苦于以下问题:Java ActiveMQBuffer.readString方法的具体用法?Java ActiveMQBuffer.readString怎么用?Java ActiveMQBuffer.readString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.activemq.artemis.api.core.ActiveMQBuffer的用法示例。


在下文中一共展示了ActiveMQBuffer.readString方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   this.nodeID = buffer.readString();
   this.backupGroupName = buffer.readNullableString();
   this.backup = buffer.readBoolean();
   this.currentEventID = buffer.readLong();
   if (buffer.readBoolean()) {
      connector = new TransportConfiguration();
      connector.decode(buffer);
   }
   if (buffer.readBoolean()) {
      backupConnector = new TransportConfiguration();
      backupConnector.decode(buffer);
   }
   scaleDownGroupName = buffer.readNullableString();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:17,代码来源:NodeAnnounceMessage.java

示例2: transform

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public Message transform(final Message messageParameter) {
   ICoreMessage message = messageParameter.toCore();
   SimpleString oldProp = (SimpleString) message.getObjectProperty(new SimpleString("wibble"));

   if (!oldProp.equals(new SimpleString("bing"))) {
      throw new IllegalStateException("Wrong property value!!");
   }

   // Change a property
   message.putStringProperty(new SimpleString("wibble"), new SimpleString("bong"));

   // Change the body
   ActiveMQBuffer buffer = message.getBodyBuffer();

   buffer.readerIndex(0);

   String str = buffer.readString();

   if (!str.equals("doo be doo be doo be doo")) {
      throw new IllegalStateException("Wrong body!!");
   }

   buffer.clear();

   buffer.writeString("dee be dee be dee be dee");

   return message;
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:30,代码来源:SimpleTransformer.java

示例3: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   name = buffer.readString();
   sessionChannelID = buffer.readLong();
   version = buffer.readInt();
   username = buffer.readNullableString();
   password = buffer.readNullableString();
   minLargeMessageSize = buffer.readInt();
   xa = buffer.readBoolean();
   autoCommitSends = buffer.readBoolean();
   autoCommitAcks = buffer.readBoolean();
   windowSize = buffer.readInt();
   preAcknowledge = buffer.readBoolean();
   defaultAddress = buffer.readNullableString();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:16,代码来源:CreateSessionMessage.java

示例4: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   synchronizationIsFinished = buffer.readBoolean();
   allowsAutoFailBack = buffer.readBoolean();
   nodeID = buffer.readString();
   if (synchronizationIsFinished) {
      return;
   }
   dataType = SyncDataType.getDataType(buffer.readByte());
   int length = buffer.readInt();
   ids = new long[length];
   for (int i = 0; i < length; i++) {
      ids[i] = buffer.readLong();
   }
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:16,代码来源:ReplicationStartSyncMessage.java

示例5: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   clusterUser = buffer.readString();
   clusterPassword = buffer.readString();
   backupWantsFailBack = buffer.readBoolean();
   connector = new TransportConfiguration();
   connector.decode(buffer);
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:9,代码来源:BackupRegistrationMessage.java

示例6: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   key = buffer.readString();
   data = buffer.readString();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:6,代码来源:SessionAddMetaDataMessage.java

示例7: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   key = buffer.readString();
   data = buffer.readString();
   requiresConfirmation = buffer.readBoolean();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:7,代码来源:SessionAddMetaDataMessageV2.java

示例8: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   name = buffer.readString();
   lastConfirmedCommandID = buffer.readInt();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:6,代码来源:ReattachSessionMessage.java

示例9: decodeRest

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decodeRest(final ActiveMQBuffer buffer) {
   clusterUser = buffer.readString();
   clusterPassword = buffer.readString();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:6,代码来源:ClusterConnectMessage.java

示例10: decode

import org.apache.activemq.artemis.api.core.ActiveMQBuffer; //导入方法依赖的package包/类
@Override
public void decode(ActiveMQBuffer buff) {
   super.decode(buff);
   nodeId = buff.readString();
}
 
开发者ID:apache,项目名称:activemq-artemis,代码行数:6,代码来源:ServerConnectVote.java


注:本文中的org.apache.activemq.artemis.api.core.ActiveMQBuffer.readString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。