01: package de.masters_of_disaster.ant.tasks.ar;
02:
03: /**
04: * This interface contains all the definitions used in the package.
05: */
06:
07: public interface ArConstants {
08: /**
09: * The length of the name field in a file header.
10: */
11: int NAMELEN = 16;
12:
13: /**
14: * The length of the file date field in a file header.
15: */
16: int FILEDATELEN = 12;
17:
18: /**
19: * The length of the user id field in a file header.
20: */
21: int UIDLEN = 6;
22:
23: /**
24: * The length of the group id field in a file header.
25: */
26: int GIDLEN = 6;
27:
28: /**
29: * The length of the mode field in a file header.
30: */
31: int MODELEN = 8;
32:
33: /**
34: * The length of the size field in a file header.
35: */
36: int SIZELEN = 10;
37:
38: /**
39: * The length of the magic field in a file header.
40: */
41: int MAGICLEN = 2;
42:
43: /**
44: * The magic tag put at the end of a file header.
45: */
46: String HEADERMAGIC = "`\n";
47:
48: /**
49: * The headerlength of a file header.
50: */
51: int HEADERLENGTH = NAMELEN + FILEDATELEN + UIDLEN + GIDLEN
52: + MODELEN + SIZELEN + MAGICLEN;
53:
54: /**
55: * The length of the magic field in a file header.
56: */
57: byte[] PADDING = { '\n' };
58:
59: /**
60: * The magic tag representing an ar archive.
61: */
62: byte[] ARMAGIC = { '!', '<', 'a', 'r', 'c', 'h', '>', '\n' };
63: }
|