public static void removeSiteSecondaryURLs(SSOToken ssoToken,String siteName,Collection secondaryURLs) throws SMSException, SSOException {
  ServiceConfig rootNode=getRootSiteConfig(ssoToken);
  ServiceConfig sc=rootNode.getSubConfig(siteName);
  ServiceConfig accessPoint=sc.getSubConfig(SUBCONFIG_ACCESS_URL);
  Set secondary=accessPoint.getSubConfigNames("*");
  if ((secondary != null) && !secondary.isEmpty()) {
    for (Iterator i=secondary.iterator(); i.hasNext(); ) {
      String secName=(String)i.next();
      if (secondaryURLs.contains(secName)) {
        accessPoint.removeSubConfig(secName);
      }
    }
  }
}

public static void removeSiteSecondaryURLs ( SSOToken ssoToken , String siteName , Collection secondaryURLs ) throws SMSException , SSOException { ServiceConfig rootNode = getRootSiteConfig ( ssoToken ) ; ServiceConfig sc = rootNode . getSubConfig ( siteName ) ; ServiceConfig accessPoint = sc . getSubConfig ( SUBCONFIG_ACCESS_URL ) ; Set secondary = accessPoint . getSubConfigNames ( "*" ) ; if ( ( secondary != null ) && ! secondary . isEmpty ( ) ) { for ( Iterator i = secondary . iterator ( ) ; i . hasNext ( ) ; ) { String secName = ( String ) i . next ( ) ; if ( secondaryURLs . contains ( secName ) ) { accessPoint . removeSubConfig ( secName ) ; } } } }
removes the secondary urls from a site .
