// Decompiled by Jad v1.5.7g. Copyright 2000 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/SiliconValley/Bridge/8617/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi
// Source File Name: EnterInfo.java
package com.baustem.stbra;
import com.baustem.security.SecurityException;
import com.baustem.security.cert.*;
import java.awt.*;
import java.awt.event.*;
import java.io.*;
import java.security.cert.X509Certificate;
import java.text.DateFormat;
import javax.swing.*;
import javax.swing.border.TitledBorder;
import javax.swing.text.JTextComponent;
// Referenced classes of package com.baustem.stbra:
// WizardWithCardPanel, WizardPanel, CerOnly
public class EnterInfo extends WizardWithCardPanel
{
class FieldHandler
implements ActionListener
{
public void actionPerformed(ActionEvent event)
{
try
{
if(event.getActionCommand().trim() != null)
{
stbNumber = Integer.parseInt(event.getActionCommand());
if(stbNumber <= 0)
throw new Exception();
}
}
catch(Exception e)
{
JOptionPane.showMessageDialog(null, "请输入STB数量,或者您输入的不是数字。", "错误提示", 0);
}
}
FieldHandler()
{
}
}
private JPanel enterPanel;
private JPanel rootContentPanel;
private String stbName;
private String stbOUI;
private String stbType;
private String cerList[];
private String surname;
private int index;
private int stbNumber;
private JTextField textStbName;
private JTextField textStbOUI;
private JTextField textStbType;
private JTextField textStbNumber;
private JComboBox certList;
private JLabel lblCountry;
private JLabel lblState;
private JLabel lblLocality;
private JLabel lblOrganization;
private JLabel lblOrgUnit;
private JLabel lblCommonName;
private JLabel lblSurname;
private JLabel lblVersion;
private JLabel lblValidity;
private JLabel lab1;
private JLabel lab2;
private JLabel lab3;
private JLabel lab4;
private JLabel lab5;
private JLabel lab6;
private JLabel lab7;
private JLabel lab8;
private JLabel lab9;
private boolean selected;
private X509Certificate x509RootCert;
private PKCS pkcs;
FieldHandler handler;
public EnterInfo(boolean useCard)
{
super(useCard);
enterPanel = null;
rootContentPanel = null;
stbName = null;
stbOUI = null;
stbType = null;
surname = null;
stbNumber = -1;
textStbName = null;
textStbOUI = null;
textStbType = null;
textStbNumber = null;
certList = null;
lblCountry = null;
lblState = null;
lblLocality = null;
lblOrganization = null;
lblOrgUnit = null;
lblCommonName = null;
lblSurname = null;
lblVersion = null;
lblValidity = null;
lab1 = null;
lab2 = null;
lab3 = null;
lab4 = null;
lab5 = null;
lab6 = null;
lab7 = null;
lab8 = null;
lab9 = null;
selected = false;
x509RootCert = null;
pkcs = null;
handler = new FieldHandler();
initialize();
}
public void process()
{
}
public void initCardType()
{
}
public void cardInserted()
{
}
public void cardRemoved()
{
}
private void initialize()
{
setHint("请输入厂商信息并选择根证书。");
setName("输入厂商信息");
getTitledBorder().setTitle("");
getCenterPanel().add("North", getEnterPanel());
getCenterPanel().add("Center", getRootContentPanel());
}
public String getStbName()
{
stbName = textStbName.getText();
if(stbName != null)
stbName = stbName.trim();
return stbName;
}
public String getStbOUI()
{
stbOUI = textStbOUI.getText();
if(stbOUI != null)
stbOUI = stbOUI.trim();
return stbOUI;
}
public String getStbType()
{
stbType = textStbType.getText();
if(stbType != null)
stbType = stbType.trim();
return stbType;
}
public int getStbNumber()
{
try
{
if(textStbNumber.getText() != null)
{
stbNumber = Integer.parseInt(textStbNumber.getText());
if(stbNumber <= 0)
stbNumber = -1;
} else
{
stbNumber = -1;
}
}
catch(Exception e)
{
stbNumber = -1;
}
return stbNumber;
}
public String getSurname()
{
try
{
surname = cerList[index];
}
catch(Exception exception) { }
return surname;
}
public boolean getSelected()
{
return selected;
}
public X509Certificate getRootCert()
{
return x509RootCert;
}
private JPanel getEnterPanel()
{
if(enterPanel == null)
{
enterPanel = new JPanel();
enterPanel.setLayout(new GridBagLayout());
GridBagConstraints gbc = new GridBagConstraints();
java.awt.Color epColor = SystemColor.textHighlight;
gbc.insets = new Insets(0, 10, 10, 10);
int y = 0;
gbc.anchor = 13;
gbc.weightx = 0.0D;
gbc.gridwidth = 1;
gbc.gridx = 0;
gbc.gridy = y;
JLabel lnull = new JLabel("", 10);
enterPanel.add(lnull, gbc);
y++;
gbc.anchor = 13;
gbc.weightx = 0.0D;
gbc.gridwidth = 1;
gbc.gridx = 0;
gbc.gridy = y;
enterPanel.add(new JLabel("厂商名称", 10), gbc);
gbc.anchor = 17;
gbc.weightx = 1.0D;
gbc.gridwidth = 3;
gbc.gridx = 1;
gbc.gridy = y;
textStbName = new JTextField(24);
textStbName.setForeground(epColor);
enterPanel.add(textStbName, gbc);
gbc.anchor = 13;
gbc.weightx = 0.0D;
gbc.gridwidth = 1;
gbc.gridx = 4;
gbc.gridy = y;
enterPanel.add(new JLabel("厂商 OUI", 10), gbc);
gbc.anchor = 17;
gbc.weightx = 1.0D;
gbc.gridwidth = 3;
gbc.gridx = 5;
gbc.gridy = y;
textStbOUI = new JTextField(24);
textStbOUI.setForeground(epColor);
enterPanel.add(textStbOUI, gbc);
y++;
gbc.anchor = 13;
gbc.weightx = 0.0D;
gbc.gridwidth = 1;
gbc.gridx = 0;
gbc.gridy = y;
enterPanel.add(new JLabel("STB 类型", 10), gbc);
gbc.anchor = 17;
gbc.weightx = 1.0D;
gbc.gridwidth = 3;
gbc.gridx = 1;
gbc.gridy = y;
textStbType = new JTextField(24);
textStbType.setForeground(epColor);
enterPanel.add(textStbType, gbc);
gbc.anchor = 13;
gbc.weightx = 0.0D;
gbc.gridwidth = 1;
gbc.gridx = 4;
gbc.gridy = y;
enterPanel.add(new JLabel("STB 数量", 10), gbc);
gbc.anchor = 17;
gbc.weightx = 1.0D;
gbc.gridwidth = 3;
gbc.gridx = 5;
gbc.gridy = y;
textStbNumber = new
没有合适的资源?快使用搜索试试~ 我知道了~
java swing 图形界面实例
共198个文件
gif:70个
class:33个
jar:32个
需积分: 10 59 下载量 107 浏览量
2008-11-28
11:59:46
上传
评论
收藏 5.52MB RAR 举报
温馨提示
比较全面的swing应用,各种基本的swing包中类的应用,如:jbutton,jmenu,jmenubar,jmenuitem等!!
资源推荐
资源详情
资源评论
收起资源包目录
java swing 图形界面实例 (198个子文件)
EnterInfo.class 13KB
ApplyCertPanel.class 10KB
ImportRootCertPanel.class 9KB
Main.class 8KB
WizardDialog.class 7KB
WizardWithCardPanel.class 5KB
ApplyCertWizard.class 5KB
JavaCardType.class 3KB
ApplyInfo.class 3KB
JCSignatary.class 3KB
ApplyCertWizard$2.class 3KB
WizardPanel.class 3KB
Config.class 2KB
ImportRootCertWizard.class 2KB
ApplyCertWizard$1.class 2KB
EnterInfo$1.class 2KB
ImportRootCertWizard$1.class 2KB
JCManager.class 2KB
ApplyCertWizard$EnterException.class 2KB
ImagePanel.class 1KB
EnterInfo$FieldHandler.class 1KB
Main$ImportAction.class 1KB
Main$IssueAction.class 1KB
Main$AboutAction.class 1KB
Main$ExitAction.class 1KB
CerOnly.class 1KB
Dialog.class 1KB
Shape.class 884B
WizardDialog$1.class 729B
WizardDialog$2.class 725B
WizardDialog$4.class 721B
WizardDialog$3.class 717B
Main$1.class 486B
.classpath 2KB
.classpath 2KB
Thumbs.db 49KB
Ocfpcsc1.dll 41KB
Ocfpcsc1.dll 41KB
BackGround.gif 5KB
BackGround.gif 5KB
javadev_obj.gif 2KB
javadev_obj.gif 2KB
teamsup_obj.gif 2KB
teamsup_obj.gif 2KB
new_obj.gif 2KB
new_obj.gif 2KB
cer.gif 1KB
cer.gif 1KB
wiz-action-small.gif 1KB
wiz-action-small.gif 1KB
int_default_obj.gif 595B
int_default_obj.gif 595B
int_obj.gif 574B
int_obj.gif 574B
site_xml_obj.gif 570B
site_xml_obj.gif 570B
nav_required.gif 549B
nav_required.gif 549B
lrun_obj.gif 379B
lrun_obj.gif 379B
welcome_item.gif 376B
welcome_item.gif 376B
types.gif 364B
types.gif 364B
synch_synch.gif 353B
synch_synch.gif 353B
delete_obj.gif 351B
delete_obj.gif 351B
nav_class.gif 347B
nav_class.gif 347B
bundle_obj.gif 335B
bundle_obj.gif 335B
SelectNextBottomUnmappedObject.gif 333B
SelectNextTopUnmappedObject.gif 333B
fatalerror_obj.gif 333B
SelectNextBottomUnmappedObject.gif 333B
SelectNextTopUnmappedObject.gif 333B
fatalerror_obj.gif 333B
SelectNextUseObject.gif 332B
SelectNextUseObject.gif 332B
plugins.gif 328B
plugins.gif 328B
e_back.gif 327B
e_forward.gif 327B
e_back.gif 327B
e_forward.gif 327B
memory_view.gif 325B
memory_view.gif 325B
SelectPreviousBottomUnmappedObject.gif 322B
SelectPreviousBottomUnmappedObject.gif 322B
play.gif 318B
play.gif 318B
bundled_obj.gif 227B
bundled_obj.gif 227B
delete_edit.gif 221B
delete_edit.gif 221B
plugin_dis_obj.gif 211B
plugin_dis_obj.gif 211B
jaune_transparent.gif 198B
jaune_transparent.gif 198B
共 198 条
- 1
- 2
资源评论
n_andy
- 粉丝: 3
- 资源: 1
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功