コード例 #1
0
ファイル: DialingRule.java プロジェクト: LordGaav/sipxecs
 @Override
 public CallTag getCallTag() {
   // try to determine the call type based on the rule type
   DialingRuleType type = getType();
   if (type != null) {
     CallTag callTag = type.getCallTag();
     if (callTag != null) {
       return callTag;
     }
   }
   // try to check for permissions
   List<Permission> permissions = getPermissions();
   if (permissions == null) {
     return null;
   }
   for (Permission p : permissions) {
     if (!p.isBuiltIn()) {
       continue;
     }
     PermissionName permissionName = PermissionName.findByName(p.getName());
     if (permissionName == null) {
       continue;
     }
     CallTag callTag = permissionName.getCalltag();
     if (callTag != null) {
       return callTag;
     }
   }
   return null;
 }