@Override
	public void createPartControl(Composite composite) {
		composite.setLayout(new GridLayout(10, false));

		Label label_1 = new Label(composite, SWT.NONE);
		label_1.setText("自定义号段");
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);

		text_1 = new Text(composite, SWT.BORDER | SWT.V_SCROLL);
		GridData gd_text_1 = new GridData(SWT.FILL, SWT.CENTER, true, false, 10, 1);
		gd_text_1.heightHint = 100;
		text_1.setLayoutData(gd_text_1);

		Composite composite_2 = new Composite(composite, SWT.NONE);
		composite_2.setLayout(new GridLayout(4, false));
		composite_2.setLayoutData(new GridData(SWT.RIGHT, SWT.CENTER, false, false, 10, 1));

		final Button button = new Button(composite_2, SWT.NONE);
		button.addSelectionListener(new SelectionAdapter() {
			@Override
			public void widgetSelected(SelectionEvent e) {
				final String interval = text_1.getText();
				if (interval == null || interval.equals("")) {
					styledText.append("请添加号码段\n");
					return;
				} else {
					service.addinterval(interval);
					styledText.append("添加号码段成功\n");
				}
			}
		});
		button.setText("添加");

		Button button_3 = new Button(composite_2, SWT.NONE);
		button_3.addSelectionListener(new SelectionAdapter() {
			@Override
			public void widgetSelected(SelectionEvent e) {
				service.stop();
				styledText.append("任务已清理\n");
			}
		});
		button_3.setText("清空");

		startBut = new Button(composite_2, SWT.NONE);
		startBut.addSelectionListener(new SelectionAdapter() {
			@Override
			public void widgetSelected(SelectionEvent e) {
				Thread t = new Thread(new Runnable() {

					@Override
					public void run() {
						try {
							Display.getDefault().syncExec(new Runnable() {

								@Override
								public void run() {
									styledText.setText("");
								}

							});
							service.start(styledText, "。", startBut);
						} catch (IOException e) {
							logger.error("", e);
						}

					}

				});
				t.start();
				startBut.setEnabled(false);
			}
		});
		startBut.setText("开始");

		Button button_2 = new Button(composite_2, SWT.NONE);
		button_2.addSelectionListener(new SelectionAdapter() {
			@Override
			public void widgetSelected(SelectionEvent e) {
				service.stop();
				startBut.setEnabled(true);
				styledText.append("任务停止成功\n");
			}
		});
		button_2.setText("停止");

		Label label_2 = new Label(composite, SWT.NONE);
		label_2.setText("输出");
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);
		new Label(composite, SWT.NONE);

		styledText = new StyledText(composite, SWT.BORDER | SWT.V_SCROLL);
		styledText.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 10, 1));

		Composite composite_1 = new Composite(composite, SWT.NONE);
		composite_1.setLayout(new GridLayout(2, false));
		composite_1.setLayoutData(new GridData(SWT.RIGHT, SWT.CENTER, false, false, 10, 1));

		Button btnNewButton = new Button(composite_1, SWT.NONE);
		btnNewButton.addSelectionListener(new SelectionAdapter() {
			@Override
			public void widgetSelected(SelectionEvent e) {
			}
		});
		btnNewButton.setText("导出成功");

		Button btnshibai = new Button(composite_1, SWT.NONE);
		btnshibai.addSelectionListener(new SelectionAdapter() {
			@Override
			public void widgetSelected(SelectionEvent e) {
				FileDialog fileDialog = new FileDialog(getSite().getShell(), SWT.SAVE);
				String file = fileDialog.open();
				try {
					FileUtils.writePhones(service.getFailed(), file);
				} catch (IOException e1) {
					logger.error("", e1);
				}
			}
		});
		btnshibai.setText("导出失败");
		// TODO Auto-generated method stub

	}