Class XMLMockObjects

java.lang.Object
ome.specification.XMLMockObjects

public class XMLMockObjects
extends java.lang.Object
Creates XML objects for the 2010-06 schema.
Since:
3.0-Beta4
Version:
3.0 (Internal version: $Revision: $Date: $)
Author:
Jean-Marie Burel      [email protected], Chris Allan      Chris Allan callan at blackcat dot ca
  • Field Details

  • Constructor Details

  • Method Details

    • createDetector

      public Detector createDetector​(int index)
      Creates a detector.
      Parameters:
      index - The index of the detector in the file.
      Returns:
      See above.
    • createFilterSet

      public FilterSet createFilterSet​(int index)
      Creates a filter set.
      Parameters:
      index - The index of the filter set in the file.
      Returns:
      See above.
    • createMicroscope

      public Microscope createMicroscope()
      Creates a microscope.
      Returns:
      See above.
    • createDichroic

      public Dichroic createDichroic​(int index)
      Creates a dichroic.
      Parameters:
      index - The index of the dichroic in the file.
      Returns:
      See above.
    • createObjective

      public Objective createObjective​(int index)
      Creates an objective.
      Parameters:
      index - The index of the objective in the file.
      Returns:
      See above.
    • createFilter

      public Filter createFilter​(int index, double cutIn, double cutOut)
      Creates a filter.
      Parameters:
      index - The index of the objective in the file.
      cutIn - The cut in value.
      cutOut - The cut out value.
      Returns:
      See above.
    • createLightSource

      public LightSource createLightSource​(java.lang.String type, int index)
      Creates a light source of the specified type.
      Parameters:
      type - The type of light source to create.
      index - The index of the light source in the file.
      Returns:
      See above.
    • createBinData

      public BinData createBinData​(int sizeX, int sizeY, int bpp)
      Creates a new object.
      Parameters:
      sizeX - The number of pixels along the X-axis.
      sizeY - The number of pixels along the Y-axis.
      bpp - The number of bytes per pixels.
      Returns:
      See above.
    • createLightPath

      public LightPath createLightPath()
      Creates a light path.
      Returns:
      See above.
    • createImageEnvironment

      public ImagingEnvironment createImageEnvironment()
      Creates a imaging environment.
      Returns:
      See above.
    • createStageLabel

      public StageLabel createStageLabel()
      Creates a imaging environment.
      Returns:
      See above.
    • createLightSourceSettings

      public LightSourceSettings createLightSourceSettings​(int ref)
      Creates a light source settings.
      Parameters:
      ref - Reference to the light source.
      Returns:
      See above.
    • createMicrobeamManipulation

      public MicrobeamManipulation createMicrobeamManipulation​(int index)
      Creates a microbeam manipulation.
      Parameters:
      index - The index in the file.
      Returns:
      See above.
    • createExperimenter

      public Experimenter createExperimenter​(int index)
      Creates an experimenter.
      Parameters:
      index - The index of the Experimenter.
      Returns:
      See above.
    • createExperiment

      public Experiment createExperiment​(int index)
      Creates an experiment.
      Parameters:
      index - The index in the file.
      Returns:
      See above.
    • createExperimentWithMicrobeam

      public Experiment createExperimentWithMicrobeam​(int index)
      Creates an experiment with a microbeam.
      Parameters:
      index - The index in the file.
      Returns:
      See above.
    • createDetectorSettings

      public DetectorSettings createDetectorSettings​(int ref)
      Creates a detector settings.
      Parameters:
      ref - Reference to the detector.
      Returns:
      See above.
    • createObjectiveSettings

      public ObjectiveSettings createObjectiveSettings​(int ref)
      Creates an objective settings.
      Parameters:
      ref - Reference to the objective.
      Returns:
      See above.
    • createBinaryFile

      public BinaryFile createBinaryFile()
      Creates a binary file.
      Returns:
      See above.
    • createShape

      public Shape createShape​(int index, java.lang.String type, int z, int c, int t)
      Creates the specified type of shape.
      Parameters:
      index - The index of the shape in the file.
      type - The type of shape to create.
      z - The selected z-section.
      c - The selected channel.
      t - The selected time-point.
      Returns:
      See above.
    • createROI

      public ROI createROI​(int index, int z, int c, int t)
      Creates an ROI.
      Parameters:
      index - The index of the ROI in the file.
      z - The selected z-section.
      c - The selected channel.
      t - The selected time-point.
    • getRoot

      public OME getRoot()
      Returns the root of the XML file.
      Returns:
      See above.
    • createProject

      public Project createProject​(int index)
      Creates a project.
      Parameters:
      index - The index of the project.
      Returns:
      See above.
    • createDataset

      public Dataset createDataset​(int index)
      Creates a dataset.
      Parameters:
      index - The index of the dataset.
      Returns:
      See above.
    • createScreen

      public Screen createScreen​(int index)
      Creates a screen.
      Parameters:
      index - The index of the screen.
      Returns:
      See above.
    • createBasicPlate

      public Plate createBasicPlate​(int index)
      Creates a basic plate.
      Parameters:
      index - The index of the plate.
      Returns:
      See above.
    • createPlate

      public Plate createPlate​(int numberOfPlates, int index, int numberOfPlateAcquisition)
      Creates a default plate
      Parameters:
      numberOfPlates - The total number of plates.
      index - The index of the plate.
      numberOfPlateAcquisition - The number of plate acquisition to add.
      Returns:
      See above.
    • createPlate

      public Plate createPlate​(int numberOfPlates, int index, int rows, int columns, int fields, int numberOfPlateAcquisition)
      Creates a populated plate with images.
      Parameters:
      numberOfPlates - The total number of plates.
      index - The index of the plate.
      rows - The number of rows.
      columns - The number of columns.
      fields - The number of fields.
      numberOfPlateAcquisition - The number of plate acquisition to add.
      Returns:
      See above.
    • createPlate

      public Plate createPlate​(int numberOfPlates, int index, int rows, int columns, int fields, int numberOfPlateAcquisition, boolean withMicrobeam)
      Creates a populated plate with images.
      Parameters:
      numberOfPlates - The total number of plates.
      index - The index of the plate.
      rows - The number of rows.
      columns - The number of columns.
      fields - The number of fields.
      numberOfPlateAcquisition - The number of plate acquisition to add.
      withMicrobeam - Whether the experiment should contain a microbeam
      Returns:
      See above.
    • createPlate

      public Plate createPlate​(int numberOfScreens, int screenIndex, int numberOfPlates, int plateIndex, int rows, int columns, int fields, int numberOfPlateAcquisition)
      Creates a populated plate with images.
      Parameters:
      numberOfScreens - The total number of screens.
      screenIndex - The index of the screen.
      numberOfPlates - The total number of plates.
      plateIndex - The index of the plate.
      rows - The number of rows.
      columns - The number of columns.
      fields - The number of fields.
      numberOfPlateAcquisition - The number of plate acquisition to add.
      Returns:
      See above.
    • createPlate

      public Plate createPlate​(int numberOfScreens, int screenIndex, int numberOfPlates, int plateIndex, int rows, int columns, int fields, int numberOfPlateAcquisition, boolean withMicrobeam)
      Creates a populated plate with images.
      Parameters:
      numberOfScreens - The total number of screens.
      screenIndex - The index of the screen.
      numberOfPlates - The total number of plates.
      plateIndex - The index of the plate.
      rows - The number of rows.
      columns - The number of columns.
      fields - The number of fields.
      numberOfPlateAcquisition - The number of plate acquisition to add.
      withMicrobeam - Whether the experiment should contain a microbeam
      Returns:
      See above.
    • createPlane

      public Plane createPlane​(int z, int c, int t)
      Creates a plane information object.
      Parameters:
      z - The z-section.
      c - The channel.
      t - The time-point.
      Returns:
      See above.
    • createImage

      public Image createImage​(int index, boolean metadata)
      Creates a new image.
      Parameters:
      index - The identifier of the image.
      metadata - Pass true to create channel with acquisition metadata, false otherwise.
      Returns:
      See above.
    • createChannel

      public Channel createChannel​(int index)
      Creates a channel.
      Parameters:
      index - The index in the file.
      Returns:
      See above.
    • createImage

      public Image createImage​(int index)
      Creates a new image.
      Parameters:
      index - The identifier of the image.
      Returns:
      See above.
    • createInstrument

      public Instrument createInstrument​(boolean populate)
      Creates an instrument with filters, light sources etc.
      Parameters:
      populate - Pass true to populate the instrument, false otherwise.
      Returns:
      See above.
    • createReagent

      public Reagent createReagent​(int index)
      Creates a reagent.
      Parameters:
      index - The index in the file.
      Returns:
      See above.
    • createAnnotation

      public Annotation createAnnotation​(java.lang.String type, OMEModelObject object, int index)
      Create a comment annotation for the specified object.
      Parameters:
      type - The type of annotation to create.
      object - The object to link the annotation to.
      index - The index of the annotation.
      Returns:
      See above.
    • createImage

      public OME createImage()
      Creates and returns the root element. Creates an image w/o metadata.
      Returns:
      See above.
    • createImage

      public OME createImage​(boolean metadata)
      Creates and returns the root element.
      Parameters:
      metadata - Pass true to create an image with metadata, false w/o/
      Returns:
      See above.
    • createAnnotatedImage

      public OME createAnnotatedImage()
      Creates and annotates an image. The following types of annotations are added: TagAnnotation, TermAnnotation, BooleanAnnotation, LongAnnotation, CommentAnnotation.
      Returns:
      See above.
    • createImageWithAcquisitionData

      public OME createImageWithAcquisitionData()
      Creates an image with acquisition data.
      Returns:
      See above.
    • createImageWithAnnotatedAcquisitionData

      public OME createImageWithAnnotatedAcquisitionData()
      Creates an image with acquisition data.
      Returns:
      See above.
    • createImageWithExperiment

      public Image createImageWithExperiment​(int index, boolean metadata, Experiment exp)
      Creates an image with a given experiment. The Image is not added to ome.
      Returns:
      See above.
    • createImageWithROI

      public OME createImageWithROI()
      Creates an image with ROI.
      Returns:
      See above.
    • createPopulatedPlate

      public OME createPopulatedPlate​(int n)
      Creates a plate with 1 row, 1 column and 1field. The plate will have images with acquisition data but no plate acquisition data if the passed value is 0 otherwise will have n plate acquisitions.
      Parameters:
      n - The number of plate acquisition.
      Returns:
      See above
    • createPopulatedPlate

      public OME createPopulatedPlate​(int n, int fields)
      Creates a plate with 1 row, 1 column and fieldsfield. The plate will have images with acquisition data but no plate acquisition data if the passed value is 0 otherwise will have n plate acquisitions.
      Parameters:
      n - The number of plate acquisition.
      fields - The number of fields.
      Returns:
      See above
    • createPopulatedPlate

      public OME createPopulatedPlate​(int plates, int rows, int cols, int fields, int acqs)
      Creates several plates but no containing screen.
      Parameters:
      plates - The number of plates to create.
      rows - The number of rows for plate.
      cols - The number of columns for plate.
      fields - The number of fields.
      acqs - The number of plate acquisitions.
      Returns:
      See above.
    • createPopulatedPlate

      public OME createPopulatedPlate​(int plates, int rows, int cols, int fields, int acqs, boolean withMicrobeam)
      Creates several plates but no containing screen.
      Parameters:
      plates - The number of plates to create.
      rows - The number of rows for plate.
      cols - The number of columns for plate.
      fields - The number of fields.
      acqs - The number of plate acquisitions.
      withMicrobeam - Whether the experiment should contain a microbeam
      Returns:
      See above.
    • createPopulatedScreen

      public OME createPopulatedScreen​(int screens, int plates, int rows, int cols, int fields, int acqs)
      Creates several screens each with several plates.
      Parameters:
      screens - The number of screens to create.
      plates - The number of plates to create.
      rows - The number of rows for plate.
      cols - The number of columns for plate.
      fields - The number of fields.
      acqs - The number of plate acquisitions.
      Returns:
      See above.
    • createPopulatedScreen

      public OME createPopulatedScreen​(int screens, int plates, int rows, int cols, int fields, int acqs, boolean withMicrobeam)
      Creates several screens each with several plates.
      Parameters:
      screens - The number of screens to create.
      plates - The number of plates to create.
      rows - The number of rows for plate.
      cols - The number of columns for plate.
      fields - The number of fields.
      acqs - The number of plate acquisitions.
      withMicrobeam - Whether the experiment should contain a microbeam
      Returns:
      See above.
    • createPopulatedScreen

      public OME createPopulatedScreen​(int plates, int rows, int cols, int fields, int acqs)
      Creates a screen with several plates.
      Parameters:
      plates - The number of plates to create.
      rows - The number of rows for plate.
      cols - The number of columns for plate.
      fields - The number of fields.
      acqs - The number of plate acquisitions.
      Returns:
      See above.
    • createPopulatedScreen

      public OME createPopulatedScreen()
      Creates one 2x2 plate of with a single well sample per well and one plate acquisition.
    • createBasicPlateWithReagent

      public OME createBasicPlateWithReagent()
      Creates a plate with 1 row, 1 column and 1 field. This plate will be added to a screen and the well linked to a reagent.
      Returns:
      See above
    • createFullPopulatedPlate

      public OME createFullPopulatedPlate​(int n)
      Creates a plate with ROWS rows, COLUMNS columns and FIELDS field. The plate will have images with acquisition data but no plate acquisition data.
      Parameters:
      n - The number of plate acquisition.
      Returns:
      See above