Module org.hdfgroup.hdfview
Package hdf.view.MetaDataView

# Class DefaultBaseMetaDataView

Object
hdf.view.MetaDataView.DefaultBaseMetaDataView

All Implemented Interfaces:
  `DataView`, `MetaDataView`

Direct Known Subclasses:
  `DefaultLinkMetaDataView`

public abstract class DefaultBaseMetaDataView extends Object implements MetaDataView
DefaultBaseMetaDataView is a default implementation of the MetaDataView which is used to show data properties of an object. Data properties include attributes and general object information such as the object type, data type and data space. This base class is responsible for displaying an object's general information and attributes, since these are not object-specific. Subclasses of this class are responsible for displaying any extra object-specific content by overriding the addObjectSpecificContent() method.

Version:
  1.0 4/20/2018
Author:
  Jordan T. Henderson

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected final org.eclipse.swt.widgets.Composite`
  `attributeInfoPane`
  The attribute metadata pane
  `protected final org.eclipse.swt.widgets.TabFolder`
  `contentTabFolder`
  The metadata container
  `protected org.eclipse.swt.graphics.Font`
  `curFont`
  The current font
  `protected HObject`
  `dataObject`
  The HDF data object
  `protected final org.eclipse.swt.widgets.Display`
  `display`
  The default display
  `protected final org.eclipse.swt.widgets.Composite`
  `generalObjectInfoPane`
  The general metadata pane
  `protected boolean`
  `isH4`
  The HDF data object is hdf4 type
  `protected boolean`
  `isH5`
  The HDF data object is hdf5 type
  `protected boolean`
  `isN3`
  The HDF data object is netcdf type
  `protected final DataViewManager`
  `viewManager`
  The view manger reference

  ### Fields inherited from interface hdf.view.DataView.DataView

  `DATAVIEW_IMAGE, DATAVIEW_TABLE, DATAVIEW_UNKNOWN`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DefaultBaseMetaDataView(org.eclipse.swt.widgets.Composite parentComposite, DataViewManager viewer, HObject theObj)`
  The metadata view interface for displaying metadata information

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Attribute`
  `addAttribute(HObject obj)`
  Add an attribute to a data object.
  `protected abstract void`
  `addObjectSpecificContent()`
  Additional metadata to display
  `Attribute`
  `deleteAttribute(HObject obj)`
  Delete an attribute from a data object.
  `HObject`
  `getDataObject()`
  `void`
  `updateFont(org.eclipse.swt.graphics.Font font)`
  Updates the current font.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### display

    protected final org.eclipse.swt.widgets.Display display
    The default display

  - ### viewManager

    protected final DataViewManager viewManager
    The view manger reference

  - ### contentTabFolder

    protected final org.eclipse.swt.widgets.TabFolder contentTabFolder
    The metadata container

  - ### attributeInfoPane

    protected final org.eclipse.swt.widgets.Composite attributeInfoPane
    The attribute metadata pane

  - ### generalObjectInfoPane

    protected final org.eclipse.swt.widgets.Composite generalObjectInfoPane
    The general metadata pane

  - ### curFont

    protected org.eclipse.swt.graphics.Font curFont
    The current font

  - ### dataObject

    protected HObject dataObject
    The HDF data object

  - ### isH5

    protected boolean isH5
    The HDF data object is hdf5 type

  - ### isH4

    protected boolean isH4
    The HDF data object is hdf4 type

  - ### isN3

    protected boolean isN3
    The HDF data object is netcdf type

- ## Constructor Details

  - ### DefaultBaseMetaDataView

    public DefaultBaseMetaDataView(org.eclipse.swt.widgets.Composite parentComposite, DataViewManager viewer, HObject theObj)
    The metadata view interface for displaying metadata information
    Parameters:
      `parentComposite` - the parent visual object
      `viewer` - the viewer to use
      `theObj` - the object to display the metadata info

- ## Method Details

  - ### addObjectSpecificContent

    protected abstract void addObjectSpecificContent()
    Additional metadata to display

  - ### getDataObject

    public HObject getDataObject()
    Specified by:
      `getDataObject` in interface `DataView`
    Returns:
      the data object displayed in this data viewer

  - ### addAttribute

    public Attribute addAttribute(HObject obj)
    Description copied from interface: `MetaDataView`
    Add an attribute to a data object.
    Specified by:
      `addAttribute` in interface `MetaDataView`
    Parameters:
      `obj` - the attribute to add
    Returns:
      the Attribute object

  - ### deleteAttribute

    public Attribute deleteAttribute(HObject obj)
    Description copied from interface: `MetaDataView`
    Delete an attribute from a data object.
    Specified by:
      `deleteAttribute` in interface `MetaDataView`
    Parameters:
      `obj` - the attribute to delte
    Returns:
      the Attribute object

  - ### updateFont

    public void updateFont(org.eclipse.swt.graphics.Font font)
    Updates the current font.
    Parameters:
      `font` - the new font