Examples of ImageDetail


Examples of com.netfever.common.jpeg.ImageDetail

      } else {
        photo.setFullSizeBW(FILE_STORAGE_PREFIX + filePath);
      }

      in = Configuration.getSystemRoot().getRoot().getFileItem(filePath).openRead();
      ImageDetail originalDetail;
     
      try {
        originalDetail = ImageUtils.getImageDetail(in);
      } finally {
        in.close();
      }
     
      in = Configuration.getSystemRoot().getRoot().getFileItem(filePath).openRead();
     
      try {
        out = Configuration.getSystemRoot().getRoot().getFileItem(filePath + THUMB_EXT).openWrite();
       
        try {
          double ratio = originalDetail.getHeight() / THUMB_HEIGHT;
          ImageUtils.resize(in, out, ratio);       
        } finally {
          out.close();
        }       
      } finally {
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

     * @return the account image content.
     */
    public ImageDetail getAccountImage()
        throws OperationFailedException
    {
        ImageDetail imageDetail;

        try
        {
            ContentType presContent = xCapClient.getPresContent(
                    PRES_CONTENT_IMAGE_NAME);
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

        return AccountInfoUtils.getImage(this.accountInfoOpSet);
    }

    public void setAvatar(byte[] avatar)
    {
        ImageDetail oldDetail = null;
        ImageDetail newDetail = new ImageDetail("avatar", avatar);

        Iterator<GenericDetail> imageDetails = this.accountInfoOpSet
                .getDetails(ServerStoredDetails.ImageDetail.class);
        if (imageDetails.hasNext())
        {
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

     * @return the account image content.
     */
    public ImageDetail getAccountImage()
        throws OperationFailedException
    {
        ImageDetail imageDetail;

        try
        {
            ContentType presContent = xCapClient.getPresContent(
                    PRES_CONTENT_IMAGE_NAME);
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

        List<T> result = new Vector<T>();

        if (ImageDetail.class.isAssignableFrom(detailClass) &&
                isImageDetailSupported())
        {
            ImageDetail imageDetail = getAccountImage();
            if (imageDetail != null)
            {
                @SuppressWarnings("unchecked")
                T t = (T) getAccountImage();
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

    {
        List<GenericDetail> result = new ArrayList<GenericDetail>();
        if (ImageDetail.class.isAssignableFrom(detailClass) &&
                isImageDetailSupported())
        {
            ImageDetail imageDetail = getAccountImage();
            if (imageDetail != null)
            {
                result.add(getAccountImage());
            }
        }
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

    public Iterator<GenericDetail> getAllAvailableDetails()
    {
        List<GenericDetail> details = new ArrayList<GenericDetail>();
        if (isImageDetailSupported())
        {
            ImageDetail imageDetail = getAccountImage();
            if (imageDetail != null)
            {
                details.add(getAccountImage());
            }
        }
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

                    "Max count for this detail is already reached");
        }
        if (ImageDetail.class.isAssignableFrom(detail.getClass()) &&
                isImageDetailSupported())
        {
            ImageDetail imageDetail = (ImageDetail) detail;
            putImageDetail(imageDetail);
            accountImage = imageDetail;
            isAccountImageLoaded = true;
        }
        else if(DisplayNameDetail.class.isAssignableFrom(detail.getClass()))
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

                    synchronized(this)
                    {
                        byte[] img = byteBlock.toByteArray();

                        if(img != null && img.length > 0)
                            accountImage = new ImageDetail("Account Image", img);

                        this.notifyAll();
                    }
                }
            }
View Full Code Here

Examples of net.java.sip.communicator.service.protocol.ServerStoredDetails.ImageDetail

        if(detailClass.equals(ImageDetail.class)
                && (contact.getImage() != null))
        {
            List<ImageDetail> res = new Vector<ImageDetail>();

            res.add(new ImageDetail("Image", contact.getImage()));

            @SuppressWarnings("unchecked")
            Iterator<T> tIt = (Iterator<T>) res.iterator();

            return tIt;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.