protected void generateTemplateParameters(Template t, ClassFile classFile) {

        // Build the static getTemplateParameterNames method.

        Variable[] params = t.getParams();
        int paramCount = params.length;

        Modifiers pubstat = new Modifiers();
        pubstat.setPublic(true);
        pubstat.setStatic(true);

        TypeDesc stringArrayDesc = TypeDesc.STRING.toArrayType();

        MethodInfo mi = classFile.addMethod
            (pubstat, PARAMETER_METHOD_NAME, stringArrayDesc);

        CodeBuilder builder = new CodeBuilder(mi);
        builder.loadConstant(paramCount);
        builder.newObject(stringArrayDesc);

        // Populate the array.
        for (int i=0; i<paramCount; i++) {
            builder.dup();
            builder.loadConstant(i);
            builder.loadConstant(params[i].getName());
            builder.storeToArray(TypeDesc.STRING);
        }

        builder.returnValue(TypeDesc.OBJECT);

        // Done building the static getTemplateParameterNames method.
    }