public static List<NamespaceDto> transformToDto(List<Namespace> namespaces){
  if (namespaces == null) {
    throw new WebApplicationException("Null entity object cannot be converted to Dto object.",Status.INTERNAL_SERVER_ERROR);
  }
  List<NamespaceDto> result=new ArrayList<>();
  for (  Namespace namespace : namespaces) {
    result.add(transformToDto(namespace));
  }
  return result;
}

public static List < NamespaceDto > transformToDto ( List < Namespace > namespaces ) { if ( namespaces == null ) { throw new WebApplicationException ( "Null entity object cannot be converted to Dto object." , Status . INTERNAL_SERVER_ERROR ) ; } List < NamespaceDto > result = new ArrayList < > ( ) ; for ( Namespace namespace : namespaces ) { result . add ( transformToDto ( namespace ) ) ; } return result ; }
converts list of alert entity objects to list of alertdto objects .
