01: /***
02: * jwma Java WebMail
03: * Copyright (c) 2000-2003 jwma team
04: *
05: * jwma is free software; you can distribute and use this source
06: * under the terms of the BSD-style license received along with
07: * the distribution.
08: ***/package dtw.webmail.model;
09:
10: /**
11: * An interface defining the contract for interaction with
12: * the JwmaMessagePart model.
13: * <p>
14: * The JwmaMessagePart allows a view programmer to obtain
15: * information about a part of a multipart message.
16: *
17: * @author Dieter Wimberger
18: * @version 0.9.7 07/02/2003
19: */
20: public interface JwmaMessagePart {
21:
22: /**
23: * Returns an <tt>int</tt> representing the number
24: * of this message part.
25: * <p>
26: * This number is the unique identifier for a part of
27: * a message.
28: *
29: * @return the number of this message part.
30: */
31: public int getPartNumber();
32:
33: /**
34: * Returns a <tt>String</tt> representing the
35: * content type of this message part.
36: *
37: * @return the content type of this message part
38: * as String.
39: */
40: public String getContentType();
41:
42: /**
43: * Tests if this <tt>JwmaMessagePart</tt> is of
44: * the given type.
45: *
46: * @param type the Mime type as <tt>String</tt>.
47: */
48: public boolean isMimeType(String type);
49:
50: /**
51: * Returns a <tt>String</tt> representing the
52: * description of this message part.
53: *
54: * @return description of this message part
55: * as String.
56: */
57: public String getDescription();
58:
59: /**
60: * Returns a <tt>String</tt> representing the
61: * name of this message part.
62: *
63: * @return name of this message part
64: * as String.
65: */
66: public String getName();
67:
68: /**
69: * Returns an <tt>int</tt> representing the size
70: * of this message part in bytes.
71: *
72: * @return the size of this message part in bytes.
73: */
74: public int getSize();
75:
76: }//JwmaMessagePart
|