Examples of EJString


Examples of org.jboss.errai.marshalling.client.api.json.EJString

    if (o.isNull()) {
      return null;
    }
    else if (o.isObject() != null) {
      EJObject jsObject = o.isObject();
      EJString string = jsObject.get(SerializationParts.ENCODED_TYPE).isString();
      if (string == null) {
        return MapMarshaller.INSTANCE.demarshall(o, ctx);
      }

      if (jsObject.containsKey(SerializationParts.NUMERIC_VALUE)) {
        return NumbersUtils.getNumber(string.stringValue(), jsObject.get(SerializationParts.NUMERIC_VALUE));
      }

      Marshaller<Object> marshaller = ctx.getMarshallerInstance(string.stringValue());

      if (marshaller == null) {
        throw new RuntimeException("marshalled type is unknown to the marshalling framework: " + string.stringValue());
      }

      return marshaller.demarshall(o, ctx);
    }
    else if (o.isArray() != null) {
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          final EJString activationKey = ejObject.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(session, activationKey.stringValue())) {
            // nope. go away!
            sendMessage(ctx, getFailedNegotiation("bad negotiation key"));
          }
          else {
            // the key matches. now we send the reverse challenge to prove this client is actually
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          EJString activationKey = val.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(cometSession, activationKey.stringValue())) {

            // nope. go away!
            sendMessage(new SimpleEventChannelWrapped(socket), getFailedNegotiation("bad negotiation key"));
          }
          else {
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          EJString activationKey = val.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(session, activationKey.stringValue())) {
            // nope. go away!
            sendMessage(ctx, getFailedNegotiation("bad negotiation key"));
          }
          else {
            // the key matches. now we send the reverse challenge to prove this client is actually
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          final EJString activationKey = val.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(cometSession, activationKey.stringValue())) {

            // nope. go away!
            sendMessage(new SimpleEventChannelWrapped(socket), getFailedNegotiation("bad negotiation key"));
          }
          else {
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

    if (o.isNull() != null) {
      return null;
    }
    else if (o.isObject() != null) {
      EJObject jsObject = o.isObject();
      EJString string = jsObject.get(SerializationParts.ENCODED_TYPE).isString();
      if (string == null) {
        return MapMarshaller.INSTANCE.demarshall(o, ctx);
      }

      if (jsObject.containsKey(SerializationParts.NUMERIC_VALUE)) {
        return NumbersUtils.getNumber(string.stringValue(), jsObject.get(SerializationParts.NUMERIC_VALUE));
      }

      Marshaller<Object> marshaller = ctx.getMarshallerInstance(string.stringValue());

      if (marshaller == null) {
        throw new RuntimeException("marshalled type is unknown to the marshalling framework: " + string.stringValue());
      }

      return marshaller.demarshall(o, ctx);
    }
    else if (o.isArray() != null) {
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

  @Override
  public Object doNotNullDemarshall(EJValue o, MarshallingSession ctx) {
    if (o.isObject() != null) {
      EJObject jsObject = o.isObject();
      EJString string = jsObject.get(SerializationParts.ENCODED_TYPE).isString();
      if (string == null) {
        return MapMarshaller.INSTANCE.demarshall(o, ctx);
      }

      if (jsObject.containsKey(SerializationParts.NUMERIC_VALUE)) {
        return NumbersUtils.getNumber(string.stringValue(), jsObject.get(SerializationParts.NUMERIC_VALUE));
      }

      Marshaller<Object> marshaller = ctx.getMarshallerInstance(string.stringValue());

      if (marshaller == null) {
        throw new RuntimeException("marshalled type is unknown to the marshalling framework: " + string.stringValue());
      }

      return marshaller.demarshall(o, ctx);
    }
    else if (o.isArray() != null) {
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          final EJString activationKey = val.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(cometSession, activationKey.stringValue())) {

            // nope. go away!
            sendMessage(new SimpleEventChannelWrapped(socket), getFailedNegotiation("bad negotiation key"));
          }
          else {
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          final EJString activationKey = ejObject.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(session, activationKey.stringValue())) {
            // nope. go away!
            sendMessage(ctx, getFailedNegotiation("bad negotiation key"));
          }
          else {
            // the key matches. now we send the reverse challenge to prove this client is actually
View Full Code Here

Examples of org.jboss.errai.marshalling.client.api.json.EJString

            return;
          }

          // check the activation key matches.
          final EJString activationKey = val.get(MessageParts.WebSocketToken.name()).isString();
          if (activationKey == null || !WebSocketTokenManager.verifyOneTimeToken(cometSession, activationKey.stringValue())) {

            // nope. go away!
            sendMessage(new SimpleEventChannelWrapped(socket), getFailedNegotiation("bad negotiation key"));
          }
          else {
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.