Package org.smslib.helper

Examples of org.smslib.helper.ExtStringBuilder.replaceAll()


  {
    ExtStringBuilder sb = new ExtStringBuilder(template);
    sb.replaceAll("%gatewayId%", URLEncoder.encode(msg.getGatewayId(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    if(msg.getDate() != null) sb.replaceAll("%date%", URLEncoder.encode(msg.getDate().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%text%", URLEncoder.encode(msg.getText(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%refNo%", URLEncoder.encode(msg.getRefNo(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%recipient%", msg.getRecipient());
    sb.replaceAll("%from%", msg.getFrom());
    sb.replaceAll("%failureCause%", URLEncoder.encode(msg.getFailureCause().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%messageStatus%", msg.getMessageStatus().toString());
View Full Code Here


    ExtStringBuilder sb = new ExtStringBuilder(template);
    sb.replaceAll("%gatewayId%", URLEncoder.encode(msg.getGatewayId(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    if(msg.getDate() != null) sb.replaceAll("%date%", URLEncoder.encode(msg.getDate().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%text%", URLEncoder.encode(msg.getText(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%refNo%", URLEncoder.encode(msg.getRefNo(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%recipient%", msg.getRecipient());
    sb.replaceAll("%from%", msg.getFrom());
    sb.replaceAll("%failureCause%", URLEncoder.encode(msg.getFailureCause().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%messageStatus%", msg.getMessageStatus().toString());
    return sb.toString();
View Full Code Here

    sb.replaceAll("%gatewayId%", URLEncoder.encode(msg.getGatewayId(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    if(msg.getDate() != null) sb.replaceAll("%date%", URLEncoder.encode(msg.getDate().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%text%", URLEncoder.encode(msg.getText(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%refNo%", URLEncoder.encode(msg.getRefNo(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%recipient%", msg.getRecipient());
    sb.replaceAll("%from%", msg.getFrom());
    sb.replaceAll("%failureCause%", URLEncoder.encode(msg.getFailureCause().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%messageStatus%", msg.getMessageStatus().toString());
    return sb.toString();
  }  }
View Full Code Here

    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    if(msg.getDate() != null) sb.replaceAll("%date%", URLEncoder.encode(msg.getDate().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%text%", URLEncoder.encode(msg.getText(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%refNo%", URLEncoder.encode(msg.getRefNo(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%recipient%", msg.getRecipient());
    sb.replaceAll("%from%", msg.getFrom());
    sb.replaceAll("%failureCause%", URLEncoder.encode(msg.getFailureCause().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%messageStatus%", msg.getMessageStatus().toString());
    return sb.toString();
  }  }
View Full Code Here

    if(msg.getDate() != null) sb.replaceAll("%date%", URLEncoder.encode(msg.getDate().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%text%", URLEncoder.encode(msg.getText(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%refNo%", URLEncoder.encode(msg.getRefNo(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%recipient%", msg.getRecipient());
    sb.replaceAll("%from%", msg.getFrom());
    sb.replaceAll("%failureCause%", URLEncoder.encode(msg.getFailureCause().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%messageStatus%", msg.getMessageStatus().toString());
    return sb.toString();
  }  }
View Full Code Here

    sb.replaceAll("%text%", URLEncoder.encode(msg.getText(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%refNo%", URLEncoder.encode(msg.getRefNo(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%recipient%", msg.getRecipient());
    sb.replaceAll("%from%", msg.getFrom());
    sb.replaceAll("%failureCause%", URLEncoder.encode(msg.getFailureCause().toString(), getProperty("encoding", "ISO-8859-1")));
    sb.replaceAll("%messageStatus%", msg.getMessageStatus().toString());
    return sb.toString();
  }  }
View Full Code Here

  }

  private String updateTemplateString(String template, InboundMessage msg)
  {
    ExtStringBuilder sb = new ExtStringBuilder(template);
    sb.replaceAll("%gatewayId%", msg.getGatewayId());
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    sb.replaceAll("%date%", msg.getDate().toString());
    sb.replaceAll("%text%", msg.getText());
    sb.replaceAll("%pduUserData%", msg.getPduUserData());
    sb.replaceAll("%originator%", msg.getOriginator());
View Full Code Here

  private String updateTemplateString(String template, InboundMessage msg)
  {
    ExtStringBuilder sb = new ExtStringBuilder(template);
    sb.replaceAll("%gatewayId%", msg.getGatewayId());
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    sb.replaceAll("%date%", msg.getDate().toString());
    sb.replaceAll("%text%", msg.getText());
    sb.replaceAll("%pduUserData%", msg.getPduUserData());
    sb.replaceAll("%originator%", msg.getOriginator());
    sb.replaceAll("%memIndex%", msg.getMemIndex());
View Full Code Here

  private String updateTemplateString(String template, InboundMessage msg)
  {
    ExtStringBuilder sb = new ExtStringBuilder(template);
    sb.replaceAll("%gatewayId%", msg.getGatewayId());
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    sb.replaceAll("%date%", msg.getDate().toString());
    sb.replaceAll("%text%", msg.getText());
    sb.replaceAll("%pduUserData%", msg.getPduUserData());
    sb.replaceAll("%originator%", msg.getOriginator());
    sb.replaceAll("%memIndex%", msg.getMemIndex());
    sb.replaceAll("%mpMemIndex%", msg.getMpMemIndex());
View Full Code Here

  {
    ExtStringBuilder sb = new ExtStringBuilder(template);
    sb.replaceAll("%gatewayId%", msg.getGatewayId());
    sb.replaceAll("%encoding%", (msg.getEncoding() == MessageEncodings.ENC7BIT ? "7-bit" : (msg.getEncoding() == MessageEncodings.ENC8BIT ? "8-bit" : "UCS2 (Unicode)")));
    sb.replaceAll("%date%", msg.getDate().toString());
    sb.replaceAll("%text%", msg.getText());
    sb.replaceAll("%pduUserData%", msg.getPduUserData());
    sb.replaceAll("%originator%", msg.getOriginator());
    sb.replaceAll("%memIndex%", msg.getMemIndex());
    sb.replaceAll("%mpMemIndex%", msg.getMpMemIndex());
    return sb.toString();
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.