d.Use the setFirstQuestion method in the constructor to specify the first question in the
The following setFirstQuestion code in the SampleInterview example specifies the first question.
public class SampleInterview extends Interview { public SampleInterview(MidpTckBaseInterview parent)
throws Fault { super(parent, "sample"); setResourceBundle("i18n"); setHelpSet("help/sampleInterview"); setFirstQuestion(first);
}
}
e.Specify the question type.
The Question class is a base class that provides the different types of questions required to build the
StringQuestion type.
The following code in the SampleInterview example specifies the
StringQuestion type.
StringQuestion first = new StringQuestion(this, "hello")
In the example, hello is a unique id that identifies the specific question name. This name is used in the properties and map files.