Class OperationProcessor

java.lang.Object
net.sourceforge.jiu.apps.OperationProcessor
All Implemented Interfaces:
MenuIndexConstants
Direct Known Subclasses:
AwtOperationProcessor

public abstract class OperationProcessor extends Object implements MenuIndexConstants
Abstract base class for performing JIU operations in combination with an EditorState.
Author:
Marco Schmidt
  • Field Details

  • Constructor Details

    • OperationProcessor

      public OperationProcessor(EditorState editorState)
      Create an object of this class, storing the state argument for later use.
      Parameters:
      editorState - EditorState object to be used for processing
  • Method Details

    • colorAdjustBrightness

      public abstract void colorAdjustBrightness()
      Adjust the brightness of the current image.
    • colorAdjustContrast

      public abstract void colorAdjustContrast()
      Adjust the contrast of the current image.
    • colorAdjustGamma

      public abstract void colorAdjustGamma()
      Adjust the gamma value of the current image.
    • colorAdjustHueSaturationValue

      public abstract void colorAdjustHueSaturationValue()
      Adjust hue, saturation and value of the current image.
    • colorHistogramCountColorsUsed

      public abstract void colorHistogramCountColorsUsed()
      Count the number of colors used in the current image.
    • colorHistogramEqualize

      public abstract void colorHistogramEqualize()
    • colorHistogramNormalize

      public abstract void colorHistogramNormalize()
    • colorHistogramTextureProperties

      public abstract void colorHistogramTextureProperties()
    • colorHistogramSaveHistogramAs

      public abstract void colorHistogramSaveHistogramAs()
    • colorHistogramSaveCoOccurrenceMatrixAs

      public abstract void colorHistogramSaveCoOccurrenceMatrixAs()
    • colorHistogramSaveCoOccurrenceFrequencyMatrixAs

      public abstract void colorHistogramSaveCoOccurrenceFrequencyMatrixAs()
    • colorPaletteSaveAs

      public abstract void colorPaletteSaveAs()
    • colorPromotePromoteToPaletted

      public abstract void colorPromotePromoteToPaletted()
    • colorPromotePromoteToGray8

      public abstract void colorPromotePromoteToGray8()
    • colorPromotePromoteToGray16

      public abstract void colorPromotePromoteToGray16()
    • colorPromotePromoteToRgb24

      public abstract void colorPromotePromoteToRgb24()
    • colorPromotePromoteToRgb48

      public abstract void colorPromotePromoteToRgb48()
    • colorReduceReduceNumberOfShadesOfGray

      public abstract void colorReduceReduceNumberOfShadesOfGray()
    • colorReduceConvertToGrayscale

      public abstract void colorReduceConvertToGrayscale()
    • colorReduceMedianCut

      public abstract void colorReduceMedianCut()
    • colorReduceOctree

      public abstract void colorReduceOctree()
    • colorReduceReduceToBilevelThreshold

      public abstract void colorReduceReduceToBilevelThreshold()
    • colorReduceUniformPalette

      public abstract void colorReduceUniformPalette()
    • colorReduceMapToArbitraryPalette

      public abstract void colorReduceMapToArbitraryPalette()
    • colorConvertToMinimumColorType

      public abstract void colorConvertToMinimumColorType()
    • colorInvert

      public abstract void colorInvert()
    • editRedo

      public abstract void editRedo()
    • editUndo

      public abstract void editUndo()
    • filtersBlur

      public abstract void filtersBlur()
    • filtersSharpen

      public abstract void filtersSharpen()
    • filtersEdgeDetection

      public abstract void filtersEdgeDetection()
    • filtersEmboss

      public abstract void filtersEmboss()
    • filtersPsychedelicDistillation

      public abstract void filtersPsychedelicDistillation()
    • filtersLithograph

      public abstract void filtersLithograph()
    • filtersHorizontalSobel

      public abstract void filtersHorizontalSobel()
    • filtersVerticalSobel

      public abstract void filtersVerticalSobel()
    • filtersHorizontalPrewitt

      public abstract void filtersHorizontalPrewitt()
    • filtersVerticalPrewitt

      public abstract void filtersVerticalPrewitt()
    • filtersMaximum

      public abstract void filtersMaximum()
    • filtersMedian

      public abstract void filtersMedian()
    • filtersMean

      public abstract void filtersMean()
    • filtersMinimum

      public abstract void filtersMinimum()
    • filtersOil

      public abstract void filtersOil()
    • transformationsFlip

      public abstract void transformationsFlip()
    • transformationsMirror

      public abstract void transformationsMirror()
    • transformationsRotate90Left

      public abstract void transformationsRotate90Left()
    • transformationsRotate90Right

      public abstract void transformationsRotate90Right()
    • transformationsRotate180

      public abstract void transformationsRotate180()
    • transformationsCrop

      public abstract void transformationsCrop()
    • transformationsShear

      public abstract void transformationsShear()
    • transformationsScale

      public abstract void transformationsScale()
    • viewInterpolationTypeBicubic

      public abstract void viewInterpolationTypeBicubic()
    • viewInterpolationTypeBilinear

      public abstract void viewInterpolationTypeBilinear()
    • viewInterpolationTypeNearestNeighbor

      public abstract void viewInterpolationTypeNearestNeighbor()
    • viewZoomIn

      public abstract void viewZoomIn()
    • viewZoomOut

      public abstract void viewZoomOut()
    • viewSetOriginalSize

      public abstract void viewSetOriginalSize()
    • fileClose

      public abstract void fileClose()
      If there is an image loaded in the application, remove the image.
    • fileExit

      public abstract void fileExit()
      Terminate the application. If changes were not saved, the user should be asked whether these changes should be discarded.
    • fileOpen

      public abstract void fileOpen(String uri)
      Load an image in the application.
    • fileSaveAsBmp

      public abstract void fileSaveAsBmp()
      Save the current image as a Windows BMP file.
    • fileSaveAsGif

      public abstract void fileSaveAsGif()
      Save the current image as a GIF file.
    • fileSaveAsPalm

      public abstract void fileSaveAsPalm()
      Save the current image as a Palm image file.
    • fileSaveAsPbm

      public abstract void fileSaveAsPbm()
      Save the current image as a Portable Bitmap file.
    • fileSaveAsPgm

      public abstract void fileSaveAsPgm()
      Save the current image as a Portable Graymap file.
    • fileSaveAsPng

      public abstract void fileSaveAsPng()
      Save the current image as a Portable Network Graphics file.
    • fileSaveAsPpm

      public abstract void fileSaveAsPpm()
      Save the current image as a Portable Pixmap file.
    • fileSaveAsRas

      public abstract void fileSaveAsRas()
      Save the current image as a Sun Raster file.
    • getEditorState

      public EditorState getEditorState()
      Returns the EditorState object given to this object's constructor.
      Returns:
      EditorState object used by this processor
    • helpAbout

      public abstract void helpAbout()
      Display information about the application: name, version, feedback email address, website.
    • helpSystemInformation

      public abstract void helpSystemInformation()
      Display information on the system this application is currently running on.
    • isAvailable

      public boolean isAvailable(int menuIndex)
      Returns if the operation given by the menu index (from MenuIndexConstants is available regarding the current editor state. This method is used to update the enabled status of menu items so that they reflect what can be done in the current state of an application. Thus, things that cannot be done cannot be chosen in the menu because they are disabled. Example: the File | Save as... items are disabled as long as there is no image loaded, simply because there is nothing to save.
      Parameters:
      menuIndex - index of menu item to be checked
      Returns:
      whether the operation is available (if true, menu item should be enabled)
    • process

      public void process(int menuIndex)