Source code: com/flexstor/common/io/SocketProtocolI.java
1 /*
2 * SocketProtocolI.java
3 *
4 * Copyright $Date: 2003/08/11 02:22:30 $ FLEXSTOR.net Inc.
5 *
6 * This work is licensed for use and distribution under license terms found at
7 * http://www.flexstor.org/license.html
8 *
9 */
10
11 package com.flexstor.common.io;
12
13 public interface SocketProtocolI
14 {
15 public static final int PROTOCOL_BEGIN = 0;
16 public static final int PROTOCOL_GET_FILENAME = 1;
17 public static final int PROTOCOL_VERIFY_PATH = 2;
18 public static final int PROTOCOL_WAIT_FOR_DATA = 3;
19 public static final int PROTOCOL_GET_DATA = 4;
20 public static final int PROTOCOL_FILE_WRITTEN = 5;
21 public static final int PROTOCOL_COMPARE = 6;
22 public static final int PROTOCOL_FAILED = 7;
23 public static final int PROTOCOL_DONE = 8;
24
25 public static final String SOCKET_CONN_ESTABLISHED = "-:Connection Established";
26 public static final String SOCKET_SEND_FILENAME = "-:Send Filename";
27 public static final String SOCKET_CREATE_DIRS = "-:Create Directories";
28 public static final String SOCKET_GET_FILESIZE = "-:Get File Size";
29 public static final String SOCKET_READY_FOR_DATA = "-:Ready for data";
30 public static final String SOCKET_WRITE_DATA = "-:Write Data";
31 public static final String SOCKET_READ_DATA = "-:Read Data";
32 public static final String SOCKET_CHECK_BYTES = "-:Check Bytes";
33 public static final String SOCKET_BEGIN_XFER = "-:Transfer starting";
34 public static final String SOCKET_TRANSFER_COMPLETE = "-:Transfer Complete";
35 public static final String SOCKET_SUCCESS = "-:Success";
36 public static final String SOCKET_FAILURE = "-:Failure ";
37
38 public static final int PROTOCOL_CHUNK_SIZE = 4096;
39
40 }