0 Replies Latest reply on Jan 3, 2006 10:57 PM by Vijay Ganesan

    static field initializer

    Vijay Ganesan Newbie

      Could someone help on how to initialize a static class field of array type as follows:

      private static final Foo[] _foos = {new Foo("a"), new Foo("b")};

      Just feeding this string to CtField.make() causes a compilation error.

      On a related note, how would I add a static block of code in my class?

      static {
      some code;