Skip to content

Commit 0f9d468

Browse files
Merge pull request #25 from rockstar777/up-hi
reverse complete
2 parents 1a721fb + 5d2578b commit 0f9d468

9 files changed

+855
-858
lines changed

File_Sharing/Client_Main.java

+17-42
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
21
package file_sharing;
2+
33
import java.io.DataInputStream;
44
import java.io.DataOutputStream;
55
import java.io.File;
@@ -20,27 +20,17 @@
2020
import java.util.logging.Logger;
2121
import java.util.logging.SimpleFormatter;
2222
import javax.swing.JFileChooser;
23-
24-
25-
/**
26-
*
27-
* @author rockstar
28-
*/
29-
30-
31-
class Client {
32-
33-
23+
class Client{
24+
3425
}
26+
3527
public class Client_Main extends javax.swing.JFrame {
3628

37-
public Socket socket = null;
38-
private DataInputStream input = null;
29+
public Socket socket = null;
30+
private DataInputStream input = null;
3931
private DataOutputStream out = null;
40-
public void setupconnection(String ip,int port) {
41-
42-
43-
try
32+
public void setupconnection(String ip,int port){
33+
try
4434
{
4535
this.socket = new Socket(ip, port);
4636
System.out.println("Connection Established!");
@@ -54,24 +44,16 @@ public void setupconnection(String ip,int port) {
5444
{
5545
System.out.println(i);
5646
}
57-
}
58-
59-
60-
61-
62-
63-
47+
}
48+
6449
/**
6550
* Creates new form Client_Main
6651
*/
6752
public Client_Main() {
6853
initComponents();
6954
}
70-
7155
@SuppressWarnings("unchecked")
72-
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
7356
private void initComponents() {
74-
7557
ipaddress = new javax.swing.JTextField();
7658
port_no = new javax.swing.JTextField();
7759
connect = new javax.swing.JButton();
@@ -160,18 +142,16 @@ public void actionPerformed(java.awt.event.ActionEvent evt) {
160142
);
161143

162144
pack();
163-
}// </editor-fold>//GEN-END:initComponents
145+
}
164146

165-
private void connectActionPerformed(java.awt.event.ActionEvent evt) throws IOException {//GEN-FIRST:event_connectActionPerformed
166-
// TODO add your handling code here:
167-
147+
private void connectActionPerformed(java.awt.event.ActionEvent evt) throws IOException {
168148
ip = this.ipaddress.getText();
169149
pn = Integer.parseInt(this.port_no.getText());
170150
user = this.username.getText();
171151
this.setupconnection(ip, pn);
172152
Logger logger = Logger.getLogger("mylog");
173153

174-
FileHandler fileHandler = new FileHandler("E:\\file_sharing\\File_Sharing\\File_appd.log", true);
154+
FileHandler fileHandler = new FileHandler("E:\\file_sharing\\File_Sharing\\Filapplogg.log", true);
175155

176156
if(this.socket!=null && user!=null){
177157

@@ -189,23 +169,20 @@ public void run(){
189169
}
190170

191171

192-
}//GEN-LAST:event_connectActionPerformed
172+
}
193173

194174
private void port_noActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_port_noActionPerformed
195175
// TODO add your handling code here:
196-
}//GEN-LAST:event_port_noActionPerformed
197-
176+
}
198177
private void usernameActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_usernameActionPerformed
199178
// TODO add your handling code here:
200-
}//GEN-LAST:event_usernameActionPerformed
179+
}
201180

202181
private void ipaddressActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_ipaddressActionPerformed
203182
// TODO add your handling code here:
204-
}//GEN-LAST:event_ipaddressActionPerformed
183+
}
205184

206-
207185
public static void main(String args[]) {
208-
209186
try {
210187
for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
211188
if ("Nimbus".equals(info.getName())) {
@@ -232,13 +209,11 @@ public void run() {
232209
private String ip;
233210
private int pn;
234211
private String user;
235-
236212
private javax.swing.JButton connect;
237213
private javax.swing.JTextField ipaddress;
238214
private javax.swing.JLabel jLabel1;
239215
private javax.swing.JLabel jLabel2;
240216
private javax.swing.JLabel jLabel3;
241217
private javax.swing.JTextField port_no;
242218
private javax.swing.JTextField username;
243-
// End of variables declaration//GEN-END:variables
244219
}

File_Sharing/Filapplogg.log

+90
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
Apr 16, 2018 12:27:04 AM file_sharing.User_window Send_fileActionPerformed
2+
INFO: Rabb Da Banda Ahen (1).mp3 16/04/2018 00:27:04 pm send gha
3+
Apr 16, 2018 12:28:37 AM file_sharing.User_window$3 run
4+
INFO: Azhar_ OYE OYE.mp4 16/04/2018 00:28:37 am recieve Dax
5+
Apr 16, 2018 12:28:37 AM file_sharing.User_window$3 run
6+
INFO: Azhar_ OYE OYE.mp4 16/04/2018 00:28:37 am recieve Dax
7+
Apr 16, 2018 12:34:11 AM file_sharing.User_window Send_fileActionPerformed
8+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:11 pm send gha
9+
Apr 16, 2018 12:34:11 AM file_sharing.User_window Send_fileActionPerformed
10+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:11 pm send gha
11+
Apr 16, 2018 12:34:11 AM file_sharing.User_window Send_fileActionPerformed
12+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:11 pm send gha
13+
Apr 16, 2018 12:34:16 AM file_sharing.User_window Send_fileActionPerformed
14+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:16 pm send gha
15+
Apr 16, 2018 12:34:16 AM file_sharing.User_window Send_fileActionPerformed
16+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:16 pm send gha
17+
Apr 16, 2018 12:34:16 AM file_sharing.User_window Send_fileActionPerformed
18+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:16 pm send gha
19+
Apr 16, 2018 12:34:16 AM file_sharing.User_window Send_fileActionPerformed
20+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:16 pm send gha
21+
Apr 16, 2018 12:34:17 AM file_sharing.User_window Send_fileActionPerformed
22+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:17 pm send gha
23+
Apr 16, 2018 12:34:17 AM file_sharing.User_window Send_fileActionPerformed
24+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:17 pm send gha
25+
Apr 16, 2018 12:34:17 AM file_sharing.User_window Send_fileActionPerformed
26+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:17 pm send gha
27+
Apr 16, 2018 12:34:17 AM file_sharing.User_window Send_fileActionPerformed
28+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:17 pm send gha
29+
Apr 16, 2018 12:34:17 AM file_sharing.User_window Send_fileActionPerformed
30+
INFO: - Saavn.com - Listen to Indian Music for free_3.MP3 16/04/2018 00:34:17 pm send gha
31+
Apr 16, 2018 12:45:27 AM file_sharing.User_window$3 run
32+
INFO: 09 - Raabta [Songspk.name] (1).mp3 16/04/2018 00:45:27 am recieve Dax
33+
Apr 16, 2018 12:45:41 AM file_sharing.User_window$3 run
34+
INFO: 09 - Raabta [Songspk.name] (1).mp3 16/04/2018 00:45:41 am recieve Dax
35+
Apr 16, 2018 12:45:41 AM file_sharing.User_window$3 run
36+
INFO: 09 - Raabta [Songspk.name] (1).mp3 16/04/2018 00:45:41 am recieve Dax
37+
Apr 16, 2018 12:45:50 AM file_sharing.User_window$3 run
38+
INFO: 09 - Raabta [Songspk.name] (1).mp3 16/04/2018 00:45:50 am recieve Dax
39+
Apr 16, 2018 12:45:50 AM file_sharing.User_window$3 run
40+
INFO: 09 - Raabta [Songspk.name] (1).mp3 16/04/2018 00:45:50 am recieve Dax
41+
Apr 16, 2018 12:45:50 AM file_sharing.User_window$3 run
42+
INFO: 09 - Raabta [Songspk.name] (1).mp3 16/04/2018 00:45:50 am recieve Dax
43+
Apr 16, 2018 12:50:03 AM file_sharing.User_window Send_fileActionPerformed
44+
INFO: README.md 16/04/2018 00:50:03 pm send Avkatran
45+
Apr 16, 2018 12:50:40 AM file_sharing.User_window$3 run
46+
INFO: 2015020317 (2).pdf 16/04/2018 00:50:40 am recieve Dax
47+
Apr 16, 2018 12:50:40 AM file_sharing.User_window$3 run
48+
INFO: 2015020317 (2).pdf 16/04/2018 00:50:40 am recieve Dax
49+
Apr 16, 2018 12:52:05 AM file_sharing.User_window Send_fileActionPerformed
50+
INFO: package-lock.json 16/04/2018 00:52:05 pm send Avkatran
51+
Apr 16, 2018 12:52:05 AM file_sharing.User_window Send_fileActionPerformed
52+
INFO: package-lock.json 16/04/2018 00:52:05 pm send Avkatran
53+
Apr 16, 2018 12:52:05 AM file_sharing.User_window Send_fileActionPerformed
54+
INFO: package-lock.json 16/04/2018 00:52:05 pm send Avkatran
55+
Apr 16, 2018 12:52:14 AM file_sharing.User_window Send_fileActionPerformed
56+
INFO: package-lock.json 16/04/2018 00:52:14 pm send Avkatran
57+
Apr 16, 2018 12:52:14 AM file_sharing.User_window Send_fileActionPerformed
58+
INFO: package-lock.json 16/04/2018 00:52:14 pm send Avkatran
59+
Apr 16, 2018 12:52:14 AM file_sharing.User_window Send_fileActionPerformed
60+
INFO: package-lock.json 16/04/2018 00:52:14 pm send Avkatran
61+
Apr 16, 2018 12:52:14 AM file_sharing.User_window Send_fileActionPerformed
62+
INFO: package-lock.json 16/04/2018 00:52:14 pm send Avkatran
63+
Apr 16, 2018 12:53:02 AM file_sharing.User_window$3 run
64+
INFO: analytic geometry.pdf 16/04/2018 00:53:02 am recieve Dax
65+
Apr 16, 2018 12:53:02 AM file_sharing.User_window$3 run
66+
INFO: analytic geometry.pdf 16/04/2018 00:53:02 am recieve Dax
67+
Apr 16, 2018 12:53:02 AM file_sharing.User_window$3 run
68+
INFO: analytic geometry.pdf 16/04/2018 00:53:02 am recieve Dax
69+
Apr 16, 2018 12:53:02 AM file_sharing.User_window$3 run
70+
INFO: analytic geometry.pdf 16/04/2018 00:53:02 am recieve Dax
71+
Apr 16, 2018 12:53:02 AM file_sharing.User_window$3 run
72+
INFO: analytic geometry.pdf 16/04/2018 00:53:02 am recieve Dax
73+
Apr 16, 2018 12:56:06 AM file_sharing.User_window$3$1 run
74+
INFO: DBMS_Project_Description.pdf 16/04/2018 00:56:06 am recieve A
75+
Apr 16, 2018 12:56:48 AM file_sharing.User_window Send_fileActionPerformed
76+
INFO: b.py 16/04/2018 00:56:48 pm send Av
77+
Apr 16, 2018 12:56:48 AM file_sharing.User_window Send_fileActionPerformed
78+
INFO: b.py 16/04/2018 00:56:48 pm send Av
79+
Apr 16, 2018 12:57:36 AM file_sharing.User_window$3$1 run
80+
INFO: SchemaDiagram.pdf 16/04/2018 00:57:36 am recieve A
81+
Apr 16, 2018 12:57:36 AM file_sharing.User_window$3$1 run
82+
INFO: SchemaDiagram.pdf 16/04/2018 00:57:36 am recieve A
83+
Apr 16, 2018 12:57:36 AM file_sharing.User_window$3$1 run
84+
INFO: SchemaDiagram.pdf 16/04/2018 00:57:36 am recieve A
85+
Apr 16, 2018 1:03:38 AM file_sharing.User_window$3 run
86+
INFO: 4thsemPaymenteReceipt.pdf 16/04/2018 01:03:38 am recieve Jbjbj
87+
Apr 16, 2018 1:05:40 AM file_sharing.User_window Send_fileActionPerformed
88+
INFO: abstractdata.c 16/04/2018 01:05:40 pm send AV
89+
Apr 16, 2018 1:05:40 AM file_sharing.User_window Send_fileActionPerformed
90+
INFO: abstractdata.c 16/04/2018 01:05:40 pm send AV

File_Sharing/File_sharing.java

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/*
2+
* To change this license header, choose License Headers in Project Properties.
3+
* To change this template file, choose Tools | Templates
4+
* and open the template in the editor.
5+
*/
6+
package file_sharing;
7+
8+
/**
9+
*
10+
* @author Av Singh
11+
*/
12+
public class File_sharing {
13+
14+
/**
15+
* @param args the command line arguments
16+
*/
17+
public static void main(String[] args) {
18+
// TODO code application logic here
19+
}
20+
21+
}

File_Sharing/Progressionbar.java

-14
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this license header, choose License Headers in Project Properties.
3-
* To change this template file, choose Tools | Templates
4-
* and open the template in the editor.
5-
*/
61
package file_sharing;
72

83
import java.awt.BasicStroke;
@@ -17,22 +12,13 @@
1712
import java.util.Random;
1813
import javax.swing.JPanel;
1914

20-
/**
21-
*
22-
* @author rockstar
23-
*/
2415
public class Progressionbar extends JPanel {
25-
26-
/**
27-
* @param args the command line arguments
28-
*/
2916

3017
float progress = 0;
3118

3219
@Override protected void paintComponent (Graphics g) {
3320
AffineTransform at = new AffineTransform();
3421
super.paintComponent(g);
35-
3622
Graphics2D g2 = (Graphics2D) g;
3723
g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
3824
AffineTransform save_ctx = g2.getTransform();

File_Sharing/Server_Main.java

+6-43
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this license header, choose License Headers in Project Properties.
3-
* To change this template file, choose Tools | Templates
4-
* and open the template in the editor.
5-
*/
61
package file_sharing;
72

83
import java.io.DataInputStream;
@@ -18,19 +13,9 @@
1813
import java.util.logging.Level;
1914
import java.util.logging.Logger;
2015

21-
/**
22-
*
23-
* @author rockstar
24-
*/
25-
26-
27-
2816

2917
public class Server_Main extends javax.swing.JFrame {
3018

31-
/**
32-
* Creates new form Server_Main
33-
*/
3419
public Socket socket = null;
3520
public ServerSocket server = null;
3621
public DataInputStream in = null;
@@ -58,13 +43,7 @@ public Server_Main() {
5843
initComponents();
5944
}
6045

61-
/**
62-
* This method is called from within the constructor to initialize the form.
63-
* WARNING: Do NOT modify this code. The content of this method is always
64-
* regenerated by the Form Editor.
65-
*/
6646
@SuppressWarnings("unchecked")
67-
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
6847
private void initComponents() {
6948

7049
portno = new javax.swing.JTextField();
@@ -117,14 +96,12 @@ public void actionPerformed(java.awt.event.ActionEvent evt) {
11796
);
11897

11998
pack();
120-
}// </editor-fold>//GEN-END:initComponents
99+
}
100+
private void portnoActionPerformed(java.awt.event.ActionEvent evt) {
121101

122-
private void portnoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_portnoActionPerformed
123-
// TODO add your handling code here:
124-
}//GEN-LAST:event_portnoActionPerformed
102+
}
125103

126-
private void start_serverActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_start_serverActionPerformed
127-
// TODO add your handling code here:
104+
private void start_serverActionPerformed(java.awt.event.ActionEvent evt) {
128105
pn = Integer.parseInt(this.portno.getText());
129106

130107
this.setupconnection(pn);
@@ -141,25 +118,16 @@ public void run(){
141118
}
142119
});
143120
t1.start();
144-
//
121+
145122

146123

147124

148125
}
149126

150127

151128

152-
}//GEN-LAST:event_start_serverActionPerformed
153-
154-
/**
155-
* @param args the command line arguments
156-
*/
129+
}
157130
public static void main(String args[]) {
158-
/* Set the Nimbus look and feel */
159-
//<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
160-
/* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
161-
* For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html
162-
*/
163131
try {
164132
for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
165133
if ("Nimbus".equals(info.getName())) {
@@ -176,19 +144,14 @@ public static void main(String args[]) {
176144
} catch (javax.swing.UnsupportedLookAndFeelException ex) {
177145
java.util.logging.Logger.getLogger(Server_Main.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
178146
}
179-
//</editor-fold>
180-
181-
/* Create and display the form */
182147
java.awt.EventQueue.invokeLater(new Runnable() {
183148
public void run() {
184149
new Server_Main().setVisible(true);
185150
}
186151
});
187152
}
188153
private int pn;
189-
// Variables declaration - do not modify//GEN-BEGIN:variables
190154
private javax.swing.JLabel jLabel1;
191155
private javax.swing.JTextField portno;
192156
private javax.swing.JButton start_server;
193-
// End of variables declaration//GEN-END:variables
194157
}

0 commit comments

Comments
 (0)