Home » openjdk-7 » java » awt » [javadoc | source]
java.awt
protected class: Component.FlipBufferStrategy [javadoc | source]
java.lang.Object
   java.awt.image.BufferStrategy
      java.awt.Component$FlipBufferStrategy

Direct Known Subclasses:
    FlipSubRegionBufferStrategy

Inner class for flipping buffers on a component. That component must be a Canvas or Window.
Field Summary
protected  int numBuffers    The number of buffers 
protected  BufferCapabilities caps    The buffering capabilities 
protected  Image drawBuffer    The drawing buffer 
protected  VolatileImage drawVBuffer    The drawing buffer as a volatile image 
protected  boolean validatedContents    Whether or not the drawing buffer has been recently restored from a lost state. 
 int width    Size of the back buffers. (Note: these fields were added in 6.0 but kept package-private to avoid exposing them in the spec. None of these fields/methods really should have been marked protected when they were introduced in 1.4, but now we just have to live with that decision.) 
 int height     
Constructor:
 protected FlipBufferStrategy(int numBuffers,
    BufferCapabilities caps) throws AWTException 
    Creates a new flipping buffer strategy for this component. The component must be a Canvas or Window.
    Parameters:
    numBuffers - the number of buffers
    caps - the capabilities of the buffers
    Throws:
    AWTException - if the capabilities supplied could not be supported or met
    ClassCastException - if the component is not a canvas or window.
    IllegalStateException - if the component has no peer
    IllegalArgumentException - if {@code numBuffers} is less than two, or if {@code BufferCapabilities.isPageFlipping} is not {@code true}.
    Also see:
    Canvas
    Window
    createBuffers(int, BufferCapabilities)
    exception: AWTException - if the capabilities supplied could not be supported or met
    exception: ClassCastException - if the component is not a canvas or window.
    exception: IllegalStateException - if the component has no peer
    exception: IllegalArgumentException - if {@code numBuffers} is less than two, or if {@code BufferCapabilities.isPageFlipping} is not {@code true}.
Method from java.awt.Component$FlipBufferStrategy Summary:
contentsLost,   contentsRestored,   createBuffers,   destroyBuffers,   dispose,   flip,   flipSubRegion,   getBackBuffer,   getCapabilities,   getDrawGraphics,   revalidate,   revalidate,   show,   showSubRegion
Methods from java.awt.image.BufferStrategy:
contentsLost,   contentsRestored,   dispose,   getCapabilities,   getDrawGraphics,   show
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.awt.Component$FlipBufferStrategy Detail:
 public boolean contentsLost() 
 public boolean contentsRestored() 
 protected  void createBuffers(int numBuffers,
    BufferCapabilities caps) throws AWTException 
    Creates one or more complex, flipping buffers with the given capabilities.
 protected  void destroyBuffers() 
    Destroys the buffers created through this object
 public  void dispose() 
    {@inheritDoc}
 protected  void flip(FlipContents flipAction) 
    Flipping moves the contents of the back buffer to the front buffer, either by copying or by moving the video pointer.
  void flipSubRegion(int x1,
    int y1,
    int x2,
    int y2,
    FlipContents flipAction) 
 protected Image getBackBuffer() 
 public BufferCapabilities getCapabilities() 
 public Graphics getDrawGraphics() 
 protected  void revalidate() 
    Restore the drawing buffer if it has been lost
  void revalidate(boolean checkSize) 
 public  void show() 
    Makes the next available buffer visible by either blitting or flipping.
  void showSubRegion(int x1,
    int y1,
    int x2,
    int y2) 
    Makes specified region of the the next available buffer visible by either blitting or flipping.