View Javadoc

1   // Autogenerated Jamon proxy
2   // /Users/misty/git/hbase/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon
3   
4   package org.apache.hadoop.hbase.tmpl.master;
5   
6   // 32, 1
7   import java.util.*;
8   // 33, 1
9   import org.apache.hadoop.util.StringUtils;
10  // 34, 1
11  import org.apache.hadoop.hbase.util.Bytes;
12  // 35, 1
13  import org.apache.hadoop.hbase.util.JvmVersion;
14  // 36, 1
15  import org.apache.hadoop.hbase.util.FSUtils;
16  // 37, 1
17  import org.apache.hadoop.hbase.master.HMaster;
18  // 38, 1
19  import org.apache.hadoop.hbase.master.AssignmentManager;
20  // 39, 1
21  import org.apache.hadoop.hbase.master.ServerManager;
22  // 40, 1
23  import org.apache.hadoop.hbase.HConstants;
24  // 41, 1
25  import org.apache.hadoop.hbase.NamespaceDescriptor;
26  // 42, 1
27  import org.apache.hadoop.hbase.ServerLoad;
28  // 43, 1
29  import org.apache.hadoop.hbase.ServerName;
30  // 44, 1
31  import org.apache.hadoop.hbase.client.Admin;
32  // 45, 1
33  import org.apache.hadoop.hbase.client.HConnectionManager;
34  // 46, 1
35  import org.apache.hadoop.hbase.HTableDescriptor;
36  // 47, 1
37  import org.apache.hadoop.hbase.HBaseConfiguration;
38  // 48, 1
39  import org.apache.hadoop.hbase.TableName;
40  // 49, 1
41  import org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.SnapshotDescription;
42  // 50, 1
43  import org.apache.hadoop.hbase.master.DeadServer;
44  // 51, 1
45  import org.apache.hadoop.hbase.protobuf.ProtobufUtil;
46  // 52, 1
47  import org.apache.hadoop.hbase.security.visibility.VisibilityConstants;
48  // 53, 1
49  import org.apache.hadoop.hbase.security.access.AccessControlLists;
50  
51  @org.jamon.annotations.Template(
52    signature = "F59618D40FCCFCE1A535582D51FAE85C",
53    requiredArguments = {
54      @org.jamon.annotations.Argument(name = "master", type = "HMaster")},
55    optionalArguments = {
56      @org.jamon.annotations.Argument(name = "filter", type = "String"),
57      @org.jamon.annotations.Argument(name = "deadServers", type = "Set<ServerName>"),
58      @org.jamon.annotations.Argument(name = "servers", type = "List<ServerName>"),
59      @org.jamon.annotations.Argument(name = "frags", type = "Map<String,Integer>"),
60      @org.jamon.annotations.Argument(name = "assignmentManager", type = "AssignmentManager"),
61      @org.jamon.annotations.Argument(name = "metaLocation", type = "ServerName"),
62      @org.jamon.annotations.Argument(name = "serverManager", type = "ServerManager"),
63      @org.jamon.annotations.Argument(name = "catalogJanitorEnabled", type = "boolean"),
64      @org.jamon.annotations.Argument(name = "format", type = "String")})
65  public class MasterStatusTmpl
66    extends org.jamon.AbstractTemplateProxy
67  {
68    
69    public MasterStatusTmpl(org.jamon.TemplateManager p_manager)
70    {
71       super(p_manager);
72    }
73    
74    public MasterStatusTmpl()
75    {
76       super("/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl");
77    }
78    
79    protected interface Intf
80      extends org.jamon.AbstractTemplateProxy.Intf{
81      
82      void renderNoFlush(final java.io.Writer jamonWriter) throws java.io.IOException;
83      
84    }
85    public static class ImplData
86      extends org.jamon.AbstractTemplateProxy.ImplData
87    {
88      // 20, 1
89      public void setMaster(HMaster master)
90      {
91        // 20, 1
92        m_master = master;
93      }
94      public HMaster getMaster()
95      {
96        return m_master;
97      }
98      private HMaster m_master;
99      // 26, 1
100     public void setFilter(String filter)
101     {
102       // 26, 1
103       m_filter = filter;
104       m_filter__IsNotDefault = true;
105     }
106     public String getFilter()
107     {
108       return m_filter;
109     }
110     private String m_filter;
111     public boolean getFilter__IsNotDefault()
112     {
113       return m_filter__IsNotDefault;
114     }
115     private boolean m_filter__IsNotDefault;
116     // 24, 1
117     public void setDeadServers(Set<ServerName> deadServers)
118     {
119       // 24, 1
120       m_deadServers = deadServers;
121       m_deadServers__IsNotDefault = true;
122     }
123     public Set<ServerName> getDeadServers()
124     {
125       return m_deadServers;
126     }
127     private Set<ServerName> m_deadServers;
128     public boolean getDeadServers__IsNotDefault()
129     {
130       return m_deadServers__IsNotDefault;
131     }
132     private boolean m_deadServers__IsNotDefault;
133     // 23, 1
134     public void setServers(List<ServerName> servers)
135     {
136       // 23, 1
137       m_servers = servers;
138       m_servers__IsNotDefault = true;
139     }
140     public List<ServerName> getServers()
141     {
142       return m_servers;
143     }
144     private List<ServerName> m_servers;
145     public boolean getServers__IsNotDefault()
146     {
147       return m_servers__IsNotDefault;
148     }
149     private boolean m_servers__IsNotDefault;
150     // 21, 1
151     public void setFrags(Map<String,Integer> frags)
152     {
153       // 21, 1
154       m_frags = frags;
155       m_frags__IsNotDefault = true;
156     }
157     public Map<String,Integer> getFrags()
158     {
159       return m_frags;
160     }
161     private Map<String,Integer> m_frags;
162     public boolean getFrags__IsNotDefault()
163     {
164       return m_frags__IsNotDefault;
165     }
166     private boolean m_frags__IsNotDefault;
167     // 29, 1
168     public void setAssignmentManager(AssignmentManager assignmentManager)
169     {
170       // 29, 1
171       m_assignmentManager = assignmentManager;
172       m_assignmentManager__IsNotDefault = true;
173     }
174     public AssignmentManager getAssignmentManager()
175     {
176       return m_assignmentManager;
177     }
178     private AssignmentManager m_assignmentManager;
179     public boolean getAssignmentManager__IsNotDefault()
180     {
181       return m_assignmentManager__IsNotDefault;
182     }
183     private boolean m_assignmentManager__IsNotDefault;
184     // 22, 1
185     public void setMetaLocation(ServerName metaLocation)
186     {
187       // 22, 1
188       m_metaLocation = metaLocation;
189       m_metaLocation__IsNotDefault = true;
190     }
191     public ServerName getMetaLocation()
192     {
193       return m_metaLocation;
194     }
195     private ServerName m_metaLocation;
196     public boolean getMetaLocation__IsNotDefault()
197     {
198       return m_metaLocation__IsNotDefault;
199     }
200     private boolean m_metaLocation__IsNotDefault;
201     // 28, 1
202     public void setServerManager(ServerManager serverManager)
203     {
204       // 28, 1
205       m_serverManager = serverManager;
206       m_serverManager__IsNotDefault = true;
207     }
208     public ServerManager getServerManager()
209     {
210       return m_serverManager;
211     }
212     private ServerManager m_serverManager;
213     public boolean getServerManager__IsNotDefault()
214     {
215       return m_serverManager__IsNotDefault;
216     }
217     private boolean m_serverManager__IsNotDefault;
218     // 25, 1
219     public void setCatalogJanitorEnabled(boolean catalogJanitorEnabled)
220     {
221       // 25, 1
222       m_catalogJanitorEnabled = catalogJanitorEnabled;
223       m_catalogJanitorEnabled__IsNotDefault = true;
224     }
225     public boolean getCatalogJanitorEnabled()
226     {
227       return m_catalogJanitorEnabled;
228     }
229     private boolean m_catalogJanitorEnabled;
230     public boolean getCatalogJanitorEnabled__IsNotDefault()
231     {
232       return m_catalogJanitorEnabled__IsNotDefault;
233     }
234     private boolean m_catalogJanitorEnabled__IsNotDefault;
235     // 27, 1
236     public void setFormat(String format)
237     {
238       // 27, 1
239       m_format = format;
240       m_format__IsNotDefault = true;
241     }
242     public String getFormat()
243     {
244       return m_format;
245     }
246     private String m_format;
247     public boolean getFormat__IsNotDefault()
248     {
249       return m_format__IsNotDefault;
250     }
251     private boolean m_format__IsNotDefault;
252   }
253   @Override
254   protected ImplData makeImplData()
255   {
256     return new ImplData();
257   }
258   @Override @SuppressWarnings("unchecked") public ImplData getImplData()
259   {
260     return (ImplData) super.getImplData();
261   }
262   
263   protected String filter;
264   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setFilter(String p_filter)
265   {
266     (getImplData()).setFilter(p_filter);
267     return this;
268   }
269   
270   protected Set<ServerName> deadServers;
271   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setDeadServers(Set<ServerName> p_deadServers)
272   {
273     (getImplData()).setDeadServers(p_deadServers);
274     return this;
275   }
276   
277   protected List<ServerName> servers;
278   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setServers(List<ServerName> p_servers)
279   {
280     (getImplData()).setServers(p_servers);
281     return this;
282   }
283   
284   protected Map<String,Integer> frags;
285   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setFrags(Map<String,Integer> p_frags)
286   {
287     (getImplData()).setFrags(p_frags);
288     return this;
289   }
290   
291   protected AssignmentManager assignmentManager;
292   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setAssignmentManager(AssignmentManager p_assignmentManager)
293   {
294     (getImplData()).setAssignmentManager(p_assignmentManager);
295     return this;
296   }
297   
298   protected ServerName metaLocation;
299   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setMetaLocation(ServerName p_metaLocation)
300   {
301     (getImplData()).setMetaLocation(p_metaLocation);
302     return this;
303   }
304   
305   protected ServerManager serverManager;
306   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setServerManager(ServerManager p_serverManager)
307   {
308     (getImplData()).setServerManager(p_serverManager);
309     return this;
310   }
311   
312   protected boolean catalogJanitorEnabled;
313   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setCatalogJanitorEnabled(boolean p_catalogJanitorEnabled)
314   {
315     (getImplData()).setCatalogJanitorEnabled(p_catalogJanitorEnabled);
316     return this;
317   }
318   
319   protected String format;
320   public final org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl setFormat(String p_format)
321   {
322     (getImplData()).setFormat(p_format);
323     return this;
324   }
325   
326   
327   @Override
328   public org.jamon.AbstractTemplateImpl constructImpl(Class<? extends org.jamon.AbstractTemplateImpl> p_class){
329     try
330     {
331       return p_class
332         .getConstructor(new Class [] { org.jamon.TemplateManager.class, ImplData.class })
333         .newInstance(new Object [] { getTemplateManager(), getImplData()});
334     }
335     catch (RuntimeException e)
336     {
337       throw e;
338     }
339     catch (Exception e)
340     {
341       throw new RuntimeException(e);
342     }
343   }
344   
345   @Override
346   protected org.jamon.AbstractTemplateImpl constructImpl(){
347     return new MasterStatusTmplImpl(getTemplateManager(), getImplData());
348   }
349   public org.jamon.Renderer makeRenderer(final HMaster master)
350   {
351     return new org.jamon.AbstractRenderer() {
352       @Override
353       public void renderTo(final java.io.Writer jamonWriter)
354         throws java.io.IOException
355       {
356         render(jamonWriter, master);
357       }
358     };
359   }
360   
361   public void render(final java.io.Writer jamonWriter, final HMaster master)
362     throws java.io.IOException
363   {
364     renderNoFlush(jamonWriter, master);
365     jamonWriter.flush();
366   }
367   public void renderNoFlush(final java.io.Writer jamonWriter, final HMaster master)
368     throws java.io.IOException
369   {
370     ImplData implData = getImplData();
371     implData.setMaster(master);
372     Intf instance = (Intf) getTemplateManager().constructImpl(this);
373     instance.renderNoFlush(jamonWriter);
374     reset();
375   }
376   
377   
378 }