Class HamletGen

java.lang.Object
org.apache.hadoop.yarn.webapp.hamlet2.HamletGen

@LimitedPrivate({"YARN","MapReduce"}) public class HamletGen extends Object
Generates a specific hamlet implementation class from a spec class using a generic hamlet implementation class.
  • Constructor Details

    • HamletGen

      public HamletGen()
  • Method Details

    • generate

      public void generate(Class<?> specClass, Class<?> implClass, String outputName, String outputPkg) throws IOException
      Generate a specific Hamlet implementation from a spec.
      Parameters:
      specClass - holds hamlet interfaces. e.g. HamletSpec
      implClass - a generic hamlet implementation. e.g. HamletImpl
      outputName - name of the output class. e.g. Hamlet
      outputPkg - package name of the output class.
      Throws:
      IOException - io error occur.
    • main

      public static void main(String[] args) throws Exception
      Throws:
      Exception