View Javadoc

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