Examples of RecipientChunksSorter


Examples of org.apache.poi.hsmf.datatypes.RecipientChunks.RecipientChunksSorter

      // Simple
      chunks = new RecipientChunks[] {
            new RecipientChunks("__recip_version1.0_#00000001"),
            new RecipientChunks("__recip_version1.0_#00000000"),
      };
      Arrays.sort(chunks, new RecipientChunksSorter());
      assertEquals(0, chunks[0].recipientNumber);
      assertEquals(1, chunks[1].recipientNumber);
     
      // Lots, with gaps
      chunks = new RecipientChunks[] {
            new RecipientChunks("__recip_version1.0_#00020001"),
            new RecipientChunks("__recip_version1.0_#000000FF"),
            new RecipientChunks("__recip_version1.0_#00000205"),
            new RecipientChunks("__recip_version1.0_#00000001"),
            new RecipientChunks("__recip_version1.0_#00000005"),
            new RecipientChunks("__recip_version1.0_#00000009"),
            new RecipientChunks("__recip_version1.0_#00000404"),
            new RecipientChunks("__recip_version1.0_#00000000"),
      };
      Arrays.sort(chunks, new RecipientChunksSorter());
      assertEquals(0, chunks[0].recipientNumber);
      assertEquals(1, chunks[1].recipientNumber);
      assertEquals(5, chunks[2].recipientNumber);
      assertEquals(9, chunks[3].recipientNumber);
      assertEquals(0xFF, chunks[4].recipientNumber);
View Full Code Here

Examples of org.apache.poi.hsmf.datatypes.RecipientChunks.RecipientChunksSorter

      recipientChunks  = recipients.toArray(new RecipientChunks[recipients.size()]);

      // Now sort these chunks lists so they're in ascending order,
      //  rather than in random filesystem order
      Arrays.sort(attachmentChunks, new AttachmentChunksSorter());
      Arrays.sort(recipientChunks, new RecipientChunksSorter());
   }
View Full Code Here

Examples of org.apache.poi.hsmf.datatypes.RecipientChunks.RecipientChunksSorter

      recipientChunks  = recipients.toArray(new RecipientChunks[recipients.size()]);

      // Now sort these chunks lists so they're in ascending order,
      //  rather than in random filesystem order
      Arrays.sort(attachmentChunks, new AttachmentChunksSorter());
      Arrays.sort(recipientChunks, new RecipientChunksSorter());
   }
View Full Code Here

Examples of org.apache.poi.hsmf.datatypes.RecipientChunks.RecipientChunksSorter

      assertEquals("nickb@alfresco.com", chunks[4].getRecipientEmailAddress());
      assertEquals("'Paul Holmes-Higgin'", chunks[5].getRecipientName());
      assertEquals("paul.hh@alfresco.com", chunks[5].getRecipientEmailAddress());
     
      // Now sort, and re-check
      Arrays.sort(chunks, new RecipientChunksSorter());
     
      assertEquals("'Ashutosh Dandavate'", chunks[0].getRecipientName());
      assertEquals("ashutosh.dandavate@alfresco.com", chunks[0].getRecipientEmailAddress());
      assertEquals("'Paul Holmes-Higgin'", chunks[1].getRecipientName());
      assertEquals("paul.hh@alfresco.com", chunks[1].getRecipientEmailAddress());
View Full Code Here

Examples of org.apache.poi.hsmf.datatypes.RecipientChunks.RecipientChunksSorter

      recipientChunks  = recipients.toArray(new RecipientChunks[recipients.size()]);

      // Now sort these chunks lists so they're in ascending order,
      //  rather than in random filesystem order
      Arrays.sort(attachmentChunks, new AttachmentChunksSorter());
      Arrays.sort(recipientChunks, new RecipientChunksSorter());
   }
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.