Examples of first()


Examples of org.apache.directory.shared.ldap.model.cursor.Cursor.first()

        {
            out = new PrintStream( outputStream );
        }

        Cursor cursor = idx.forwardCursor();
        cursor.first();
        for ( Object entry : cursor )
        {
            out.println( entry );
        }
    }
View Full Code Here

Examples of org.apache.jena.atlas.web.AcceptList.first()

       
        AcceptList headerList = new AcceptList(headerString) ;
       
        if ( myPrefs == null )
        {
            MediaType i = headerList.first() ;
            if ( i == null ) return defaultMediaType ;
            return i ;
        }
   
        MediaType i = AcceptList.match(headerList, myPrefs) ;
View Full Code Here

Examples of org.apache.mina.util.Queue.first()

        for( ;; )
        {
            synchronized( writeBufferQueue )
            {
                buf = ( ByteBuffer ) writeBufferQueue.first();
                marker = writeMarkerQueue.first();
            }

            if( buf == null )
                break;
View Full Code Here

Examples of org.apache.pivot.text.CharSequenceCharacterIterator.first()

        float lineWidth = 0;
        int lastWhitespaceIndex = -1;

        Font effectiveFont = getEffectiveFont();
        char c = ci.first();
        while (c != CharacterIterator.DONE
            && lineWidth < breakWidth) {
            if (Character.isWhitespace(c)) {
                lastWhitespaceIndex = ci.getIndex();
            }
View Full Code Here

Examples of org.apache.spark.api.java.JavaDoubleRDD.first()

      List<Double> lengths = new LinkedList<Double>();
      for (String word : s.split(" ")) lengths.add(word.length() * 1.0);
      return lengths;
    });

    Double x = doubles.first();
    Assert.assertEquals(5.0, doubles.first().doubleValue(), 0.01);
    Assert.assertEquals(11, pairs.count());
  }

  @Test
View Full Code Here

Examples of org.apache.xml.dtm.DTMAxisTraverser.first()

    // NodeTest.debugWhatToShow(what);
    if(DTMFilter.SHOW_ALL == what
       || localName == NodeTest.WILD
       || namespace == NodeTest.WILD)
    {
      return traverser.first(current);
    }
    else
    {
      int type = getNodeTypeTest(what);
      int extendedType = dtm.getExpandedTypeID(namespace, localName, type);
View Full Code Here

Examples of org.bukkit.inventory.Inventory.first()

                   
                inv.setItem(inv.firstEmpty(), handitem);
            }
       
            if (inv.contains(item)) {
                Integer slotId = inv.first(item);
                ItemStack stack = inv.getItem(slotId);
                Integer stackAmount = stack.getAmount();

                if (stackAmount > 1 ) {
                    stack.setAmount( stackAmount - 1 );
View Full Code Here

Examples of org.bukkit.inventory.PlayerInventory.first()

   
    PlayerInventory inventory = player.getInventory();
    boolean itemConsumed = false;
   
   
    int idx = inventory.first(itemID);
   
    if (idx >= 0) {
      ItemStack toConsume = inventory.getItem(idx);
      int amt = toConsume.getAmount();
      if (amt > 0) {
View Full Code Here

Examples of org.dmlite.model.component.comment.Comments.first()

    try {
      boolean done;
      Session session = getDomainModel().getSession();
      EntitiesAction action = new RemoveAction(session);
      Comments comments = getComments();
      Comment firstComment = (Comment) comments.first();
      action.setEntities(comments);
      action.setEntity(firstComment);
      done = action.execute();
      log.info("Successful Action: " + done);
    } catch (ActionException ae) {
View Full Code Here

Examples of org.dmlite.model.component.info.Infos.first()

      ModelContext infoModelContext = new ModelContext();
      infoModelContext.setDomainModel(app.getDomainModel());
      Infos infos = (Infos) app.getEntry("Infos");
      Infos orderedInfos = infos.getInfosOrderedByCreationDate(false);
      Info lastInfo = (Info) orderedInfos.first();
      infoModelContext.setEntity(lastInfo);
      ViewContext infoViewContext = new ViewContext();
      infoViewContext.setApp(app);
      infoViewContext.setContextPage(this);
      infoViewContext.setPage(this);
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.