01: /**
02: * JOnAS: Java(TM) Open Application Server
03: * Copyright (C) 1999 Bull S.A.
04: * Contact: jonas-team@objectweb.org
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation; either
09: * version 2.1 of the License, or 1any later version.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: *
16: * You should have received a copy of the GNU Lesser General Public
17: * License along with this library; if not, write to the Free Software
18: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19: * USA
20: *
21: * --------------------------------------------------------------------------
22: * $Id: JavaMailMimePartDSResource.java 5279 2004-08-19 09:30:22Z danesa $
23: * --------------------------------------------------------------------------
24: */package org.objectweb.jonas.mail.factory;
25:
26: import java.util.Properties;
27:
28: public class JavaMailMimePartDSResource extends JavaMailResource {
29:
30: /**
31: * Value used as sequence number by reconfiguration notifications
32: */
33: protected long sequenceNumber = 0;
34:
35: public JavaMailMimePartDSResource(String objectName,
36: boolean stateManageable, boolean statisticsProvider,
37: boolean eventProvider, JavaMailMimePartDS mailFactory) {
38: super (objectName, stateManageable, statisticsProvider,
39: eventProvider, mailFactory);
40: }
41:
42: /**
43: * Get the mimePartDatasource properties.
44: * @return the mimePartDatasource properties
45: */
46: public Properties getMimeMessageProperties() {
47: return ((JavaMailMimePartDS) mailFactory)
48: .getMimeMessageProperties();
49: }
50:
51: /**
52: * Set the mimePartDatasource properties.
53: * @param props the mimePartDatasource properties
54: */
55: public void setMimeMessageProperties(Properties props) {
56: ((JavaMailMimePartDS) mailFactory)
57: .setMimeMessageProperties(props);
58: notifyReconfiguration(props);
59: }
60:
61: /**
62: * Gets the sequence number for MBeans operations
63: * @return the sequence number for MBeans operations
64: */
65: protected long getSequenceNumber() {
66: return ++sequenceNumber;
67: }
68: }
|