コード例 #1
0
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   ExternalizableUtil.getInstance().writeSerializable(out, (DefaultElement) presence.getElement());
   ExternalizableUtil.getInstance().writeSafeUTF(out, nickname);
   ExternalizableUtil.getInstance().writeInt(out, role);
   ExternalizableUtil.getInstance().writeInt(out, affiliation);
 }
コード例 #2
0
 @Override
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   super.readExternal(in);
   Element packetElement = (Element) ExternalizableUtil.getInstance().readSerializable(in);
   presence = new Presence(packetElement, true);
   nickname = ExternalizableUtil.getInstance().readSafeUTF(in);
   role = ExternalizableUtil.getInstance().readInt(in);
   affiliation = ExternalizableUtil.getInstance().readInt(in);
 }
コード例 #3
0
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   roomParticipation = ExternalizableUtil.getInstance().readBoolean(in);
   if (roomParticipation) {
     participations = new ArrayList<ConversationParticipation>();
   } else {
     participations = new CopyOnWriteArrayList<ConversationParticipation>();
   }
   ExternalizableUtil.getInstance()
       .readExternalizableCollection(in, participations, getClass().getClassLoader());
 }
コード例 #4
0
ファイル: PrivacyList.java プロジェクト: team-lab/openfire
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   userJID = new JID(ExternalizableUtil.getInstance().readSafeUTF(in));
   isDefault = ExternalizableUtil.getInstance().readBoolean(in);
   String xml = ExternalizableUtil.getInstance().readSafeUTF(in);
   try {
     Element element = localParser.get().read(new StringReader(xml)).getRootElement();
     updateList(element, false);
   } catch (Exception e) {
     Log.error("Error while parsing Privacy Property", e);
   }
 }
コード例 #5
0
ファイル: ClientRoute.java プロジェクト: Coselding/Openfire
 @Override
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   byte[] bytes = ExternalizableUtil.getInstance().readByteArray(in);
   // Retrieve the NodeID but try to use the singleton instance
   if (XMPPServer.getInstance().getNodeID().equals(bytes)) {
     nodeID = XMPPServer.getInstance().getNodeID();
   } else {
     nodeID = NodeID.getInstance(bytes);
   }
   available = ExternalizableUtil.getInstance().readBoolean(in);
 }
コード例 #6
0
ファイル: RosterItem.java プロジェクト: team-lab/openfire
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeSafeUTF(out, jid.toString());
   ExternalizableUtil.getInstance().writeBoolean(out, nickname != null);
   if (nickname != null) {
     ExternalizableUtil.getInstance().writeSafeUTF(out, nickname);
   }
   ExternalizableUtil.getInstance().writeStrings(out, groups);
   ExternalizableUtil.getInstance().writeStrings(out, sharedGroups);
   ExternalizableUtil.getInstance().writeStrings(out, invisibleSharedGroups);
   ExternalizableUtil.getInstance().writeInt(out, recvStatus.getValue());
   ExternalizableUtil.getInstance().writeInt(out, subStatus.getValue());
   ExternalizableUtil.getInstance().writeInt(out, askStatus.getValue());
   ExternalizableUtil.getInstance().writeLong(out, rosterID);
 }
コード例 #7
0
ファイル: RosterItem.java プロジェクト: team-lab/openfire
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   jid = new JID(ExternalizableUtil.getInstance().readSafeUTF(in));
   if (ExternalizableUtil.getInstance().readBoolean(in)) {
     nickname = ExternalizableUtil.getInstance().readSafeUTF(in);
   }
   this.groups = new LinkedList<String>();
   ExternalizableUtil.getInstance().readStrings(in, groups);
   ExternalizableUtil.getInstance().readStrings(in, sharedGroups);
   ExternalizableUtil.getInstance().readStrings(in, invisibleSharedGroups);
   recvStatus = RecvType.getTypeFromInt(ExternalizableUtil.getInstance().readInt(in));
   subStatus = SubType.getTypeFromInt(ExternalizableUtil.getInstance().readInt(in));
   askStatus = AskType.getTypeFromInt(ExternalizableUtil.getInstance().readInt(in));
   rosterID = ExternalizableUtil.getInstance().readLong(in);
 }
コード例 #8
0
ファイル: User.java プロジェクト: clin9ame/clin9ame
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   username = ExternalizableUtil.getInstance().readSafeUTF(in);
   name = ExternalizableUtil.getInstance().readSafeUTF(in);
   if (ExternalizableUtil.getInstance().readBoolean(in)) {
     email = ExternalizableUtil.getInstance().readSafeUTF(in);
   }
   creationDate = new Date(ExternalizableUtil.getInstance().readLong(in));
   modificationDate = new Date(ExternalizableUtil.getInstance().readLong(in));
 }
コード例 #9
0
ファイル: User.java プロジェクト: clin9ame/clin9ame
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeSafeUTF(out, username);
   ExternalizableUtil.getInstance().writeSafeUTF(out, getName());
   ExternalizableUtil.getInstance().writeBoolean(out, email != null);
   if (email != null) {
     ExternalizableUtil.getInstance().writeSafeUTF(out, email);
   }
   ExternalizableUtil.getInstance().writeLong(out, creationDate.getTime());
   ExternalizableUtil.getInstance().writeLong(out, modificationDate.getTime());
 }
コード例 #10
0
ファイル: PrivacyList.java プロジェクト: team-lab/openfire
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeSafeUTF(out, userJID.toString());
   ExternalizableUtil.getInstance().writeBoolean(out, isDefault);
   ExternalizableUtil.getInstance().writeSafeUTF(out, asElement().asXML());
 }
コード例 #11
0
ファイル: NodeTask.java プロジェクト: soa4java/JavaChatServer
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   nodeId = ExternalizableUtil.getInstance().readSafeUTF(in);
   serviceId = ExternalizableUtil.getInstance().readSafeUTF(in);
 }
コード例 #12
0
ファイル: MUCRoomTask.java プロジェクト: GeorgeShaw/openFire
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   originator = ExternalizableUtil.getInstance().readBoolean(in);
   roomName = ExternalizableUtil.getInstance().readSafeUTF(in);
   subdomain = ExternalizableUtil.getInstance().readSafeUTF(in);
 }
コード例 #13
0
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   super.readExternal(in);
   address = new JID(ExternalizableUtil.getInstance().readSafeUTF(in));
 }
コード例 #14
0
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   ExternalizableUtil.getInstance().writeSafeUTF(out, address.toString());
 }
コード例 #15
0
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeBoolean(out, roomParticipation);
   ExternalizableUtil.getInstance().writeExternalizableCollection(out, participations);
 }
コード例 #16
0
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeSerializable(out, (DefaultElement) iq.getElement());
 }
コード例 #17
0
 public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
   Element packetElement = (Element) ExternalizableUtil.getInstance().readSerializable(in);
   iq = new IQ(packetElement, true);
 }
コード例 #18
0
ファイル: MUCRoomTask.java プロジェクト: GeorgeShaw/openFire
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeBoolean(out, originator);
   ExternalizableUtil.getInstance().writeSafeUTF(out, roomName);
   ExternalizableUtil.getInstance().writeSafeUTF(out, subdomain);
 }
コード例 #19
0
ファイル: NodeTask.java プロジェクト: soa4java/JavaChatServer
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeSafeUTF(out, nodeId);
   ExternalizableUtil.getInstance().writeSafeUTF(out, serviceId);
 }
コード例 #20
0
ファイル: ClientRoute.java プロジェクト: Coselding/Openfire
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   ExternalizableUtil.getInstance().writeByteArray(out, nodeID.toByteArray());
   ExternalizableUtil.getInstance().writeBoolean(out, available);
 }