Android Open Source - Emoji-ChatRoom My Socket






From Project

Back to project page Emoji-ChatRoom.

License

The source code is released under:

Apache License

If you think the Android project Emoji-ChatRoom listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

/* Copyright 2014 RobustNet Lab, University of Michigan. All Rights Reserved.
 */*from  ww w . j ava 2s. c  o  m*/
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.emojicharroom.util;

import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.IOException;
import java.net.Socket;

/**
 * @author Hongyi Yao (hyyao@umich.edu)
 *
 */
public class MySocket {
  public Socket socket;
  public DataInputStream reader;
  public DataOutputStream writer;
  
  public void init(Socket socket) throws IOException {
    this.socket = socket;
    this.reader = new DataInputStream(socket.getInputStream());
    this.writer = new DataOutputStream(socket.getOutputStream());
  }
}




Java Source Code List

com.emojicharroom.util.Config.java
com.emojicharroom.util.DatabaseHelper.java
com.emojicharroom.util.EmojiFreq.java
com.emojicharroom.util.Logger.java
com.emojicharroom.util.MySocket.java
com.emojicharroom.util.package-info.java
com.emojichatroom.ChatRoom.java
com.emojichatroom.NetworkConsole.java