View Javadoc
1   /*
2    * Copyright (C) 2013 4th Line GmbH, Switzerland
3    *
4    * The contents of this file are subject to the terms of either the GNU
5    * Lesser General Public License Version 2 or later ("LGPL") or the
6    * Common Development and Distribution License Version 1 or later
7    * ("CDDL") (collectively, the "License"). You may not use this file
8    * except in compliance with the License. See LICENSE.txt for more
9    * information.
10   *
11   * This program 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.
14   */
15  
16  package org.fourthline.cling.support.shared;
17  
18  import org.seamless.swing.logging.LogCategory;
19  
20  import java.util.ArrayList;
21  import java.util.logging.Level;
22  
23  /**
24   * @author Christian Bauer
25   */
26  public class CoreLogCategories extends ArrayList<LogCategory> {
27  
28      public CoreLogCategories() {
29          super(10);
30  
31          add(new LogCategory("Network", new LogCategory.Group[]{
32  
33                  new LogCategory.Group(
34                          "UDP communication",
35                          new LogCategory.LoggerLevel[]{
36                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.DatagramIO.class.getName(), Level.FINE),
37                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.MulticastReceiver.class.getName(), Level.FINE),
38                          }
39                  ),
40  
41                  new LogCategory.Group(
42                          "UDP datagram processing and content",
43                          new LogCategory.LoggerLevel[]{
44                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.DatagramProcessor.class.getName(), Level.FINER)
45                          }
46                  ),
47  
48                  new LogCategory.Group(
49                          "TCP communication",
50                          new LogCategory.LoggerLevel[]{
51                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.UpnpStream.class.getName(), Level.FINER),
52                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.StreamServer.class.getName(), Level.FINE),
53                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.StreamClient.class.getName(), Level.FINE),
54                          }
55                  ),
56  
57                  new LogCategory.Group(
58                          "SOAP action message processing and content",
59                          new LogCategory.LoggerLevel[]{
60                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.SOAPActionProcessor.class.getName(), Level.FINER)
61                          }
62                  ),
63  
64                  new LogCategory.Group(
65                          "GENA event message processing and content",
66                          new LogCategory.LoggerLevel[]{
67                                  new LogCategory.LoggerLevel(org.fourthline.cling.transport.spi.GENAEventProcessor.class.getName(), Level.FINER)
68                          }
69                  ),
70  
71                  new LogCategory.Group(
72                          "HTTP header processing",
73                          new LogCategory.LoggerLevel[]{
74                                  new LogCategory.LoggerLevel(org.fourthline.cling.model.message.UpnpHeaders.class.getName(), Level.FINER)
75                          }
76                  ),
77          }));
78  
79  
80          add(new LogCategory("UPnP Protocol", new LogCategory.Group[]{
81  
82                  new LogCategory.Group(
83                          "Discovery (Notification & Search)",
84                          new LogCategory.LoggerLevel[]{
85                                  new LogCategory.LoggerLevel(org.fourthline.cling.protocol.ProtocolFactory.class.getName(), Level.FINER),
86                                  new LogCategory.LoggerLevel("org.fourthline.cling.protocol.async", Level.FINER)
87                          }
88                  ),
89  
90                  new LogCategory.Group(
91                          "Description",
92                          new LogCategory.LoggerLevel[]{
93                                  new LogCategory.LoggerLevel(org.fourthline.cling.protocol.ProtocolFactory.class.getName(), Level.FINER),
94                                  new LogCategory.LoggerLevel(org.fourthline.cling.protocol.RetrieveRemoteDescriptors.class.getName(), Level.FINE),
95                                  new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.ReceivingRetrieval.class.getName(), Level.FINE),
96                                  new LogCategory.LoggerLevel(org.fourthline.cling.binding.xml.DeviceDescriptorBinder.class.getName(), Level.FINE),
97                                  new LogCategory.LoggerLevel(org.fourthline.cling.binding.xml.ServiceDescriptorBinder.class.getName(), Level.FINE),
98                          }
99                  ),
100 
101                 new LogCategory.Group(
102                         "Control",
103                         new LogCategory.LoggerLevel[]{
104                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.ProtocolFactory.class.getName(), Level.FINER),
105                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.ReceivingAction.class.getName(), Level.FINER),
106                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.SendingAction.class.getName(), Level.FINER),
107                         }
108                 ),
109 
110                 new LogCategory.Group(
111                         "GENA ",
112                         new LogCategory.LoggerLevel[]{
113                                 new LogCategory.LoggerLevel("org.fourthline.cling.model.gena", Level.FINER),
114                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.ProtocolFactory.class.getName(), Level.FINER),
115                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.ReceivingEvent.class.getName(), Level.FINER),
116                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.ReceivingSubscribe.class.getName(), Level.FINER),
117                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.ReceivingUnsubscribe.class.getName(), Level.FINER),
118                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.SendingEvent.class.getName(), Level.FINER),
119                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.SendingSubscribe.class.getName(), Level.FINER),
120                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.SendingUnsubscribe.class.getName(), Level.FINER),
121                                 new LogCategory.LoggerLevel(org.fourthline.cling.protocol.sync.SendingRenewal.class.getName(), Level.FINER),
122                         }
123                 ),
124         }));
125 
126         add(new LogCategory("Core", new LogCategory.Group[]{
127 
128                 new LogCategory.Group(
129                         "Router",
130                         new LogCategory.LoggerLevel[]{
131                                 new LogCategory.LoggerLevel(org.fourthline.cling.transport.Router.class.getName(), Level.FINER)
132                         }
133                 ),
134 
135                 new LogCategory.Group(
136                         "Registry",
137                         new LogCategory.LoggerLevel[]{
138                                 new LogCategory.LoggerLevel(org.fourthline.cling.registry.Registry.class.getName(), Level.FINER),
139                         }
140                 ),
141 
142                 new LogCategory.Group(
143                         "Local service binding & invocation",
144                         new LogCategory.LoggerLevel[]{
145                                 new LogCategory.LoggerLevel("org.fourthline.cling.binding.annotations", Level.FINER),
146                                 new LogCategory.LoggerLevel(org.fourthline.cling.model.meta.LocalService.class.getName(), Level.FINER),
147                                 new LogCategory.LoggerLevel("org.fourthline.cling.model.action", Level.FINER),
148                                 new LogCategory.LoggerLevel("org.fourthline.cling.model.state", Level.FINER),
149                                 new LogCategory.LoggerLevel(org.fourthline.cling.model.DefaultServiceManager.class.getName(), Level.FINER)
150                         }
151                 ),
152 
153                 new LogCategory.Group(
154                         "Control Point interaction",
155                         new LogCategory.LoggerLevel[]{
156                                 new LogCategory.LoggerLevel("org.fourthline.cling.controlpoint", Level.FINER),
157                         }
158                 ),
159         }));
160 
161     }
162 
163 }