- public int[] buildSequence(Production p) {
- Field[] f = _class.getDeclaredFields();
- String[] names = new String[f.length];
- bind.arg[] argtags = new bind.arg[f.length];
- for(int i=0; i<f.length; i++) {
- names[i] = f[i].getName();
- argtags[i] = f[i].getAnnotation(bind.arg.class);
- }
- int[] ret = buildSequence(p, names, argtags);
- if (ret!=null) return ret;
- for(Constructor c : _class.getConstructors())
- if (new TargetConstructor(c).buildSequence(p)!=null)
- return new TargetConstructor(c).buildSequence(p);
- return null;
- }