TopicWord.java
01 package org.apache.qpid.server.exchange.topic;
02 
03 import org.apache.qpid.framing.AMQShortString;
04 
05 import java.util.Map;
06 import java.util.HashMap;
07 import java.util.concurrent.ConcurrentHashMap;
08 
09 /*
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one
12 * or more contributor license agreements.  See the NOTICE file
13 * distributed with this work for additional information
14 * regarding copyright ownership.  The ASF licenses this file
15 * to you under the Apache License, Version 2.0 (the
16 * "License"); you may not use this file except in compliance
17 * with the License.  You may obtain a copy of the License at
18 *
19 *   http://www.apache.org/licenses/LICENSE-2.0
20 *
21 * Unless required by applicable law or agreed to in writing,
22 * software distributed under the License is distributed on an
23 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
24 * KIND, either express or implied.  See the License for the
25 * specific language governing permissions and limitations
26 * under the License.
27 *
28 */
29 public final class TopicWord
30 {
31     public static final TopicWord ANY_WORD = new TopicWord("*");
32     public static final TopicWord WILDCARD_WORD = new TopicWord("#");
33     private String _word;
34 
35     public TopicWord()
36     {
37 
38     }
39 
40     public TopicWord(String s)
41     {
42         _word = s;
43     }
44 
45     public TopicWord(final AMQShortString name)
46     {
47         _word = name.toString();
48     }
49 
50     public String toString()
51     {
52         return _word;
53     }
54 }