Bug 160000 [DataBinding] Convert scenarios to official APIs
tests/org.eclipse.jface.tests.databinding/src/org/eclipse/jface/tests/databinding/scenarios/MasterDetailScenarios.java
// 
		// 
		// 
		final Catalog catalog = SampleData.CATALOG_2005;
		final ListViewer categoryListViewer = new ListViewer(getComposite(),
				SWT.BORDER);
		categoryListViewer.getList().setLayoutData(
				new GridData(SWT.FILL, SWT.FILL, false, false));
		categoryListViewer.setLabelProvider(new LabelProvider() {
			public String getText(Object element) {
				return ((Category) element).getName();
			}
		});
		categoryListViewer
				.setContentProvider(new ObservableListContentProvider());
		categoryListViewer.setInput(BeansObservables.observeList(realm,
				catalog, "categories"));
		assertArrayEquals(catalog.getCategories(), getViewerContent(
				categoryListViewer).toArray());
		final IObservableValue selectedCategoryObservable = ViewersObservables
				.observeSingleSelection(categoryListViewer);
		final ListViewer adventureListViewer = new ListViewer(getComposite(),
				SWT.BORDER);
		adventureListViewer.getList().setLayoutData(
				new GridData(SWT.FILL, SWT.FILL, false, false));
		adventureListViewer.setLabelProvider(new LabelProvider() {
			public String getText(Object element) {
				return ((Adventure) element).getName();
			}