View Javadoc

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