ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/server/uk/org/iscream/cms/server/rootfilter/RootFilterServant.java
Revision: 1.15
Committed: Wed Mar 14 23:25:29 2001 UTC (23 years, 2 months ago) by tdb
Branch: MAIN
CVS Tags: PROJECT_COMPLETION
Changes since 1.14: +9 -9 lines
Log Message:
The whole server package structure has been changed.
Old Package: uk.ac.ukc.iscream.*
New Package: uk.org.iscream.*

File Contents

# User Rev Content
1 tdb 1.1 //---PACKAGE DECLARATION---
2 tdb 1.15 package uk.org.iscream.rootfilter;
3 tdb 1.1
4     //---IMPORTS---
5 tdb 1.15 import uk.org.iscream.core.*;
6     import uk.org.iscream.componentmanager.*;
7     import uk.org.iscream.filter.*;
8     import uk.org.iscream.clientinterface.*;
9     import uk.org.iscream.util.*;
10 tdb 1.1
11     /**
12 ajm 1.11 * A root filter servant has an array
13     * of client interfaces where data should be
14     * piped.
15 tdb 1.1 *
16 tdb 1.13 * @author $Author: tdb1 $
17 tdb 1.15 * @version $Id: RootFilterServant.java,v 1.14 2001/01/28 05:40:36 tdb1 Exp $
18 tdb 1.1 */
19     class RootFilterServant extends FilterPOA {
20    
21     //---FINAL ATTRIBUTES---
22    
23     /**
24     * The current CVS revision of this class
25     */
26 tdb 1.15 public final String REVISION = "$Revision: 1.14 $";
27 tdb 1.1
28     //---STATIC METHODS---
29    
30     //---CONSTRUCTORS---
31    
32     /**
33     * Creates a new RootFilter.
34     *
35 tdb 1.12 * @param queue a Queue to use
36 tdb 1.1 */
37 tdb 1.12 public RootFilterServant(Queue queue) {
38     _queue = queue;
39 ajm 1.11 _logger.write(toString(), Logger.SYSINIT, "created");
40 tdb 1.1 }
41    
42     //---PUBLIC METHODS---
43    
44     /**
45     * Method to receive a string over corba.
46     *
47 tdb 1.12 * @param xml the String of XML to send on
48 tdb 1.1 */
49     public void receiveXML(String xml) {
50 tdb 1.12 _queue.add(xml);
51 tdb 1.3 }
52    
53 tdb 1.1 /**
54     * Overrides the {@link java.lang.Object#toString() Object.toString()}
55     * method to provide clean logging (every class should have this).
56     *
57 tdb 1.15 * This uses the uk.org.iscream.util.NameFormat class
58 ajm 1.11 * to format the toString()
59     *
60 tdb 1.1 * @return the name of this class and its CVS revision
61     */
62     public String toString() {
63 ajm 1.11 return FormatName.getName(
64     _name,
65     getClass().getName(),
66     REVISION);
67 tdb 1.1 }
68    
69     //---PRIVATE METHODS---
70    
71     //---ACCESSOR/MUTATOR METHODS---
72    
73 tdb 1.14 /**
74     * This method is provided because the RootFilter appears
75     * as another Filter to the rest of the Filter tree. This
76     * method is required by the interface, although it actually
77     * returns null.
78     *
79     * @return null
80     */
81 ajm 1.11 public String getUDPPort() {
82     return null;
83     }
84    
85 tdb 1.14 /**
86     * This method is provided because the RootFilter appears
87     * as another Filter to the rest of the Filter tree. This
88     * method is required by the interface, although it actually
89     * returns null.
90     *
91     * @return null
92     */
93 ajm 1.11 public String getTCPPort() {
94     return null;
95     }
96    
97 tdb 1.14 /**
98     * This method is provided because the RootFilter appears
99     * as another Filter to the rest of the Filter tree. This
100     * method is required by the interface, although it actually
101     * returns null.
102     *
103     * @return null
104     */
105 ajm 1.11 public String getHostName() {
106     return null;
107     }
108    
109 tdb 1.1 //---ATTRIBUTES---
110    
111     /**
112 ajm 1.11 * This is the friendly identifier of the
113     * component this class is running in.
114     * eg, a Filter may be called "filter1",
115     * If this class does not have an owning
116     * component, a name from the configuration
117     * can be placed here. This name could also
118     * be changed to null for utility classes.
119     */
120     private String _name = RootFilter.NAME;
121    
122     /**
123     * This holds a reference to the
124     * system logger that is being used.
125 tdb 1.1 */
126 tdb 1.8 private Logger _logger = ReferenceManager.getInstance().getLogger();
127 tdb 1.1
128     /**
129 tdb 1.12 * A reference to the Queue being used.
130     */
131     private Queue _queue;
132 tdb 1.1
133     //---STATIC ATTRIBUTES---
134    
135     }