Package org.smslib.smpp

Examples of org.smslib.smpp.AbstractSMPPGateway


    Constructor<AbstractSMPPGateway> con= clazz.getConstructor(classArgs);
   
    String host=getProperty("host");
    Integer port=Integer.parseInt(getProperty("port"));
    Object args[]=new Object[]{getGatewayId(),host,port,getBindAttributes()};
    AbstractSMPPGateway gateway=con.newInstance(args);
    String enquireLink=getProperty("enquirelink");
    if(enquireLink!=null && !enquireLink.isEmpty()){
      gateway.setEnquireLink(Integer.parseInt(enquireLink));
    }
    String ton=getProperty("sourceton");
    TypeOfNumber typeOfNumber=(ton==null)?TypeOfNumber.UNKNOWN:TypeOfNumber.valueOf(Byte.parseByte(ton));
   
    String npi=getProperty("sourcenpi");
    NumberingPlanIndicator numberingPlanIndicator=(npi==null)?NumberingPlanIndicator.UNKNOWN:NumberingPlanIndicator.valueOf(Byte.parseByte(npi));
   
    gateway.setSourceAddress(new Address(typeOfNumber, numberingPlanIndicator));
   
    ton=getProperty("destton");
    typeOfNumber=(ton==null)?TypeOfNumber.UNKNOWN:TypeOfNumber.valueOf(Byte.parseByte(ton));
   
    npi=getProperty("destnpi");
    numberingPlanIndicator=(npi==null)?NumberingPlanIndicator.UNKNOWN:NumberingPlanIndicator.valueOf(Byte.parseByte(npi));
   
   
    gateway.setDestinationAddress(new Address(typeOfNumber, numberingPlanIndicator));
    setGateway(gateway);
   
 
  }
View Full Code Here

TOP

Related Classes of org.smslib.smpp.AbstractSMPPGateway

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.