Examples of peek()


Examples of com.gs.collections.api.stack.primitive.ShortStack.peek()

        ShortStack stack = (ShortStack) otherStack;
        if (stack.size() != 1)
        {
            return false;
        }
        return this.element1 == stack.peek();
    }

    @Override
    public int hashCode()
    {
View Full Code Here

Examples of com.hazelcast.core.IQueue.peek()

                        else if(random > 30){
                            q.offer("item");
                            totalOffer.incrementAndGet();
                        }
                        else {
                            q.peek();
                            totalPeek.incrementAndGet();
                        }
                    }
                }
            }.start();
View Full Code Here

Examples of com.hazelcast.core.TransactionalQueue.peek()

    @Override
    public Object innerCall() throws Exception {
        final ClientEndpoint endpoint = getEndpoint();
        final TransactionContext context = endpoint.getTransactionContext(txnId);
        final TransactionalQueue queue = context.getQueue(name);
        return queue.peek(timeout, TimeUnit.MILLISECONDS);
    }

    @Override
    public String getServiceName() {
        return QueueService.SERVICE_NAME;
View Full Code Here

Examples of com.leansoft.bigqueue.IBigQueue.peek()

    QueueResponse resp = new QueueResponse();
    byte[] data = null;
    IBigQueue bigQueue = queueMap.get(topic);
    if (bigQueue != null) {
      try {
        data = bigQueue.peek();
      } catch (IOException e) {
        resp.setResultCode(ResultCode.FAILURE);
        return resp;
      }
    }
View Full Code Here

Examples of com.massivecraft.mcore.xlib.gson.stream.JsonReader.peek()

   */
  public JsonElement parse(Reader json) throws JsonIOException, JsonSyntaxException {
    try {
      JsonReader jsonReader = new JsonReader(json);
      JsonElement element = parse(jsonReader);
      if (!element.isJsonNull() && jsonReader.peek() != JsonToken.END_DOCUMENT) {
        throw new JsonSyntaxException("Did not consume the entire document.");
      }
      return element;
    } catch (MalformedJsonException e) {
      throw new JsonSyntaxException(e);
View Full Code Here

Examples of com.opensymphony.xwork2.util.CompoundRoot.peek()

            if (root instanceof CompoundRoot) {
                if (className.startsWith("vs")) {
                    CompoundRoot compoundRoot = (CompoundRoot) root;

                    if ("vs".equals(className)) {
                        return compoundRoot.peek().getClass();
                    }

                    int index = Integer.parseInt(className.substring(2));

                    return compoundRoot.get(index - 1).getClass();
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.peek()

            {   // A bean list
                boolean result = super.end(writer, body);
                if (result)
                {   // Set current Value
                    ValueStack stack = getStack();
                    pageContext.setAttribute(EmpireValueTagSupport.BEAN_ITEM_ATTRIBUTE, stack.peek());
                }
                return result;
            }
        }   
       
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.OMemoryInputStream.peek()

    final ORID rootRid = new ORecordId();

    try {
      final OMemoryInputStream stream = new OMemoryInputStream(iStream);

      byte protocolVersion = stream.peek();
      if (protocolVersion != -1) {
        // @COMPATIBILITY BEFORE 0.9.25
        stream.getAsByte();
        if (protocolVersion != CURRENT_PROTOCOL_VERSION)
          throw new OSerializationException(
View Full Code Here

Examples of com.peterhi.obsolete.Data.peek()

        Integer.valueOf("11111010", 2).byteValue(),
        Integer.valueOf("10010110", 2).byteValue()
      });
     
      assertEquals(0, data.debug_GetRead());
      BigInteger a = data.peek(32, false);
      assertEquals(0, data.debug_GetRead());
      BigInteger b = data.read(32, false);
      assertEquals(32, data.debug_GetRead());
      assertEquals(a, b);
      assertEquals(0, data.readable());
View Full Code Here

Examples of com.sun.corba.se.impl.orbutil.StackImpl.peek()

    {
        synchronized (this) {
                checkShutdownState();
        }
        StackImpl stack = (StackImpl)(OAInvocationInfoStack.get()) ;
        return (OAInvocationInfo)(stack.peek()) ;
    }

    public void pushInvocationInfo( OAInvocationInfo info )
    {
        synchronized (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.