%line | %branch | |||||||||
---|---|---|---|---|---|---|---|---|---|---|
org.apache.turbine.util.mail.EmailAttachment |
|
|
1 | package org.apache.turbine.util.mail; |
|
2 | ||
3 | /* |
|
4 | * Copyright 2001-2005 The Apache Software Foundation. |
|
5 | * |
|
6 | * Licensed under the Apache License, Version 2.0 (the "License") |
|
7 | * you may not use this file except in compliance with the License. |
|
8 | * You may obtain a copy of the License at |
|
9 | * |
|
10 | * http://www.apache.org/licenses/LICENSE-2.0 |
|
11 | * |
|
12 | * Unless required by applicable law or agreed to in writing, software |
|
13 | * distributed under the License is distributed on an "AS IS" BASIS, |
|
14 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
15 | * See the License for the specific language governing permissions and |
|
16 | * limitations under the License. |
|
17 | */ |
|
18 | ||
19 | import java.net.URL; |
|
20 | ||
21 | /** |
|
22 | * This class models an email attachment. Used by MultiPartEmail. |
|
23 | * |
|
24 | * @author <a href="mailto:frank.kim@clearink.com">Frank Y. Kim</a> |
|
25 | * @version $Id: EmailAttachment.java 264148 2005-08-29 14:21:04Z henning $ |
|
26 | * @deprecated Use org.apache.commons.mail.EmailAttachment instead. |
|
27 | */ |
|
28 | 0 | public class EmailAttachment |
29 | { |
|
30 | public final static String ATTACHMENT = javax.mail.Part.ATTACHMENT; |
|
31 | public final static String INLINE = javax.mail.Part.INLINE; |
|
32 | ||
33 | /** The name of this attachment. */ |
|
34 | 0 | private String name = ""; |
35 | ||
36 | /** The description of this attachment. */ |
|
37 | 0 | private String description = ""; |
38 | ||
39 | /** The full path to this attachment (ie c:/path/to/file.jpg). */ |
|
40 | 0 | private String path = ""; |
41 | ||
42 | /** The HttpURI where the file can be got. */ |
|
43 | 0 | private URL url = null; |
44 | ||
45 | /** The disposition. */ |
|
46 | 0 | private String disposition = ATTACHMENT; |
47 | ||
48 | /** |
|
49 | * Get the description. |
|
50 | * |
|
51 | * @return A String. |
|
52 | */ |
|
53 | public String getDescription() |
|
54 | { |
|
55 | 0 | return description; |
56 | } |
|
57 | ||
58 | /** |
|
59 | * Get the name. |
|
60 | * |
|
61 | * @return A String. |
|
62 | */ |
|
63 | public String getName() |
|
64 | { |
|
65 | 0 | return name; |
66 | } |
|
67 | ||
68 | /** |
|
69 | * Get the path. |
|
70 | * |
|
71 | * @return A String. |
|
72 | */ |
|
73 | public String getPath() |
|
74 | { |
|
75 | 0 | return path; |
76 | } |
|
77 | ||
78 | /** |
|
79 | * Get the URL. |
|
80 | * |
|
81 | * @return A URL. |
|
82 | */ |
|
83 | public URL getURL() |
|
84 | { |
|
85 | 0 | return url; |
86 | } |
|
87 | ||
88 | /** |
|
89 | * Get the disposition. |
|
90 | * |
|
91 | * @return A String. |
|
92 | */ |
|
93 | public String getDisposition() |
|
94 | { |
|
95 | 0 | return disposition; |
96 | } |
|
97 | ||
98 | /** |
|
99 | * Set the description. |
|
100 | * |
|
101 | * @param desc A String. |
|
102 | */ |
|
103 | public void setDescription(String desc) |
|
104 | { |
|
105 | 0 | this.description = desc; |
106 | 0 | } |
107 | ||
108 | /** |
|
109 | * Set the name. |
|
110 | * |
|
111 | * @param name A String. |
|
112 | */ |
|
113 | public void setName(String name) |
|
114 | { |
|
115 | 0 | this.name = name; |
116 | 0 | } |
117 | ||
118 | /** |
|
119 | * Set the path. |
|
120 | * |
|
121 | * @param path A String. |
|
122 | */ |
|
123 | public void setPath(String path) |
|
124 | { |
|
125 | 0 | this.path = path; |
126 | 0 | } |
127 | ||
128 | /** |
|
129 | * Set the URL. |
|
130 | * |
|
131 | * @param url A URL. |
|
132 | */ |
|
133 | public void setURL(URL url) |
|
134 | { |
|
135 | 0 | this.url = url; |
136 | 0 | } |
137 | ||
138 | /** |
|
139 | * Set the disposition. |
|
140 | * |
|
141 | * @param disposition A String. |
|
142 | */ |
|
143 | public void setDisposition(String disposition) |
|
144 | { |
|
145 | 0 | this.disposition = disposition; |
146 | 0 | } |
147 | } |
This report is generated by jcoverage, Maven and Maven JCoverage Plugin. |