use of org.eclipse.scout.rt.client.ui.form.fields.IFormField in project scout.rt by eclipse.
the class FindFieldByFormDataIdVisitorTest method testGetFirstFieldOnInnerForm.
@Test
public void testGetFirstFieldOnInnerForm() throws Exception {
InnerForm innerForm = m_mainForm.getWrappedFormField().getInnerForm();
FindFieldByFormDataIdVisitor visitor = new FindFieldByFormDataIdVisitor(FIRST_FIELD_DATA_ID, innerForm);
innerForm.visitFields(visitor);
IFormField field = visitor.getField();
assertNotNull(field);
assertSame(innerForm.getFirstField(), field);
}
use of org.eclipse.scout.rt.client.ui.form.fields.IFormField in project scout.rt by eclipse.
the class FindFieldByFormDataIdVisitorTest method testGetFirstFieldOnInnerInnerForm.
@Test
public void testGetFirstFieldOnInnerInnerForm() throws Exception {
InnerInnerForm innerInnerForm = m_mainForm.getWrappedFormField().getInnerForm().getWrappedFormField().getInnerForm();
FindFieldByFormDataIdVisitor visitor = new FindFieldByFormDataIdVisitor(FIRST_FIELD_DATA_ID, innerInnerForm);
innerInnerForm.visitFields(visitor);
IFormField field = visitor.getField();
assertNotNull(field);
assertSame(innerInnerForm.getFirstField(), field);
}
use of org.eclipse.scout.rt.client.ui.form.fields.IFormField in project scout.rt by eclipse.
the class FindFieldByFormDataIdVisitorTest method testGetThirdFieldWithoutForm.
/* --------------------------------------------------------------------------
* third field
* --------------------------------------------------------------------------
*/
@Test
public void testGetThirdFieldWithoutForm() throws Exception {
FindFieldByFormDataIdVisitor visitor = new FindFieldByFormDataIdVisitor(THIRD_FIELD_DATA_ID);
m_mainForm.visitFields(visitor);
IFormField field = visitor.getField();
assertNotNull(field);
assertSame(m_mainForm.getWrappedFormField().getInnerForm().getWrappedFormField().getInnerForm().getThirdField(), field);
}
use of org.eclipse.scout.rt.client.ui.form.fields.IFormField in project scout.rt by eclipse.
the class FindFieldByFormDataIdVisitorTest method testGetSecondFieldOnInnerForm.
@Test
public void testGetSecondFieldOnInnerForm() throws Exception {
InnerForm innerForm = m_mainForm.getWrappedFormField().getInnerForm();
FindFieldByFormDataIdVisitor visitor = new FindFieldByFormDataIdVisitor(SECOND_FIELD_DATA_ID, innerForm);
innerForm.visitFields(visitor);
IFormField field = visitor.getField();
assertNotNull(field);
assertSame(innerForm.getSecondField(), field);
}
use of org.eclipse.scout.rt.client.ui.form.fields.IFormField in project scout.rt by eclipse.
the class FindFieldByFormDataIdVisitorTest method testGetThirdFieldOnInnerInnerForm.
@Test
public void testGetThirdFieldOnInnerInnerForm() throws Exception {
InnerInnerForm innerInnerForm = m_mainForm.getWrappedFormField().getInnerForm().getWrappedFormField().getInnerForm();
FindFieldByFormDataIdVisitor visitor = new FindFieldByFormDataIdVisitor(THIRD_FIELD_DATA_ID, innerInnerForm);
innerInnerForm.visitFields(visitor);
IFormField field = visitor.getField();
assertNotNull(field);
assertSame(innerInnerForm.getThirdField(), field);
}
Aggregations