我想在linux(僅客戶端)中開發STMP/POP3客戶端。我想使用數字證書來加密數據(我會嘗試提供端到端的安全性)。我也想創建一個簡單的界面(帶有文本框,發送按鈕,收件箱等)。我的問題是:我應該在java(如果可能的話)或C/C++(在這種情況下,我必須使用一些工具,例如接口 - > QT)這樣做。你怎麼看? 第二個問題:如果您有任何想法/建議或有用的鏈接(或任何可以幫助我的),我將不勝感激。Linux中的SMTP/POP3客戶端
-1
A
回答
1
關於你的第一個問題
我應該這樣做在Java中(如果可能的話)或C/C++
您可以使用您感到舒適與任何語言,如果你想要我建議我建議你使用java,因爲使用Swing或Javafx創建圖形界面非常簡單,並且有很多庫可以幫助實現你的目標。
而關於你的第二個問題
,如果您有任何意見/建議或有用的鏈接
你可以找到一個有用的教程,指導您從一開始就告訴本網站到底:JavaMail API Tutorial - Tutorialspoint
這裏是一個簡單的應用程序接口以您的項目開始使用JavaFx創建。
Simple Application UI Using JavaFX Desktop Screen-shot
Main.java
package application;
import javafx.application.Application;
import javafx.stage.Stage;
import javafx.scene.Scene;
import javafx.scene.layout.AnchorPane;
import javafx.fxml.FXMLLoader;
public class Main extends Application {
@Override
public void start(Stage primaryStage) {
try {
AnchorPane root = (AnchorPane)FXMLLoader.load(getClass().getResource("Email.fxml"));
Scene scene = new Scene(root,400,400);
scene.getStylesheets().add(getClass().getResource("application.css").toExternalForm());
primaryStage.setScene(scene);
primaryStage.show();
} catch(Exception e) {
e.printStackTrace();
}
}
public static void main(String[] args) {
launch(args);
}
}
EmailController.java
package application;
import java.net.URL;
import java.util.ResourceBundle;
import javafx.fxml.FXML;
import javafx.scene.control.Button;
import javafx.scene.control.PasswordField;
import javafx.scene.control.TextArea;
import javafx.scene.control.TextField;
public class EmailController {
@FXML
private ResourceBundle resources;
@FXML
private URL location;
@FXML
private TextField fromField;
@FXML
private TextField toField;
@FXML
private TextField loginField;
@FXML
private PasswordField passwordField;
@FXML
private TextField subjectField;
@FXML
private TextArea messageField;
@FXML
private Button deleteButton;
@FXML
private Button sendButton;
@FXML
void initialize() {
}
}
Email.fxml
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.PasswordField?>
<?import javafx.scene.control.TextArea?>
<?import javafx.scene.control.TextField?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.ColumnConstraints?>
<?import javafx.scene.layout.GridPane?>
<?import javafx.scene.layout.Pane?>
<?import javafx.scene.layout.RowConstraints?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?>
<fx:root type="AnchorPane" xmlns:fx="http://javafx.com/fxml/1" xmlns="http://javafx.com/javafx/8.0.111" fx:controller="application.EmailController">
<children>
<Pane prefHeight="522.0" prefWidth="761.0">
<children>
<VBox prefHeight="522.0" prefWidth="761.0">
<children>
<GridPane gridLinesVisible="true">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES" maxWidth="328.0" minWidth="10.0" prefWidth="131.0" />
<ColumnConstraints hgrow="SOMETIMES" maxWidth="635.0" minWidth="10.0" prefWidth="630.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
</rowConstraints>
<children>
<Label alignment="CENTER_RIGHT" prefHeight="23.0" prefWidth="136.0" text="From : ">
<font>
<Font name="Segoe UI" size="18.0" />
</font>
</Label>
<TextField fx:id="fromField" GridPane.columnIndex="1" />
<Label alignment="CENTER_RIGHT" prefHeight="17.0" prefWidth="134.0" text="To : " textAlignment="CENTER" GridPane.rowIndex="1">
<font>
<Font name="Segoe UI" size="18.0" />
</font>
</Label>
<Label alignment="CENTER_RIGHT" prefHeight="17.0" prefWidth="134.0" text="Login : " textAlignment="CENTER" GridPane.rowIndex="2">
<font>
<Font name="Segoe UI" size="18.0" />
</font>
</Label>
<TextField fx:id="toField" GridPane.columnIndex="1" GridPane.rowIndex="1" />
<TextField fx:id="loginField" GridPane.columnIndex="1" GridPane.rowIndex="2" />
<Label alignment="CENTER_RIGHT" prefHeight="17.0" prefWidth="134.0" text="Password : " textAlignment="CENTER" GridPane.rowIndex="3">
<font>
<Font name="Segoe UI" size="18.0" />
</font>
</Label>
<PasswordField fx:id="passwordField" GridPane.columnIndex="1" GridPane.rowIndex="3" />
</children>
</GridPane>
<GridPane prefHeight="240.0" prefWidth="681.0">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES" maxWidth="659.0" minWidth="10.0" prefWidth="152.0" />
<ColumnConstraints hgrow="SOMETIMES" maxWidth="722.0" minWidth="10.0" prefWidth="609.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints />
<RowConstraints minHeight="10.0" prefHeight="30.0" />
</rowConstraints>
<children>
<Label alignment="CENTER_RIGHT" prefHeight="23.0" prefWidth="150.0" text="Subject : ">
<font>
<Font name="Segoe UI" size="18.0" />
</font>
</Label>
<TextField fx:id="subjectField" GridPane.columnIndex="1" />
<Label alignment="CENTER_RIGHT" prefHeight="23.0" prefWidth="150.0" text="Message : " GridPane.hgrow="ALWAYS" GridPane.rowIndex="1" GridPane.vgrow="ALWAYS">
<font>
<Font name="Segoe UI" size="18.0" />
</font>
</Label>
<TextArea fx:id="messageField" prefHeight="200.0" prefWidth="200.0" GridPane.columnIndex="1" GridPane.rowIndex="1" GridPane.rowSpan="2">
<GridPane.margin>
<Insets top="10.0" />
</GridPane.margin>
</TextArea>
</children>
<VBox.margin>
<Insets left="30.0" right="30.0" top="20.0" />
</VBox.margin>
</GridPane>
<Pane prefHeight="200.0" prefWidth="200.0">
<children>
<Button fx:id="deleteButton" layoutX="220.0" layoutY="30.0" mnemonicParsing="false" prefHeight="30.0" prefWidth="150.0" text="Delete">
<font>
<Font name="Segoe UI" size="24.0" />
</font>
</Button>
<Button fx:id="sendButton" layoutX="450.0" layoutY="30.0" mnemonicParsing="false" prefHeight="30.0" prefWidth="150.0" text="SEND">
<font>
<Font name="Segoe UI" size="24.0" />
</font>
</Button>
</children>
</Pane>
</children>
</VBox>
</children>
</Pane>
</children>
</fx:root>
相關問題
- 1. Linux Powershell客戶端
- 2. 從Linux客戶端
- 3. Windows客戶端 - 在Linux上
- 4. TCPDF不要Linux客戶端
- 5. Linux UDP客戶端,如何?
- 6. 使用XRDP從LINUX客戶端連接Linux到Windows PC客戶端
- 7. 的XDebug dbgp for Linux客戶端
- 8. Linux的Dropbox客戶端如何工作?
- 9. Linux機器上的TPTP客戶端
- 10. Debian Linux的Visual SVN客戶端
- 11. 客戶端:Linux的Lightwieght通信協議
- 12. MongoDB GUI客戶端(跨平臺或Linux)
- 13. Linux - 系統日誌客戶端
- 14. Linux無盤客戶端nfs吞吐量
- 15. 尋找命令行ftp客戶端(linux)
- 16. Linux控制檯SIP客戶端
- 17. Windows客戶端和Linux(Ubuntu)服務器
- 18. 連接到ravendb linux客戶端?
- 19. WPF客戶端在Linux服務器上
- 20. 客戶端到客戶端的連接?
- 21. 獲取客戶端IP的客戶端
- 22. 帶客戶端的Android客戶端Python
- 23. 使用默認CCSID在Linux中連接到客戶端的Linux中的WebSphere MQ
- 24. 如何在Linux中獲取WCF服務中的客戶端IP?
- 25. Java:服務器/客戶端 - >客戶端/客戶端
- 26. 我想開發一個基本的Linux終端IM客戶端
- 27. IoT Java Device SDK無法解析Linux上的客戶端端點
- 28. 如何禁用客戶端在Linux的CIFS(samba)中的緩存
- 29. 可可中的客戶端到客戶端的消息傳遞?
- 30. Linux用戶可以訪問的git客戶端安裝後...
謝謝您的意見! –