congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
Thumber.storeImage
Code IndexAdd Tabnine to your IDE (free)

How to use
storeImage
method
in
com.atlassian.core.util.thumbnail.Thumber

Best Java code snippets using com.atlassian.core.util.thumbnail.Thumber.storeImage (Showing top 2 results out of 315)

origin: com.atlassian.core/atlassian-core-thumbnail

private Thumbnail createThumbnail(InputStream inputStream, File thumbnailFile, int maxWidth, int maxHeight, long thumbId, String fileName)
    throws IOException, ThumbnailRenderException {
  final BufferedImage thumbnailImage = scaleImage(maxWidth, maxHeight, inputStream);
  final int height = thumbnailImage.getHeight();
  final int width = thumbnailImage.getWidth();
  storeImage(thumbnailImage, thumbnailFile);
  return new Thumbnail(height, width, fileName, thumbId, mimeType);
}
origin: com.atlassian.core/atlassian-core-utils

private Thumbnail createThumbnail(InputStream originalFile, File thumbnailFile, int maxWidth, int maxHeight, long thumbId, String fileName) throws IOException, FileNotFoundException
{
  // Load original image.
  Image originalImage = getImage(originalFile);
  // Create scaled buffered image from original image.
  BufferedImage scaledImage = scaleImage(originalImage, maxWidth, maxHeight);
  int height = scaledImage.getHeight();
  int width = scaledImage.getWidth();
  storeImage(scaledImage, thumbnailFile);
  return new Thumbnail(height, width, fileName, thumbId);
}
com.atlassian.core.util.thumbnailThumberstoreImage

Javadoc

Store Image in format defined by Thumber constructor.

Popular methods of Thumber

  • getImage
    Reads an image from the specified input stream.
  • scaleImage
    This method should take BufferedImage argument, but takes just Image for backward compatibility (so
  • determineScaleSize
  • <init>
    Thumbnails will be generated of the given type and, if the type permits it (PNG), preserve transpare
  • createThumbnail
  • getThumbnail
  • isFileSupportedImage
  • retrieveOrCreateThumbNail
    Need to pass filename in as we cannot get the filename from the stream that is passed in
  • checkOutputFileCreation
  • storeImageAsJpeg
  • storeImageAsPng
  • storeImageAsPng

Popular in Java

  • Running tasks concurrently on multiple threads
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • setScale (BigDecimal)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • Menu (java.awt)
  • URL (java.net)
    A Uniform Resource Locator that identifies the location of an Internet resource as specified by RFC
  • LinkedHashMap (java.util)
    LinkedHashMap is an implementation of Map that guarantees iteration order. All optional operations a
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • Notification (javax.management)
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now