⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cmppwriter.java

📁 移动CMPP的网关,JAVA又一实现,非常完整的代码.
💻 JAVA
字号:
/*
 * Created on Mar 17, 2005
 *
 * TODO To change the template for this generated file go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
package com.grail.comm.cmpp;

import java.io.IOException;
import java.io.OutputStream;

import com.grail.comm.cmpp.message.CMPPMessage;
import com.grail.comm.core.PMessage;
import com.grail.comm.core.PWriter;

/**
 * @author eclipse
 *
 * TODO To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
public class CMPPWriter extends PWriter
{

    protected OutputStream out;

    public CMPPWriter(OutputStream out)
    {
        this.out = out;
    }

    public void write(PMessage message)
        throws IOException
    {
        CMPPMessage msg = (CMPPMessage)message;
        out.write(msg.getBytes());
    }

    public void writeHeartbeat()
        throws IOException
    {
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -