Package com.crawl.model

Examples of com.crawl.model.LocationDistribution


          logger.debug("aStringLocColl="+aCrawlResultPackage.getLocationsAsString());
         
          for (String aStringGet: aStringLocColl){
              String aCurrString=aStringGet.toLowerCase();
             
              LocationDistribution aLocDist=aSortedMap.get(aCurrString);
              logger.debug("aLocDist="+aLocDist);
             
              if (aLocDist==null){
                  LocationDistribution aLoc=new LocationDistribution();
                  aLoc.setAreaName(aCurrString);
                  aLoc.setCount(1);
                  aSortedMap.put(aCurrString, aLoc);
              } else {
                  aLocDist.setCount(aLocDist.getCount()+1);
              }
          }
View Full Code Here


                aSecondStepColl.add((LocationDistribution)arrObjSecond[i]);
            }
        } 
       
        // Create and add the Rest item to the collection
        LocationDistribution aLocationDistributionRest=new LocationDistribution();
        aLocationDistributionRest.setAreaName("others");
        aLocationDistributionRest.setCount(aIntRestCopunter);
        aSecondStepColl.add(aLocationDistributionRest);
     
      return aSecondStepColl;
  }
View Full Code Here

     */
    private Collection<LocationDistribution> bubbleSort(Object[] inputObjArray) {
        for (int i = 0; i < inputObjArray.length; i++) {
            for (int j = 1; j < inputObjArray.length; j++) {
                if (((LocationDistribution)inputObjArray[j]).getCount() < (((LocationDistribution)inputObjArray[j - 1]).getCount())) {
                    LocationDistribution aLocationDistribution = (LocationDistribution)inputObjArray[j];
                    inputObjArray[j] = inputObjArray[j - 1];
                    inputObjArray[j - 1] = aLocationDistribution;
                }
            }
        }
View Full Code Here

TOP

Related Classes of com.crawl.model.LocationDistribution

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.