mm7send.java
来自「一条彩信引擎代码 外加单元测试代码 单元测试 是我自己 把CPPUNIT去掉了U」· Java 代码 · 共 62 行
JAVA
62 行
package mm7;import java.awt.*;import java.awt.event.*;import javax.swing.*;public class Mm7Send extends JFrame { JPanel contentPane; JButton jButton1 = new JButton(); GridBagLayout gridBagLayout1 = new GridBagLayout(); //Construct the frame public Mm7Send() { enableEvents(AWTEvent.WINDOW_EVENT_MASK); try { jbInit(); } catch(Exception e) { e.printStackTrace(); } } //Component initialization private void jbInit() throws Exception { contentPane = (JPanel) this.getContentPane(); jButton1.setText("测试发送"); jButton1.addActionListener(new Mm7Send_jButton1_actionAdapter(this)); contentPane.setBackground(SystemColor.info); contentPane.setOpaque(true); contentPane.setToolTipText(""); contentPane.setLayout(gridBagLayout1); this.setSize(new Dimension(400, 300)); this.setTitle("mm7Send测试"); contentPane.add(jButton1, new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0 ,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(139, 157, 136, 164), 0, 0)); } //Overridden so we can exit when window is closed protected void processWindowEvent(WindowEvent e) { super.processWindowEvent(e); if (e.getID() == WindowEvent.WINDOW_CLOSING) { System.exit(0); } } void jButton1_actionPerformed(ActionEvent e) { VaspSendTestTemp vtt = new VaspSendTestTemp(); vtt.sendMM7("13400053950","10658535","111000000000000000165"); }}class Mm7Send_jButton1_actionAdapter implements java.awt.event.ActionListener { Mm7Send adaptee; Mm7Send_jButton1_actionAdapter(Mm7Send adaptee) { this.adaptee = adaptee; } public void actionPerformed(ActionEvent e) { adaptee.jButton1_actionPerformed(e); }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?