Package com.iviu.gcm.Result

Examples of com.iviu.gcm.Result.Builder


        String[] responseParts = split(line);
        String token = responseParts[0];
        String value = responseParts[1];
        if (token.equals(TOKEN_MESSAGE_ID))
        {
          Builder builder = new Result.Builder().messageId(value);
          // check for canonical registration id
          line = reader.readLine();
          if (line != null)
          {
            responseParts = split(line);
            token = responseParts[0];
            value = responseParts[1];
            if (token.equals(TOKEN_CANONICAL_REG_ID))
            {
              builder.canonicalRegistrationId(value);
            }
            else
            {
              logger.warning("Received invalid second line from GCM: "
                  + line);
            }
          }

          Result result = builder.build();
          if (logger.isLoggable(Level.FINE))
          {
            logger.fine("Message created succesfully (" + result
                + ")");
          }
View Full Code Here

TOP

Related Classes of com.iviu.gcm.Result.Builder

Copyright © 2018 www.massapicom. 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.